#password-hashing #sha-256 #phf

no-std sha-crypt

Pure Rust implementation of the SHA-crypt password hashing algorithm based on SHA-256/SHA-512 as implemented by the POSIX crypt C library, including support for generating and verifying password hash strings in the Modular Crypt Format

15 releases

Uses new Rust 2024

0.6.0-rc.4 Feb 3, 2026
0.6.0-rc.0 Dec 13, 2025
0.6.0-pre.1 Jul 27, 2024
0.6.0-pre.0 Feb 8, 2024
0.1.0 Dec 28, 2020

#60 in Authentication

Download history 6707/week @ 2025-11-15 6231/week @ 2025-11-22 4325/week @ 2025-11-29 2356/week @ 2025-12-06 4137/week @ 2025-12-13 2473/week @ 2025-12-20 1962/week @ 2025-12-27 2417/week @ 2026-01-03 2669/week @ 2026-01-10 2997/week @ 2026-01-17 2671/week @ 2026-01-24 3396/week @ 2026-01-31 4669/week @ 2026-02-07 3632/week @ 2026-02-14 3472/week @ 2026-02-21 3139/week @ 2026-02-28

15,621 downloads per month
Used in 24 crates (9 directly)

MIT/Apache

26KB
482 lines

RustCrypto: SHA-crypt password hash

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

Pure Rust implementation of the SHA-crypt password hash based on SHA-256/SHA-512, a legacy password hashing scheme supported by the POSIX crypt C library.

Password hashes using this algorithm start with $5$ or $6$ when encoded using the Modular Crypt Format.

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.8–2.2MB
~46K SLoC