Skip to content

Parsing of __init_offsets section in MachO #6106

Open
@mostobriv

Description

@mostobriv

What is the feature you'd like to have?
As for some time apple presented new ways to store global constructors pointers, modern compilers used to add the sections __init_offsets (pointers there stored as 32-bit RVA) instead of an old one __mod_init_func (pointers there stored as raw pointers), i think BN should be able to parse it as well and use it within its analysis.

Is your feature request related to a problem?
Not much, just simple enhancement

Are any alternative solutions acceptable?
It can be easily done with scripting yeah.

Additional Information:
There is dyld code, related to getting initialisers from this section:
https://github.com/apple-oss-distributions/dyld/blob/65bbeed63cec73f313b1d636e63f243964725a9d/cache-builder/OptimizerLinkedit.cpp#L370-L377

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions