filament-interfaces · ifac
Source declarations, signatures and documentation for ifac.
Read the current implementation boundaries before integration. This reference reproduces declarations; it omits source comments whose examples or readiness claims have not been verified.
Source: sigil/weave/filament/filament-interfaces/src/ifac.rs. SHA-256: 77eff297ae24451170b912467123ae3242a121e29a2ea5904da8494c1f1dd62f.
This reference follows declared source modules, retains conditional attributes, and includes public declarations and implementation methods. Private-module re-exports and trait resolution require the compiler; this is a source reference, not a claim that every listed item is a root import. Function bodies and constant values are omitted.
ifac::IFACConfig
#[derive(Debug, Clone)]
pub struct IFACConfig {
/// Network name (used for key derivation)
pub network_name: String,
/// Passphrase for key derivation
pub passphrase: Option<String>,
/// IFAC signature size in bits (8-512)
pub size_bits: usize
}Source line: 13.
ifac::IFACConfig::new
pub fn new(
network_name: impl Into<String>,
passphrase: Option<String>,
size_bits: usize,
) -> Self;Source line: 34.
ifac::IFACConfig::size_bytes
pub fn size_bytes(&self) -> usize;Source line: 53.
ifac::IFACError
#[derive(Error, Debug)]
pub enum IFACError {
/// Signature verification failed
#[error("signature verification failed")]
VerificationFailed,
/// Invalid signature length
#[error("invalid signature length: expected {expected}, got {actual}")]
InvalidSignatureLength {
/// Expected length
expected: usize,
/// Actual length
actual: usize,
},
/// Key derivation failed
#[error("key derivation failed: {0}")]
KeyDerivation(String),
}Source line: 70.
ifac::IFAC
#[derive(Clone)]
pub struct IFAC {
}Source line: 109.
ifac::IFAC::new
pub fn new(config: IFACConfig) -> Self;Source line: 117.
ifac::IFAC::sign
pub fn sign(&self, packet: &[u8]) -> Vec<u8>;Source line: 147.
ifac::IFAC::verify
pub fn verify(&self, packet: &[u8], signature: &[u8]) -> Result<(), IFACError>;Source line: 161.
ifac::IFAC::config
pub fn config(&self) -> &IFACConfig;Source line: 196.
ifac::IFAC::signature_size
pub fn signature_size(&self) -> usize;Source line: 201.
ifac::IFAC::add_signature
pub fn add_signature(&self, packet: &[u8]) -> Vec<u8>;Source line: 208.
ifac::IFAC::verify_and_extract
pub fn verify_and_extract(&self, packet_with_sig: &[u8]) -> Result<Vec<u8>, IFACError>;Source line: 224.