ILIAS
Release_4_0_x_branch Revision 61816
|
Singleton class that stores all security settings. More...
Public Member Functions | |
getSecuritySettingsRefId () | |
setAccountSecurityMode ($a_mode) | |
set the account security mode | |
getAccountSecurityMode () | |
get the account security mode | |
setPasswordCharsAndNumbersEnabled ($a_chars_and_numbers_enabled) | |
set if the passwords have to contain characters and numbers | |
isPasswordCharsAndNumbersEnabled () | |
get boolean if the passwords have to contain characters and numbers | |
setPasswordSpecialCharsEnabled ($a_password_special_chars_enabled) | |
set if the passwords have to contain special characters | |
isPasswordSpecialCharsEnabled () | |
get boolean if the passwords have to contain special characters | |
setPasswordMinLength ($a_password_min_length) | |
set the minimum length for passwords | |
getPasswordMinLength () | |
get the minimum length for passwords | |
setPasswordMaxLength ($a_password_max_length) | |
set the maximum length for passwords | |
getPasswordMaxLength () | |
get the maximum length for passwords | |
setPasswordMaxAge ($a_password_max_age) | |
set the maximum password age | |
getPasswordMaxAge () | |
get the maximum password age | |
setLoginMaxAttempts ($a_login_max_attempts) | |
set the maximum count of login attempts | |
getLoginMaxAttempts () | |
get the maximum count of login attempts | |
setAutomaticHTTPSEnabled ($varname) | |
write access to enable automatic https detection | |
setAutomaticHTTPSHeaderName ($varname) | |
set header name for automatic https detection | |
setAutomaticHTTPSHeaderValue ($varname) | |
set header value for automatic https detection | |
getAutomaticHTTPSHeaderName () | |
read access to header name for automatic https detection | |
getAutomaticHTTPSHeaderValue () | |
read access to header value for automatic https detection | |
isAutomaticHTTPSEnabled () | |
read access to switch if automatic https detection is enabled | |
setHTTPSEnabled ($value) | |
Enable https for certain scripts. | |
isHTTPSEnabled () | |
read access to https enabled property | |
setPasswordChangeOnFirstLoginEnabled ($a_password_change_on_first_login_enabled) | |
set if the passwords have to be changed by users on first login | |
isPasswordChangeOnFirstLoginEnabled () | |
get boolean if the passwords have to be changed by users on first login | |
save () | |
Save settings. | |
validate () | |
validate settings | |
isPreventionOfSimultaneousLoginsEnabled () | |
Prevention of simultaneous logins with the same account. | |
setPreventionOfSimultaneousLogins ($value) | |
Enable/Disable prevention of simultaneous logins with the same account. |
Static Public Member Functions | |
static | _getInstance () |
Get instance of ilSecuritySettings. |
Data Fields | |
const | SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MIN_LENGTH = 4 |
const | SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_LENGTH = 5 |
const | SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_AGE = 6 |
const | SECURITY_SETTINGS_ERR_CODE_INVALID_LOGIN_MAX_ATTEMPTS = 7 |
const | SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN2 = 8 |
const | SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN3 = 9 |
const | SECURITY_SETTINGS_ERR_CODE_PASSWORD_MAX_LENGTH_LESS_MIN_LENGTH = 10 |
const | ACCOUNT_SECURITY_MODE_DEFAULT = 1 |
const | ACCOUNT_SECURITY_MODE_CUSTOMIZED = 2 |
Static Public Attributes | |
static | $SECURITY_SETTINGS_ERR_CODE_AUTO_HTTPS = 1 |
static | $SECURITY_SETTINGS_ERR_CODE_HTTP_NOT_AVAILABLE = 2 |
static | $SECURITY_SETTINGS_ERR_CODE_HTTPS_NOT_AVAILABLE = 3 |
Private Member Functions | |
__construct () | |
Private constructor: use _getInstance() | |
read () | |
read settings |
Private Attributes | |
$db | |
$settings | |
$https_header_enable | |
$https_header_name | |
$https_header_value | |
$https_enable | |
$account_security_mode = self::ACCOUNT_SECURITY_MODE_DEFAULT | |
$password_chars_and_numbers_enabled = false | |
$password_special_chars_enabled = false | |
$password_min_length = 0 | |
$password_max_length = 0 | |
$password_max_age = 0 | |
$login_max_attempts = 0 | |
$password_change_on_first_login_enabled = false | |
$prevent_simultaneous_logins = false |
Static Private Attributes | |
static | $instance = null |
Singleton class that stores all security settings.
/
Definition at line 34 of file class.ilSecuritySettings.php.
|
private |
Private constructor: use _getInstance()
private
Definition at line 81 of file class.ilSecuritySettings.php.
References $ilDB, $ilSetting, and read().
|
static |
Get instance of ilSecuritySettings.
Definition at line 99 of file class.ilSecuritySettings.php.
References $instance.
Referenced by ilUtil\generatePasswords(), ilUtil\getPasswordRequirementsInfo(), ilInitialisation\initILIAS(), ilUtil\isPassword(), ilObjUser\isPasswordChangeDemanded(), ilObjUser\isPasswordExpired(), ilObjPrivacySecurityGUI\save_security(), ilObjPrivacySecurityGUI\showSecurity(), and ilObjUserGUI\updateObject().
ilSecuritySettings::getAccountSecurityMode | ( | ) |
get the account security mode
Definition at line 134 of file class.ilSecuritySettings.php.
References $account_security_mode.
Referenced by save(), and validate().
ilSecuritySettings::getAutomaticHTTPSHeaderName | ( | ) |
read access to header name for automatic https detection
Definition at line 303 of file class.ilSecuritySettings.php.
References $https_header_name.
Referenced by save(), and validate().
ilSecuritySettings::getAutomaticHTTPSHeaderValue | ( | ) |
read access to header value for automatic https detection
Definition at line 313 of file class.ilSecuritySettings.php.
References $https_header_value.
Referenced by save(), and validate().
ilSecuritySettings::getLoginMaxAttempts | ( | ) |
get the maximum count of login attempts
Definition at line 262 of file class.ilSecuritySettings.php.
References $login_max_attempts.
Referenced by save(), and validate().
ilSecuritySettings::getPasswordMaxAge | ( | ) |
get the maximum password age
Definition at line 242 of file class.ilSecuritySettings.php.
References $password_max_age.
Referenced by save(), and validate().
ilSecuritySettings::getPasswordMaxLength | ( | ) |
get the maximum length for passwords
Definition at line 222 of file class.ilSecuritySettings.php.
References $password_max_length.
Referenced by save(), and validate().
ilSecuritySettings::getPasswordMinLength | ( | ) |
get the minimum length for passwords
Definition at line 202 of file class.ilSecuritySettings.php.
References $password_min_length.
Referenced by save(), and validate().
ilSecuritySettings::getSecuritySettingsRefId | ( | ) |
Definition at line 108 of file class.ilSecuritySettings.php.
References $ref_id.
ilSecuritySettings::isAutomaticHTTPSEnabled | ( | ) |
read access to switch if automatic https detection is enabled
Definition at line 323 of file class.ilSecuritySettings.php.
References $https_header_enable.
Referenced by save(), and validate().
ilSecuritySettings::isHTTPSEnabled | ( | ) |
read access to https enabled property
Definition at line 343 of file class.ilSecuritySettings.php.
References $https_enable.
Referenced by save(), and validate().
ilSecuritySettings::isPasswordChangeOnFirstLoginEnabled | ( | ) |
get boolean if the passwords have to be changed by users on first login
Definition at line 367 of file class.ilSecuritySettings.php.
References $password_change_on_first_login_enabled.
Referenced by save().
ilSecuritySettings::isPasswordCharsAndNumbersEnabled | ( | ) |
get boolean if the passwords have to contain characters and numbers
Definition at line 158 of file class.ilSecuritySettings.php.
References $password_chars_and_numbers_enabled.
Referenced by save(), and validate().
ilSecuritySettings::isPasswordSpecialCharsEnabled | ( | ) |
get boolean if the passwords have to contain special characters
Definition at line 182 of file class.ilSecuritySettings.php.
References $password_special_chars_enabled.
Referenced by save(), and validate().
ilSecuritySettings::isPreventionOfSimultaneousLoginsEnabled | ( | ) |
Prevention of simultaneous logins with the same account.
Definition at line 517 of file class.ilSecuritySettings.php.
References $prevent_simultaneous_logins.
Referenced by save().
|
private |
read settings
private
Definition at line 402 of file class.ilSecuritySettings.php.
References $ilDB, $query, $res, $row, and DB_FETCHMODE_ASSOC.
Referenced by __construct().
ilSecuritySettings::save | ( | ) |
Save settings.
Definition at line 377 of file class.ilSecuritySettings.php.
References getAccountSecurityMode(), getAutomaticHTTPSHeaderName(), getAutomaticHTTPSHeaderValue(), getLoginMaxAttempts(), getPasswordMaxAge(), getPasswordMaxLength(), getPasswordMinLength(), isAutomaticHTTPSEnabled(), isHTTPSEnabled(), isPasswordChangeOnFirstLoginEnabled(), isPasswordCharsAndNumbersEnabled(), isPasswordSpecialCharsEnabled(), and isPreventionOfSimultaneousLoginsEnabled().
ilSecuritySettings::setAccountSecurityMode | ( | $a_mode | ) |
set the account security mode
integer | $a_mode |
Definition at line 123 of file class.ilSecuritySettings.php.
ilSecuritySettings::setAutomaticHTTPSEnabled | ( | $varname | ) |
write access to enable automatic https detection
boolean | $varname |
Definition at line 273 of file class.ilSecuritySettings.php.
ilSecuritySettings::setAutomaticHTTPSHeaderName | ( | $varname | ) |
set header name for automatic https detection
string | $varname |
Definition at line 283 of file class.ilSecuritySettings.php.
ilSecuritySettings::setAutomaticHTTPSHeaderValue | ( | $varname | ) |
set header value for automatic https detection
string | $varname |
Definition at line 293 of file class.ilSecuritySettings.php.
ilSecuritySettings::setHTTPSEnabled | ( | $value | ) |
Enable https for certain scripts.
boolean | $value |
Definition at line 333 of file class.ilSecuritySettings.php.
ilSecuritySettings::setLoginMaxAttempts | ( | $a_login_max_attempts | ) |
set the maximum count of login attempts
integer | $a_login_max_attempts |
Definition at line 252 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordChangeOnFirstLoginEnabled | ( | $a_password_change_on_first_login_enabled | ) |
set if the passwords have to be changed by users on first login
boolean | $a_password_change_on_first_login_enabled |
Definition at line 355 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordCharsAndNumbersEnabled | ( | $a_chars_and_numbers_enabled | ) |
set if the passwords have to contain characters and numbers
boolean | $a_chars_and_numbers_enabled |
Definition at line 146 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordMaxAge | ( | $a_password_max_age | ) |
set the maximum password age
integer | $a_password_max_age |
Definition at line 232 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordMaxLength | ( | $a_password_max_length | ) |
set the maximum length for passwords
integer | $a_password_max_length |
Definition at line 212 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordMinLength | ( | $a_password_min_length | ) |
set the minimum length for passwords
integer | $a_password_min_length |
Definition at line 192 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPasswordSpecialCharsEnabled | ( | $a_password_special_chars_enabled | ) |
set if the passwords have to contain special characters
boolean | $a_password_special_chars_enabled |
Definition at line 170 of file class.ilSecuritySettings.php.
ilSecuritySettings::setPreventionOfSimultaneousLogins | ( | $value | ) |
Enable/Disable prevention of simultaneous logins with the same account.
boolean | $value |
Definition at line 527 of file class.ilSecuritySettings.php.
ilSecuritySettings::validate | ( | ) |
validate settings
Definition at line 437 of file class.ilSecuritySettings.php.
References $password_min_length, $SECURITY_SETTINGS_ERR_CODE_HTTP_NOT_AVAILABLE, $SECURITY_SETTINGS_ERR_CODE_HTTPS_NOT_AVAILABLE, ilHTTPS\_checkHTTP(), ilHTTPS\_checkHTTPS(), elseif(), getAccountSecurityMode(), getAutomaticHTTPSHeaderName(), getAutomaticHTTPSHeaderValue(), getLoginMaxAttempts(), getPasswordMaxAge(), getPasswordMaxLength(), getPasswordMinLength(), isAutomaticHTTPSEnabled(), isHTTPSEnabled(), isPasswordCharsAndNumbersEnabled(), isPasswordSpecialCharsEnabled(), SECURITY_SETTINGS_ERR_CODE_INVALID_LOGIN_MAX_ATTEMPTS, SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_AGE, SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_LENGTH, SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MIN_LENGTH, SECURITY_SETTINGS_ERR_CODE_PASSWORD_MAX_LENGTH_LESS_MIN_LENGTH, SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN2, and SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN3.
|
private |
Definition at line 62 of file class.ilSecuritySettings.php.
Referenced by getAccountSecurityMode().
|
private |
Definition at line 54 of file class.ilSecuritySettings.php.
|
private |
Definition at line 60 of file class.ilSecuritySettings.php.
Referenced by isHTTPSEnabled().
|
private |
Definition at line 57 of file class.ilSecuritySettings.php.
Referenced by isAutomaticHTTPSEnabled().
|
private |
Definition at line 58 of file class.ilSecuritySettings.php.
Referenced by getAutomaticHTTPSHeaderName().
|
private |
Definition at line 59 of file class.ilSecuritySettings.php.
Referenced by getAutomaticHTTPSHeaderValue().
|
staticprivate |
Definition at line 53 of file class.ilSecuritySettings.php.
Referenced by _getInstance().
|
private |
Definition at line 68 of file class.ilSecuritySettings.php.
Referenced by getLoginMaxAttempts().
|
private |
Definition at line 70 of file class.ilSecuritySettings.php.
Referenced by isPasswordChangeOnFirstLoginEnabled().
|
private |
Definition at line 63 of file class.ilSecuritySettings.php.
Referenced by isPasswordCharsAndNumbersEnabled().
|
private |
Definition at line 67 of file class.ilSecuritySettings.php.
Referenced by getPasswordMaxAge().
|
private |
Definition at line 66 of file class.ilSecuritySettings.php.
Referenced by getPasswordMaxLength().
|
private |
Definition at line 65 of file class.ilSecuritySettings.php.
Referenced by getPasswordMinLength(), and validate().
|
private |
Definition at line 64 of file class.ilSecuritySettings.php.
Referenced by isPasswordSpecialCharsEnabled().
|
private |
Definition at line 72 of file class.ilSecuritySettings.php.
Referenced by isPreventionOfSimultaneousLoginsEnabled().
|
static |
Definition at line 36 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct().
|
static |
Definition at line 37 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
|
static |
Definition at line 38 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
|
private |
Definition at line 55 of file class.ilSecuritySettings.php.
const ilSecuritySettings::ACCOUNT_SECURITY_MODE_CUSTOMIZED = 2 |
Definition at line 50 of file class.ilSecuritySettings.php.
Referenced by ilUtil\getPasswordRequirementsInfo(), ilInitialisation\initILIAS(), ilUtil\isPassword(), ilObjUser\isPasswordExpired(), ilObjPrivacySecurityGUI\showSecurity(), and ilObjUserGUI\updateObject().
const ilSecuritySettings::ACCOUNT_SECURITY_MODE_DEFAULT = 1 |
Definition at line 49 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\showSecurity().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_INVALID_LOGIN_MAX_ATTEMPTS = 7 |
Definition at line 43 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_AGE = 6 |
Definition at line 42 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MAX_LENGTH = 5 |
Definition at line 41 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_INVALID_PASSWORD_MIN_LENGTH = 4 |
Definition at line 40 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_PASSWORD_MAX_LENGTH_LESS_MIN_LENGTH = 10 |
Definition at line 46 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN2 = 8 |
Definition at line 44 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().
const ilSecuritySettings::SECURITY_SETTINGS_ERR_CODE_PASSWORD_MIN_LENGTH_MIN3 = 9 |
Definition at line 45 of file class.ilSecuritySettings.php.
Referenced by ilObjPrivacySecurityGUI\__construct(), and validate().