| Crates.io | rustywallet-frost |
| lib.rs | rustywallet-frost |
| version | 0.1.0 |
| created_at | 2026-01-03 04:08:10.250885+00 |
| updated_at | 2026-01-03 04:08:10.250885+00 |
| description | FROST threshold signatures for rustywallet |
| homepage | |
| repository | https://github.com/rustywallet/rustywallet |
| max_upload_size | |
| id | 2019571 |
| size | 102,751 |
FROST (Flexible Round-Optimized Schnorr Threshold) signatures for rustywallet.
[dependencies]
rustywallet-frost = "0.1"
use rustywallet_frost::prelude::*;
// Setup: 2-of-3 threshold
let threshold = 2;
let num_participants = 3;
// Run DKG
let (key_packages, group_public) = run_dkg(threshold, num_participants)?;
// Create signing session
let message = b"Hello, FROST!";
let signers = vec![1, 2]; // Participants 1 and 2 will sign
// Generate commitments
let commitments: Vec<_> = signers.iter()
.map(|&id| generate_nonces(&key_packages[&id]))
.collect();
// Create partial signatures
let partial_sigs: Vec<_> = signers.iter()
.zip(commitments.iter())
.map(|(&id, nonce)| sign(&key_packages[&id], nonce, message, &commitments))
.collect();
// Aggregate into final signature
let signature = aggregate(&partial_sigs, &group_public)?;
// Verify
assert!(verify(&signature, &group_public, message)?);
MIT