diff --git a/BurnOutSharp.Models/PortableExecutable/Executable.cs b/BurnOutSharp.Models/PortableExecutable/Executable.cs index 2c7c8caa..cb0cb249 100644 --- a/BurnOutSharp.Models/PortableExecutable/Executable.cs +++ b/BurnOutSharp.Models/PortableExecutable/Executable.cs @@ -56,6 +56,6 @@ namespace BurnOutSharp.Models.PortableExecutable /// public DelayLoadDirectoryTableEntry[] DelayLoadDirectoryTable { get; set; } - // TODO: Left off at "Export Directory Table" + // TODO: Left off at "Export Address Table" } } diff --git a/BurnOutSharp.Models/PortableExecutable/ExportDirectoryTable.cs b/BurnOutSharp.Models/PortableExecutable/ExportDirectoryTable.cs new file mode 100644 index 00000000..bca2ac26 --- /dev/null +++ b/BurnOutSharp.Models/PortableExecutable/ExportDirectoryTable.cs @@ -0,0 +1,76 @@ +using System.Runtime.InteropServices; + +namespace BurnOutSharp.Models.PortableExecutable +{ + /// + /// The export symbol information begins with the export directory table, + /// which describes the remainder of the export symbol information. The + /// export directory table contains address information that is used to resolve + /// imports to the entry points within this image. + /// + /// + [StructLayout(LayoutKind.Sequential)] + public class ExportDirectoryTable + { + /// + /// Reserved, must be 0. + /// + public uint ExportFlags; + + /// + /// The time and date that the export data was created. + /// + public uint TimeDateStamp; + + /// + /// The major version number. The major and minor version numbers can be set + /// by the user. + /// + public ushort MajorVersion; + + /// + /// The minor version number. + /// + public ushort MinorVersion; + + /// + /// The address of the ASCII string that contains the name of the DLL. This + /// address is relative to the image base. + /// + public uint NameRVA; + + /// + /// The starting ordinal number for exports in this image. This field specifies + /// the starting ordinal number for the export address table. It is usually set + /// to 1. + /// + public uint OrdinalBase; + + /// + /// The number of entries in the export address table. + /// + public uint AddressTableEntries; + + /// + /// The number of entries in the name pointer table. This is also the number of + /// entries in the ordinal table. + /// + public uint NumberOfNamePointers; + + /// + /// The address of the export address table, relative to the image base. + /// + public uint ExportAddressTableRVA; + + /// + /// The address of the export name pointer table, relative to the image base. + /// The table size is given by the Number of Name Pointers field. + /// + public uint NamePointerRVA; + + /// + /// The address of the ordinal table, relative to the image base. + /// + public uint OrdinalTableRVA; + } +}