From fc1461874a6bcecc919f650d1bfb6bf37161c413 Mon Sep 17 00:00:00 2001 From: Roland Reichwein Date: Mon, 9 Nov 2020 14:35:34 +0100 Subject: Fix warnings, consolidate flowgraph/node.h --- coff.h | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'coff.h') diff --git a/coff.h b/coff.h index 401912b..6ee9698 100644 --- a/coff.h +++ b/coff.h @@ -3,6 +3,28 @@ #include 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 +} -- cgit v1.2.3