INNER CODE UNIT · Rust

from

google/OpenSK · libraries/opensk/fuzz/fuzz_helper/src/lib.rs:50

    fn from(err: arbitrary::Error) -> Self {
        Self::ArbitraryError(err)
    }
}

// Converts a byte slice into Message
fn raw_to_message(data: &[u8]) -> Message {
    if data.len() <= 4 {
        let mut cid = [0; 4];
        cid[..data.len()].copy_from_slice(data);
        Message {
            cid,
            // Arbitrary command.
            cmd: CtapHidCommand::Cbor,
            payload: vec![],
        }
    } else {
        Message {

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…