hal-dat-raw 0.1.0
“Bounded raw HSD DAT archive parser”
Package first published within seven daysPackage under two months old
SHA-25692774b17e75def90e7f3a14f66360c141e2b01c54e1e463bb6816fb6d1f33d14
MaleculeH₂(DbMg)Md(Pa)
Evidence
1//! Bounded, loss-aware parsing for the raw HSD DAT archive container.
2//!
3//! This crate owns byte access, declared archive extents, ordinary relocation
4//! sites and pointer resolution, public roots, extern table records, parser
5//! errors, and resource limits. …
9:12… der;
10pub mod reloc;
11pub mod root;
12
13use header::{DATA_SECTION_OFFSET, DatHeader};
14use reader::{Reader, read_u32_at};
15use root::RootNode;
16
17const MAX_RELOCATIONS: u32 = 1_000_000;
18const MAX_NAMED_ROOTS: u32 = 65_536;
19const MAX_EXTERN …
20:21… UP_SITES: usize = 1_000_000;
21const MAX_ROOT_SYMBOL_BYTES: usize = 1024 * 1024;
22const MAX_EXTERN_SYMBOL_BYTES: usize = 1024 * 1024;
23
24/// Parsed HSD .dat file.
25///
26/// The data section contains all structs � …
97:26… ta section, roots, and sorted relocation sites, with
98 /// the header those imply and no externs. For building one in code;
99 /// nothing here i …
⋯4 lines
334}
335
336#[cfg(test)]
337mod tests {
338 use super::*;
339
340 #[test]
341 fn pointer_resolution_classifies_relocation_and_bounds() {
342 let mut data = vec![0; 24];
343 data[0x08..0x0C].copy_from_slice(&4u32.to_be_bytes());
344 data[0x0C..0x10].copy_from_slice(&4u32.to_be_bytes());
345 data[0x10..0x14].copy_from_slice(&24u32.to_be_bytes()) …
No evidence locations were recorded for this file. Raw result