INNER CODE UNIT · Rust

Some

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

    if let Some(hid_packet_iterator) = HidPacketIterator::new(message) {
        let mut assembler_reply = MessageAssembler::default();
        for pkt_request in hid_packet_iterator {
            for pkt_reply in ctap.process_hid_packet(&pkt_request, Transport::MainHid) {
                // Only checks for assembling crashes, not for semantics.
                let (cid, processed_pkt) = CtapHid::<TestEnv>::process_single_packet(&pkt_reply);
                let _ = assembler_reply.parse_packet(ctap.env(), cid, processed_pkt);
            }
        }
    }
}

// Interprets the raw data as any ctap command (including the command byte) and
// invokes message splitting, packet processing at CTAP HID level and response assembling
// using an initialized and allocated channel.
pub fn process_ctap_any_type(data: &[u8]) -> arbitrary::Result<()> {
    let mut unstructured = Unstructured::new(data);

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…