All Projects → sru-systems → Rust Argon2

sru-systems / Rust Argon2

Licence: other
Rust library for hashing passwords using Argon2.

Programming Languages

rust
11053 projects

Labels

Projects that are alternatives of or similar to Rust Argon2

phc-crypto
Hashing algorithms simplified (supports Argon2, Bcrypt, Scrypt, and PBKDF2)
Stars: ✭ 22 (-82.26%)
Mutual labels:  argon2
Xmrig
RandomX, CryptoNight, AstroBWT and Argon2 CPU/GPU miner
Stars: ✭ 6,372 (+5038.71%)
Mutual labels:  argon2
Pinkman
PINkman is a library to help implementing an authentication by a PIN code in a secure manner. The library derives hash from the user's PIN using Argon2 function and stores it in an encrypted file. The file is encrypted with the AES-256 algorithm in the GCM mode and keys are stored in the AndroidKeystore.
Stars: ✭ 59 (-52.42%)
Mutual labels:  argon2
hash-wasm
Lightning fast hash functions using hand-tuned WebAssembly binaries
Stars: ✭ 382 (+208.06%)
Mutual labels:  argon2
argon2kt
An Android/Kotlin binding for the Argon2 hash
Stars: ✭ 36 (-70.97%)
Mutual labels:  argon2
Globaleaks
GlobaLeaks is free, open source software enabling anyone to easily set up and maintain a secure whistleblowing platform.
Stars: ✭ 832 (+570.97%)
Mutual labels:  argon2
CppSecurity
C++ Security Library
Stars: ✭ 24 (-80.65%)
Mutual labels:  argon2
Argon2pw
Argon2 password hashing package for go with constant time hash comparison
Stars: ✭ 85 (-31.45%)
Mutual labels:  argon2
Argon2 Cffi
Secure Password Hashes for Python
Stars: ✭ 264 (+112.9%)
Mutual labels:  argon2
Unchained
Secure password hashers for Go compatible with Django
Stars: ✭ 46 (-62.9%)
Mutual labels:  argon2
crypthash-net
CryptHash.NET is a .NET multi-target library to encrypt/decrypt/hash/encode/decode strings and files, with an optional .NET Core multiplatform console utility.
Stars: ✭ 33 (-73.39%)
Mutual labels:  argon2
xmrigCC
RandomX, CryptoNight, AstroBWT, Argon2 and GhostRider CPU/GPU miner with Command&Control (CC) Server and Monitoring
Stars: ✭ 262 (+111.29%)
Mutual labels:  argon2
Halite
High-level cryptography interface powered by libsodium
Stars: ✭ 933 (+652.42%)
Mutual labels:  argon2
lazysodium-java
A Java implementation of the Libsodium crypto library. For the lazy dev.
Stars: ✭ 110 (-11.29%)
Mutual labels:  argon2
Lazysodium Android
An Android implementation of the Libsodium cryptography library. For the lazy dev.
Stars: ✭ 69 (-44.35%)
Mutual labels:  argon2
Kryptor
A simple, modern, and secure encryption and signing tool that aims to be a better version of age and Minisign.
Stars: ✭ 267 (+115.32%)
Mutual labels:  argon2
Fscrypt
Go tool for managing Linux filesystem encryption
Stars: ✭ 534 (+330.65%)
Mutual labels:  argon2
Password4j
Password4j is a user-friendly cryptographic library that supports Argon2, Bcrypt, Scrypt, PBKDF2 and various cryptographic hash functions.
Stars: ✭ 124 (+0%)
Mutual labels:  argon2
Comeonin
Password hashing specification for the Elixir programming language
Stars: ✭ 1,166 (+840.32%)
Mutual labels:  argon2
Node Argon2
Node.js bindings for Argon2 hashing algorithm
Stars: ✭ 1,008 (+712.9%)
Mutual labels:  argon2

Rust-argon2

Rust library for hashing passwords using Argon2, the password-hashing function that won the Password Hashing Competition (PHC).

Usage

To use rust-argon2, add the following to your Cargo.toml:

[dependencies]
rust-argon2 = "0.8"

And the following to your crate root:

extern crate argon2;

Examples

Create a password hash using the defaults and verify it:

use argon2::{self, Config};

let password = b"password";
let salt = b"randomsalt";
let config = Config::default();
let hash = argon2::hash_encoded(password, salt, &config).unwrap();
let matches = argon2::verify_encoded(&hash, password).unwrap();
assert!(matches);

Create a password hash with custom settings and verify it:

use argon2::{self, Config, ThreadMode, Variant, Version};

let password = b"password";
let salt = b"othersalt";
let config = Config {
    variant: Variant::Argon2i,
    version: Version::Version13,
    mem_cost: 65536,
    time_cost: 10,
    lanes: 4,
    thread_mode: ThreadMode::Parallel,
    secret: &[],
    ad: &[],
    hash_length: 32
};
let hash = argon2::hash_encoded(password, salt, &config).unwrap();
let matches = argon2::verify_encoded(&hash, password).unwrap();
assert!(matches);

Limitations

This crate has the same limitation as the blake2-rfc crate that it uses. It does not attempt to clear potentially sensitive data from its work memory. To do so correctly without a heavy performance penalty would require help from the compiler. It's better to not attempt to do so than to present a false assurance.

This version uses the standard implementation and does not yet implement optimizations. Therefore, it is not the fastest implementation available.

License

Rust-argon2 is dual licensed under the MIT and Apache 2.0 licenses, the same licenses as the Rust compiler.

Contributions

Contributions are welcome. By submitting a pull request you are agreeing to make you work available under the license terms of the Rust-argon2 project.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].