Plain
Less than 1 minute
Plain
A "hasher" that stores and compares credentials as plain text.
class Plain implements \Hazaar\Auth\Interface\PasswordHasherImplements: Hazaar\Auth\Interface\PasswordHasher
WARNING: only for credentials the application supplies itself (for example service-to-service secrets that are already random), never for user passwords. This is what Hazaar\Auth\Adapter::disableCredentialHashing switches to.
Methods
hash
public hash(string $password, string $identity): stringReturns: string
Parameters
| Parameter | Type | Description |
|---|---|---|
$password | string | |
$identity | string |
verify
public verify(string $password, string $stored, string $identity): boolReturns: bool
Parameters
| Parameter | Type | Description |
|---|---|---|
$password | string | |
$stored | string | |
$identity | string |
needsRehash
public needsRehash(string $stored): boolReturns: bool
Parameters
| Parameter | Type | Description |
|---|---|---|
$stored | string |
Generated by Hazaar API Doc Generator on Wed, 28 Oct 2026 08:43:30 +0000