2022-11-07 13:22:59 -08:00
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
2023-03-07 16:59:14 -05:00
|
|
|
namespace BinaryObjectScanner.Models.NewExecutable
|
2022-11-03 23:32:35 -07:00
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// The segmented EXE header contains general information about the EXE
|
|
|
|
|
/// file and contains information on the location and size of the other
|
|
|
|
|
/// sections. The Windows loader copies this section, along with other
|
|
|
|
|
/// data, into the module table in the system data. The module table is
|
|
|
|
|
/// internal data used by the loader to manage the loaded executable
|
|
|
|
|
/// modules in the system and to support dynamic linking.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <see href="http://bytepointer.com/resources/win16_ne_exe_format_win3.0.htm"/>
|
2022-12-27 17:12:55 -08:00
|
|
|
public sealed class Executable
|
2022-11-03 23:32:35 -07:00
|
|
|
{
|
|
|
|
|
/// <summary>
|
2022-11-04 21:05:03 -07:00
|
|
|
/// MS-DOS executable stub
|
2022-11-03 23:32:35 -07:00
|
|
|
/// </summary>
|
2022-11-04 21:05:03 -07:00
|
|
|
public MSDOS.Executable Stub { get; set; }
|
2022-11-03 23:32:35 -07:00
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// New Executable header
|
|
|
|
|
/// </summary>
|
|
|
|
|
public ExecutableHeader Header { get; set; }
|
|
|
|
|
|
2022-11-03 23:38:51 -07:00
|
|
|
/// <summary>
|
|
|
|
|
/// Segment table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public SegmentTableEntry[] SegmentTable { get; set; }
|
|
|
|
|
|
2022-11-04 09:56:06 -07:00
|
|
|
/// <summary>
|
|
|
|
|
/// Resource table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public ResourceTable ResourceTable { get; set; }
|
2022-11-04 09:40:29 -07:00
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Resident-Name table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public ResidentNameTableEntry[] ResidentNameTable { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Module-Reference table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public ModuleReferenceTableEntry[] ModuleReferenceTable { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Imported-Name table
|
|
|
|
|
/// </summary>
|
2022-11-07 13:22:59 -08:00
|
|
|
public Dictionary<ushort, ImportedNameTableEntry> ImportedNameTable { get; set; }
|
2022-11-04 09:40:29 -07:00
|
|
|
|
2022-11-04 10:09:09 -07:00
|
|
|
/// <summary>
|
|
|
|
|
/// Entry table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public EntryTableBundle[] EntryTable { get; set; }
|
2022-11-04 09:40:29 -07:00
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Nonresident-Name table
|
|
|
|
|
/// </summary>
|
|
|
|
|
public NonResidentNameTableEntry[] NonResidentNameTable { get; set; }
|
2022-11-03 23:32:35 -07:00
|
|
|
}
|
|
|
|
|
}
|