anubis-wormhole 1.0.0

A post-quantum secure file transfer tool based on the Magic Wormhole protocol.
Documentation
#[cfg(feature = "providers-pqclean")]
use crate::providers::mldsa::MlDsa87;
#[cfg(feature = "providers-pqclean")]
use crate::traits::Signature as _;

pub struct ServerAttestation {
    pub server_name: String,
    pub welcome_payload: Vec<u8>,
    pub signature: Vec<u8>,
    pub public_key: Vec<u8>,
}

#[cfg(feature = "providers-pqclean")]
pub fn verify_welcome(att: &ServerAttestation) -> bool {
    let sig = MlDsa87;
    sig.verify(&att.public_key, &att.welcome_payload, &att.signature)
}

#[cfg(not(feature = "providers-pqclean"))]
pub fn verify_welcome(_att: &ServerAttestation) -> bool { false }