diff options
Diffstat (limited to 'coff.h')
-rw-r--r-- | coff.h | 24 |
1 files changed, 23 insertions, 1 deletions
@@ -3,6 +3,28 @@ #include <filesystem> namespace COFF { + // COFFHeader.Machine: + const uint16_t IMAGE_FILE_MACHINE_UNKNOWN = 0; + const uint16_t IMAGE_FILE_MACHINE_AMD64 = 0x8664; + + // COFFHeader.Characteristics: + const uint16_t IMAGE_FILE_EXECUTABLE_IMAGE = 0x002; + const uint16_t IMAGE_FILE_LARGE_ADDRESS_AWARE = 0x020; + + // COFFOptionalHeader_Windows.SubSystem + const uint16_t IMAGE_SUBSYSTEM_WINDOWS_CUI = 3; + + // COFFOptionalHeader.Magic + const uint16_t MAGIC_PE32 = 0x010b; + const uint16_t MAGIC_PE32p = 0x020b; + + // SectionHeader.Characteristics + const uint32_t IMAGE_SCN_CNT_CODE = 0x00000020; + const uint32_t IMAGE_SCN_CNT_INITIALIZED_DATA = 0x00000040; + const uint32_t IMAGE_SCN_MEM_EXECUTE = 0x20000000; + const uint32_t IMAGE_SCN_MEM_READ = 0x40000000; + const uint32_t IMAGE_SCN_MEM_WRITE = 0x80000000; + void Dump(std::filesystem::path path); void Create(std::filesystem::path path); -}
\ No newline at end of file +} |