PHP Class Adldap\Objects\AccountControl

This class is for easily building a user account control value. https://support.microsoft.com/en-us/kb/305144
ファイルを表示 Open project: adldap2/adldap2 Class Usage Examples

Protected Properties

Property Type Description
$values array Stores the values to be added together to build the user account control integer.

Public Methods

Method Description
__construct ( integer $flag = null ) Constructor.
__toInt ( ) : integer Returns the account control integer when the object is casted as an integer.
__toString ( ) : string Returns the account control integer as a string when the object is casted as a string.
accountDoesNotRequirePreAuth ( ) : AccountControl (Windows 2000/Windows Server 2003) This account does not require Kerberos pre-authentication for logging on.
accountIsDisabled ( ) : AccountControl The user account is disabled.
accountIsForInterdomain ( ) : AccountControl This is a permit to trust an account for a system domain that trusts other domains.
accountIsForServer ( ) : AccountControl This is a computer account for a domain controller that is a member of this domain.
accountIsForWorkstation ( ) : AccountControl This is a computer account for a computer that is running Microsoft Windows NT 4.0 Workstation, Microsoft Windows NT 4.0 Server, Microsoft Windows 2000 Professional, or Windows 2000 Server and is a member of this domain.
accountIsLocked ( ) : AccountControl The user account is locked.
accountIsMnsLogon ( ) : AccountControl This is an MNS logon account.
accountIsNormal ( ) : AccountControl This is a default account type that represents a typical user.
accountIsReadOnly ( ) : AccountControl (Windows Server 2008/Windows Server 2008 R2) The account is a read-only domain controller (RODC).
accountIsTemporary ( ) : AccountControl This is an account for users whose primary account is in another domain.
accountRequiresSmartCard ( ) : AccountControl When this flag is set, it forces the user to log on by using a smart card.
allowEncryptedTextPassword ( ) : AccountControl The user can send an encrypted password.
apply ( integer $flag ) Applies the specified flag.
doNotTrustForDelegation ( ) : AccountControl When this flag is set, the security context of the user is not delegated to a service even if the service account is set as trusted for Kerberos delegation.
getValue ( ) : integer Returns the complete account control value.
getValues ( ) : array Returns the account control's values.
homeFolderIsRequired ( ) : AccountControl The home folder is required.
passwordCannotBeChanged ( ) : AccountControl The user cannot change the password. This is a permission on the user's object.
passwordDoesNotExpire ( ) : AccountControl Represents the password, which should never expire on the account.
passwordIsExpired ( ) : AccountControl (Windows 2000/Windows Server 2003) The user's password has expired.
passwordIsNotRequired ( ) : AccountControl No password is required.
runLoginScript ( ) : AccountControl The logon script will be run.
setValues ( array $flags ) Sets the account control values.
trustForDelegation ( ) : AccountControl When this flag is set, the service account (the user or computer account) under which a service runs is trusted for Kerberos delegation.
trustToAuthForDelegation ( ) : AccountControl (Windows 2000/Windows Server 2003) The account is enabled for delegation.
useDesKeyOnly ( ) : AccountControl (Windows 2000/Windows Server 2003) Restrict this principal to use only Data Encryption Standard (DES) encryption types for keys.

Protected Methods

Method Description
add ( integer $value ) : AccountControl Applies the inserted value to the values property array.

Method Details

__construct() public method

Constructor.
public __construct ( integer $flag = null )
$flag integer

__toInt() public method

Returns the account control integer when the object is casted as an integer.
public __toInt ( ) : integer
return integer

__toString() public method

Returns the account control integer as a string when the object is casted as a string.
public __toString ( ) : string
return string

accountDoesNotRequirePreAuth() public method

(Windows 2000/Windows Server 2003) This account does not require Kerberos pre-authentication for logging on.
public accountDoesNotRequirePreAuth ( ) : AccountControl
return AccountControl

accountIsDisabled() public method

The user account is disabled.
public accountIsDisabled ( ) : AccountControl
return AccountControl

accountIsForInterdomain() public method

This is a permit to trust an account for a system domain that trusts other domains.
public accountIsForInterdomain ( ) : AccountControl
return AccountControl

accountIsForServer() public method

This is a computer account for a domain controller that is a member of this domain.
public accountIsForServer ( ) : AccountControl
return AccountControl

accountIsForWorkstation() public method

This is a computer account for a computer that is running Microsoft Windows NT 4.0 Workstation, Microsoft Windows NT 4.0 Server, Microsoft Windows 2000 Professional, or Windows 2000 Server and is a member of this domain.
public accountIsForWorkstation ( ) : AccountControl
return AccountControl

accountIsLocked() public method

The user account is locked.
public accountIsLocked ( ) : AccountControl
return AccountControl

accountIsMnsLogon() public method

This is an MNS logon account.
public accountIsMnsLogon ( ) : AccountControl
return AccountControl

accountIsNormal() public method

This is a default account type that represents a typical user.
public accountIsNormal ( ) : AccountControl
return AccountControl

accountIsReadOnly() public method

This is a security-sensitive setting. Removing this setting from an RODC compromises security on that server.
public accountIsReadOnly ( ) : AccountControl
return AccountControl

accountIsTemporary() public method

This account provides user access to this domain, but not to any domain that trusts this domain. This is sometimes referred to as a local user account.
public accountIsTemporary ( ) : AccountControl
return AccountControl

accountRequiresSmartCard() public method

When this flag is set, it forces the user to log on by using a smart card.
public accountRequiresSmartCard ( ) : AccountControl
return AccountControl

add() protected method

Applies the inserted value to the values property array.
protected add ( integer $value ) : AccountControl
$value integer
return AccountControl

allowEncryptedTextPassword() public method

The user can send an encrypted password.
public allowEncryptedTextPassword ( ) : AccountControl
return AccountControl

apply() public method

Applies the specified flag.
public apply ( integer $flag )
$flag integer

doNotTrustForDelegation() public method

When this flag is set, the security context of the user is not delegated to a service even if the service account is set as trusted for Kerberos delegation.
public doNotTrustForDelegation ( ) : AccountControl
return AccountControl

getValue() public method

Returns the complete account control value.
public getValue ( ) : integer
return integer

getValues() public method

Returns the account control's values.
public getValues ( ) : array
return array

homeFolderIsRequired() public method

The home folder is required.
public homeFolderIsRequired ( ) : AccountControl
return AccountControl

passwordCannotBeChanged() public method

For information about how to programmatically set this permission, visit the following Web site: http://msdn2.microsoft.com/en-us/library/aa746398.aspx
public passwordCannotBeChanged ( ) : AccountControl
return AccountControl

passwordDoesNotExpire() public method

Represents the password, which should never expire on the account.
public passwordDoesNotExpire ( ) : AccountControl
return AccountControl

passwordIsExpired() public method

(Windows 2000/Windows Server 2003) The user's password has expired.
public passwordIsExpired ( ) : AccountControl
return AccountControl

passwordIsNotRequired() public method

No password is required.
public passwordIsNotRequired ( ) : AccountControl
return AccountControl

runLoginScript() public method

The logon script will be run.
public runLoginScript ( ) : AccountControl
return AccountControl

setValues() public method

Sets the account control values.
public setValues ( array $flags )
$flags array

trustForDelegation() public method

Any such service can impersonate a client requesting the service. To enable a service for Kerberos delegation, you must set this flag on the userAccountControl property of the service account.
public trustForDelegation ( ) : AccountControl
return AccountControl

trustToAuthForDelegation() public method

This is a security-sensitive setting. Accounts that have this option enabled should be tightly controlled. This setting lets a service that runs under the account assume a client's identity and authenticate as that user to other remote servers on the network.
public trustToAuthForDelegation ( ) : AccountControl
return AccountControl

useDesKeyOnly() public method

(Windows 2000/Windows Server 2003) Restrict this principal to use only Data Encryption Standard (DES) encryption types for keys.
public useDesKeyOnly ( ) : AccountControl
return AccountControl

Property Details

$values protected_oe property

Stores the values to be added together to build the user account control integer.
protected array $values
return array