pakery-opaque
OPAQUE augmented PAKE protocol implementation (RFC 9807).
Part of the pakery workspace.
OPAQUE is an augmented (asymmetric) PAKE: the server stores a password verifier instead of the plaintext password. Even if the server is compromised, the attacker must perform an offline dictionary attack per user to recover passwords.
Usage
[]
= "0.1"
= { = "0.1", = ["ristretto255"] }
Example
use *;
use *;
use IdentityKsf;
;
let mut rng = OsRng;
// === Registration ===
let setup = new.unwrap;
let =
start.unwrap;
let reg_response =
start
.unwrap;
let = reg_state.finish.unwrap;
// === Login ===
let =
start.unwrap;
let = start.unwrap;
let = client_state
.finish.unwrap;
let server_session_key = server_state.finish.unwrap;
assert_eq!;
Features
| Feature | Description |
|---|---|
std (default) |
Enable std support |
getrandom |
Enable OS-backed RNG via rand_core/getrandom |
test-utils |
Expose deterministic constructors for testing |
Security
#![forbid(unsafe_code)]- Constant-time comparisons via
subtle - Secret values zeroized on drop via
zeroize - Validated against RFC 9807 test vectors
MSRV
The minimum supported Rust version is 1.79.
License
Licensed under either of Apache License, Version 2.0 or MIT License at your option.