#crypt #phc #pbkdf #mcf

no-std password-hash

Traits which describe the functionality of password hashing algorithms, with optional support for a no_std-friendly implementation of the PHC string format, as well as generic support for other formats (e.g. Modular Crypt Format)

26 releases

Uses new Rust 2024

new 0.6.0-rc.8 Jan 11, 2026
0.6.0-rc.7 Dec 28, 2025
0.6.0-rc.2 Nov 5, 2025
0.6.0-rc.1 May 29, 2025
0.0.0 Aug 18, 2020

#79 in Authentication

Download history 510571/week @ 2025-09-25 504250/week @ 2025-10-02 519189/week @ 2025-10-09 528552/week @ 2025-10-16 547996/week @ 2025-10-23 566883/week @ 2025-10-30 609181/week @ 2025-11-06 595968/week @ 2025-11-13 651934/week @ 2025-11-20 580867/week @ 2025-11-27 665668/week @ 2025-12-04 639696/week @ 2025-12-11 538209/week @ 2025-12-18 369410/week @ 2025-12-25 548403/week @ 2026-01-01 756418/week @ 2026-01-08

2,330,288 downloads per month
Used in 2,182 crates (46 directly)

MIT/Apache

17KB
187 lines

RustCrypto: Password Hashing Traits

crate Docs Build Status Apache2/MIT licensed Rust Version Project Chat

Traits which describe the functionality of password hashing algorithms.

About

Provides a no_std-friendly implementation of the Password Hashing Competition (PHC) string format specification (a well-defined subset of the Modular Crypt Format a.k.a. MCF) which works in conjunction with the traits this crate defines.

Supported Crates

See RustCrypto/password-hashes for algorithm implementations which use this crate for interoperability:

  • argon2 - Argon2 memory hard key derivation function
  • pbkdf2 - Password-Based Key Derivation Function v2
  • scrypt - scrypt key derivation function

License

Licensed under either of:

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~0–255KB