[][src]Crate sharks

Fast, small and secure Shamir's Secret Sharing library crate

Usage example:

use sharks::Sharks;

// Set a minimum threshold of 10 shares
let sharks = Sharks(10);
// Obtain an iterator over the shares for secret [1, 2, 3, 4]
let dealer = sharks.dealer(&[1, 2, 3, 4]);
// Get 10 shares
let shares = dealer.take(10).collect();
// Recover the original secret!
let secret = sharks.recover(&shares).unwrap();
assert_eq!(secret, vec![1, 2, 3, 4]);

Structs

Sharks

Tuple struct which implements methods to generate shares and recover secrets over a 256 bits Galois Field. Its only parameter is the minimum shares threshold.