4
0
mirror of https://github.com/QuasarApp/LIEF.git synced 2025-05-04 16:19:33 +00:00
This commit is contained in:
Romain Thomas 2018-06-27 16:00:44 +02:00
parent 86941c28cd
commit d7582fcab9

@ -20,7 +20,7 @@ A basic Mach-O binary (i.e. not FAT) can be represented in fours parts that are
The first part begins with a header that can be accessed through the :attr:`lief.MachO.Binary.header` attribute. In the second part, we have the load commands table which can be iterated using :attr:`lief.MachO.Binary.load_commands`
, then we can optionally have padding or free space. Finally, we have the raw data (assembly code, rebase bytecode, signature, ...)
then, we can optionally have padding or free space. Finally, we have the raw data (assembly code, rebase bytecode, signature, ...)
Load commands like :class:`~lief.MachO.SegmentCommand` or :class:`~lief.MachO.DyldInfo` can be associated with *raw data* that are located after the load command table and the padding section.
The padding section is used by OSX to sign the binary after the compilation by adding a custom command. The ``codesign`` utility extends the *raw data* area with the signature and adds a ``LC_CODE_SIGNATURE`` or a ``LC_DYLIB_CODE_SIGN_DRS`` command in the padding area.