std::crypto::password¶
Status: experimental
Argon2id password hashing facade: PHC-string hash / verify / re-hash policy.
API details and source¶
The implementation source contains the complete declarations and implementation notes. The table below lists canonical Gossamer call signatures; every item name links directly to its implementation file.
| Item | Canonical signature or declaration | Description |
|---|---|---|
hash |
fn hash(password: String) -> Result<String, errors::Error> |
Argon2id hash of plaintext; returns a PHC-format string for storage. |
needs_rehash |
fn needs_rehash(hash: String) -> bool |
True iff the stored PHC's parameters are below the current defaults. |
verify |
fn verify(password: String, hash: String) -> Result<bool, errors::Error> |
Constant-time verify of plaintext against a stored PHC string. |