DOS header Structure
Typedef struct _ image_dos_header {// dos. EXE Header
+ 0 h word e_magic; // ***** dos Executable File tag *****
+ 2 H word e_cblp; // bytes on last page of File
+ 4 h word e_cp; // pages in file
+ 6 h word e_crlc; // relocations
+ 8 h word e_cparhdr; // size of header in paragraphs
+ 0ah word e_minalloc; // minimum extra paragraphs needed
+ 0ch word e_maxalloc; // maximum extra paragraphs needed
+ 0eh word e_ss; // dos code initialization stack SS
+ 10 h word e_sp; // dos code initialization Stack pointer sp
+ 12 h word e_csum; // checksum
+ 14 h word e_ip; // dos code initialization command entry [pointer IP]
+ 16 h word e_cs; // dos code initialization stack entry
+ 18 h word e_lfarlc; // file address of relocation table
+ 1ah word e_ovno; // overlay number
+ 1ch word e_res [4]; // Reserved Words
+ 24 h word e_oemid; // OEM identifier (for e_oeminfo)
+ 26 h word e_oeminfo; // OEM information; e_oemid specific
+ 29 H word e_res2 [10]; // Reserved Words
+ 3ch long e_lfanew; // ***** points to the PE File Header *****
} Image_dos_header, * pimage_dos_header;
DOS header Structure