#[repr(C)]
pub struct DyldCacheHeader<E: Endian> {
Show 14 fields pub magic: [u8; 16], pub mapping_offset: U32<E>, pub mapping_count: U32<E>, pub images_offset: U32<E>, pub images_count: U32<E>, pub dyld_base_address: U64<E>, pub local_symbols_offset: U64<E>, pub local_symbols_size: U64<E>, pub uuid: [u8; 16], pub subcaches_offset: U32<E>, pub subcaches_count: U32<E>, pub symbols_subcache_uuid: [u8; 16], pub images_across_all_subcaches_offset: U32<E>, pub images_across_all_subcaches_count: U32<E>, /* private fields */
}
Expand description

The dyld cache header. Corresponds to struct dyld_cache_header from dyld_cache_format.h. This header has grown over time. Only the fields up to and including dyld_base_address are guaranteed to be present. For all other fields, check the header size before accessing the field. The header size is stored in mapping_offset; the mappings start right after the theader.

Fields§

§magic: [u8; 16]

e.g. “dyld_v0 i386”

§mapping_offset: U32<E>

file offset to first dyld_cache_mapping_info

§mapping_count: U32<E>

number of dyld_cache_mapping_info entries

§images_offset: U32<E>

file offset to first dyld_cache_image_info

§images_count: U32<E>

number of dyld_cache_image_info entries

§dyld_base_address: U64<E>

base address of dyld when cache was built

§local_symbols_offset: U64<E>

file offset of where local symbols are stored

§local_symbols_size: U64<E>

size of local symbols information

§uuid: [u8; 16]

unique value for each shared cache file

§subcaches_offset: U32<E>

file offset to first dyld_subcache_info

§subcaches_count: U32<E>

number of dyld_subcache_info entries

§symbols_subcache_uuid: [u8; 16]

the UUID of the .symbols subcache

§images_across_all_subcaches_offset: U32<E>

file offset to first dyld_cache_image_info Use this instead of images_offset if mapping_offset is at least 0x1c4.

§images_across_all_subcaches_count: U32<E>

number of dyld_cache_image_info entries Use this instead of images_count if mapping_offset is at least 0x1c4.

Implementations§

Read the dyld cache header.

Returns (arch, endian) based on the magic string.

Return the mapping information table.

Return the information about subcaches, if present.

Return the UUID for the .symbols subcache, if present.

Return the image information table.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.