Added Mach-O file format

This commit is contained in:
2024-08-11 21:15:47 +02:00
parent cc215a27c7
commit 58f010b81a
10 changed files with 266 additions and 4 deletions

34
src/macho/LoadCommand.go Normal file
View File

@ -0,0 +1,34 @@
package macho
type LoadCommand uint32
const (
LcSegment LoadCommand = 0x1
LcSymtab LoadCommand = 0x2
LcThread LoadCommand = 0x4
LcUnixthread LoadCommand = 0x5
LcDysymtab LoadCommand = 0xB
LcDylib LoadCommand = 0xC
LcIdDylib LoadCommand = 0xD
LcLoadDylinker LoadCommand = 0xE
LcIdDylinker LoadCommand = 0xF
LcSegment64 LoadCommand = 0x19
LcUuid LoadCommand = 0x1B
LcCodeSignature LoadCommand = 0x1D
LcSegmentSplitInfo LoadCommand = 0x1E
LcRpath LoadCommand = 0x8000001C
LcEncryptionInfo LoadCommand = 0x21
LcDyldInfo LoadCommand = 0x22
LcDyldInfoOnly LoadCommand = 0x80000022
LcVersionMinMacosx LoadCommand = 0x24
LcVersionMinIphoneos LoadCommand = 0x25
LcFunctionStarts LoadCommand = 0x26
LcDyldEnvironment LoadCommand = 0x27
LcMain LoadCommand = 0x80000028
LcDataInCode LoadCommand = 0x29
LcSourceVersion LoadCommand = 0x2A
LcDylibCodeSignDrs LoadCommand = 0x2B
LcEncryptionInfo64 LoadCommand = 0x2C
LcVersionMinTvos LoadCommand = 0x2F
LcVersionMinWatchos LoadCommand = 0x30
)