sync
This commit is contained in:
parent
47c2c79f7f
commit
6413513ee9
|
@ -1,2 +1,4 @@
|
|||
#[cfg(feature = "naive")]
|
||||
pub mod naive;
|
||||
|
||||
pub(crate) mod sig;
|
||||
|
|
|
@ -1,2 +1,21 @@
|
|||
use crate::sig::KeyGen;
|
||||
|
||||
pub struct SigParams {
|
||||
m: u16,
|
||||
n: u16,
|
||||
o: u16,
|
||||
k: u16,
|
||||
salt_bytes: u8,
|
||||
digest_bytes: u8,
|
||||
pk_seed_bytes: u8,
|
||||
}
|
||||
|
||||
pub struct SigningKey {
|
||||
v: VerifyKey,
|
||||
}
|
||||
|
||||
pub struct VerifyKey {}
|
||||
|
||||
impl KeyGen<SigParams> for SigningKey {
|
||||
fn gen(params: SigParams) -> Self {}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
pub trait Signer<S> {
|
||||
fn gen() -> Self;
|
||||
pub trait KeyGen<P> {
|
||||
fn gen(params: P) -> Self;
|
||||
}
|
||||
|
||||
pub trait Signer<S> {
|
||||
fn sign(&self, msg: &[u8]) -> S;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user