extern struct CodeDirectory [src]

This CodeDirectory is tailored specifically at version 0x20400.

Fields

magic: u32Magic number (CSMAGIC_CODEDIRECTORY)
length: u32Total length of CodeDirectory blob
version: u32Compatibility version
flags: u32Setup and mode flags
hashOffset: u32Offset of hash slot element at index zero
identOffset: u32Offset of identifier string
nSpecialSlots: u32Number of special hash slots
nCodeSlots: u32Number of ordinary (code) hash slots
codeLimit: u32Limit to main image signature range
hashSize: u8Size of each hash in bytes
hashType: u8Type of hash (cdHashType* constants)
platform: u8Platform identifier; zero if not platform binary
pageSize: u8log2(page size in bytes); 0 => infinite
spare2: u32Unused (must be zero)
scatterOffset: u32
teamOffset: u32
spare3: u32
codeLimit64: u64
execSegBase: u64Offset of executable segment
execSegLimit: u64Limit of executable segment
execSegFlags: u64Executable segment flags

Source

pub const CodeDirectory = extern struct { /// Magic number (CSMAGIC_CODEDIRECTORY) magic: u32, /// Total length of CodeDirectory blob length: u32, /// Compatibility version version: u32, /// Setup and mode flags flags: u32, /// Offset of hash slot element at index zero hashOffset: u32, /// Offset of identifier string identOffset: u32, /// Number of special hash slots nSpecialSlots: u32, /// Number of ordinary (code) hash slots nCodeSlots: u32, /// Limit to main image signature range codeLimit: u32, /// Size of each hash in bytes hashSize: u8, /// Type of hash (cdHashType* constants) hashType: u8, /// Platform identifier; zero if not platform binary platform: u8, /// log2(page size in bytes); 0 => infinite pageSize: u8, /// Unused (must be zero) spare2: u32, /// scatterOffset: u32, /// teamOffset: u32, /// spare3: u32, /// codeLimit64: u64, /// Offset of executable segment execSegBase: u64, /// Limit of executable segment execSegLimit: u64, /// Executable segment flags execSegFlags: u64, }