프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$adapter | mixed | Auth adapter object | |
$attempts | integer | Current number of login attempts | |
$encryption | integer | Encryption method to use | |
$encryptionOptions | array | 'salt' // Custom Salt 'secret' // Secret pepper 'cost' // Bcrypt cost 'prefix' // Bcrypt prefix 'rounds' // Sha rounds 'cipher' // Mcrypt cipher 'mode' // Mcrypt cipher 'source' // Mcrypt source | |
$ip | string | Current IP address | |
$isValid | boolean | User validation result from authentication | |
$result | integer | Authentication result | |
$subnet | array | Current subnet | |
$validators | array | Array of validator objects |
메소드 | 설명 | |
---|---|---|
__construct ( Pop\Auth\Adapter\AdapterInterface $adapter, integer $encryption, array $options = [] ) : |
Constructor | |
authenticate ( string $username, string $password ) : integer | Method to authenticate a user | |
factory ( Pop\Auth\Adapter\AdapterInterface $adapter, integer $encryption ) : |
Static method to instantiate the auth object and return itself to facilitate chaining methods together. | |
getAttempts ( ) : integer | Method to get the current number of login attempts | |
getEncryption ( ) : integer | Method to get the encryption | |
getEncryptionOptions ( ) : array | Method to get the encryption options | |
getResult ( ) : integer | Method to get the authentication result | |
getResultMessage ( ) : string | Method to get the authentication result message | |
getUser ( ) : array | Method to get the user data array from the adapter | |
getValidator ( string $name ) : mixed | Method to get a validator | |
isValid ( ) : boolean | Method to determine if the user is valid | |
setAllowedIps ( string | array $ips = null ) : |
Method to set the allowed IP addresses | |
setAllowedSubnets ( string | array $subnets = null ) : |
Method to set the allowed subnets | |
setAttemptLimit ( integer $attempts ) : |
Method to set the number of attempts allowed | |
setAttempts ( integer $attempts ) : |
Method to set the number of attempts allowed | |
setBlockedIps ( string | array $ips = null ) : |
Method to set the block IP addresses | |
setBlockedSubnets ( string | array $subnets = null ) : |
Method to set the block subnets | |
setEncryption ( integer $encryption ) : |
Method to set the encryption | |
setEncryptionOptions ( array $options = [] ) : |
Method to set the encryption options |
메소드 | 설명 | |
---|---|---|
filterIps ( string | array $ips ) : array | Method to filter the ip addresses to confirm their validity | |
filterSubnets ( string | array $subnets ) : array | Method to filter the subnets to confirm their validity | |
processValidators ( ) : void | Method to process the validators |
public __construct ( Pop\Auth\Adapter\AdapterInterface $adapter, integer $encryption, array $options = [] ) : |
||
$adapter | Pop\Auth\Adapter\AdapterInterface | |
$encryption | integer | |
$options | array | |
리턴 |
public getAttempts ( ) : integer | ||
리턴 | integer |
public getEncryptionOptions ( ) : array | ||
리턴 | array |
public getResultMessage ( ) : string | ||
리턴 | string |
public getValidator ( string $name ) : mixed | ||
$name | string | |
리턴 | mixed |
protected processValidators ( ) : void | ||
리턴 | void |
public setAllowedIps ( string | array $ips = null ) : |
||
$ips | string | array | |
리턴 |
public setAllowedSubnets ( string | array $subnets = null ) : |
||
$subnets | string | array | |
리턴 |
public setAttemptLimit ( integer $attempts ) : |
||
$attempts | integer | |
리턴 |
public setAttempts ( integer $attempts ) : |
||
$attempts | integer | |
리턴 |
public setBlockedIps ( string | array $ips = null ) : |
||
$ips | string | array | |
리턴 |
public setBlockedSubnets ( string | array $subnets = null ) : |
||
$subnets | string | array | |
리턴 |
public setEncryption ( integer $encryption ) : |
||
$encryption | integer | |
리턴 |
public setEncryptionOptions ( array $options = [] ) : |
||
$options | array | |
리턴 |
protected array $encryptionOptions | ||
리턴 | array |