INNER CODE UNIT · Rust

to_byte_vectors_32

IronCoreLabs/recrypt-rs · src/internal/mod.rs:88

    pub fn to_byte_vectors_32(&self) -> Option<([u8; 32], [u8; 32])> {
        self.value
            .normalize()
            .map(|(x, y)| (x.to_bytes_32(), y.to_bytes_32()))
    }
}

impl PublicKey<fp_480::Monty> {
    pub fn to_byte_vectors_60(&self) -> Option<([u8; 60], [u8; 60])> {
        self.value
            .normalize()
            .map(|(x, y)| (x.to_bytes_60(), y.to_bytes_60()))
    }
}

impl<T: Field + Hashable> Hashable for PublicKey<T> {
    fn to_bytes(&self) -> ByteVector {
        self.value.to_bytes()

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…