ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilPasswordEncoder Interface Reference
+ Inheritance diagram for ilPasswordEncoder:
+ Collaboration diagram for ilPasswordEncoder:

Public Member Functions

 encodePassword ($raw, $salt)
 Encodes the raw password. More...
 
 isPasswordValid ($encoded, $raw, $salt)
 Checks a raw password against an encoded password. More...
 
 getName ()
 Returns a unique name/id of the concrete password encoder. More...
 
 requiresSalt ()
 Returns whether or not the encoder requires a salt. More...
 
 requiresReencoding ($encoded)
 Returns whether or not the a encoded password needs to be re-encoded. More...
 
 isSupportedByRuntime ()
 Returns whether or not the encoder is supported by the runtime (PHP, HHVM, ...) More...
 

Detailed Description

Definition at line 9 of file interface.ilPasswordEncoder.php.

Member Function Documentation

◆ encodePassword()

ilPasswordEncoder::encodePassword (   $raw,
  $salt 
)

Encodes the raw password.

Parameters
string$rawThe password to encode
string$saltThe salt
Returns
string The encoded password

Implemented in ilBcryptPasswordEncoder, ilBcryptPhpPasswordEncoder, and ilMd5PasswordEncoder.

◆ getName()

ilPasswordEncoder::getName ( )

Returns a unique name/id of the concrete password encoder.

Returns
string

Implemented in ilBcryptPasswordEncoder, ilBcryptPhpPasswordEncoder, and ilMd5PasswordEncoder.

◆ isPasswordValid()

ilPasswordEncoder::isPasswordValid (   $encoded,
  $raw,
  $salt 
)

Checks a raw password against an encoded password.

The raw password has to be injected into the encoder instance before.

Parameters
string$encodedAn encoded password
string$rawA raw password
string$saltThe salt
Returns
Boolean true if the password is valid, false otherwise

Implemented in ilBcryptPasswordEncoder, ilBcryptPhpPasswordEncoder, and ilMd5PasswordEncoder.

◆ isSupportedByRuntime()

ilPasswordEncoder::isSupportedByRuntime ( )

Returns whether or not the encoder is supported by the runtime (PHP, HHVM, ...)

Returns
boolean

Implemented in ilBcryptPhpPasswordEncoder, and ilBasePasswordEncoder.

◆ requiresReencoding()

ilPasswordEncoder::requiresReencoding (   $encoded)

Returns whether or not the a encoded password needs to be re-encoded.

Parameters
$encodedstring
Returns
boolean

Implemented in ilBcryptPasswordEncoder, ilBcryptPhpPasswordEncoder, and ilBasePasswordEncoder.

◆ requiresSalt()

ilPasswordEncoder::requiresSalt ( )

Returns whether or not the encoder requires a salt.

Returns
boolean

Implemented in ilBcryptPasswordEncoder, and ilBasePasswordEncoder.


The documentation for this interface was generated from the following file: