MS-DOS EXE

From Just Solve the File Format Problem
(Difference between revisions)
Jump to: navigation, search
(Identification)
(Added Kaitai Struct link)
(8 intermediate revisions by 4 users not shown)
Line 3: Line 3:
 
|subcat=Executables
 
|subcat=Executables
 
|extensions={{ext|exe}}
 
|extensions={{ext|exe}}
 +
|pronom={{PRONOM|x-fmt/409}}
 +
|kaitai struct=dos_mz
 
}}
 
}}
'''MS-DOS EXE''' is an executable file format used mainly by [[MS-DOS]]. It is the successor to [[DOS executable (.com)|COM]]. A number of other [[EXE|EXE formats]] are based on it.
+
'''MS-DOS EXE''', also known as '''MZ''' format, is an executable file format used mainly by [[MS-DOS]]. It is the successor of [[DOS executable (.com)|COM]]. A number of other executable formats are extensions of it; see [[EXE]] for those formats.
 
+
Its name has many variations, such as '''DOS MZ executable'''. It is also called '''MZ''', though that name might include hybrid formats ([[NE]], [[PE]], etc.) that also use the "MZ" signature.
+
  
 
== Identification ==
 
== Identification ==
An MS-DOS EXE file begins with an ASCII signature of "<code>MZ</code>" or, rarely, "<code>ZM</code>". The 16-bit integer at offset 24 (relocation table offset) is ''usually'' (but apparently not always) less than 64, and at least 28. A value of 64 or more, or 0, suggests the format may not be MS-DOS EXE.
+
An MS-DOS EXE file begins with an ASCII signature of "{{magic|MZ}}" (or, rarely, "{{magic|ZM}}"), followed by a series of 16-bit fields. The field at offset 24 (the ''relocation table offset'') is ''usually'' (but apparently not always) less than 64, and at least 28. A value of 64 or more, or 0, suggests the format may not be MS-DOS EXE.
  
 
It's not clear whether there is any completely reliable way to identify an MS-DOS EXE, except in the negative (i.e. it begins with "MZ", and is not a valid [[NE]], [[PE]], etc., file).
 
It's not clear whether there is any completely reliable way to identify an MS-DOS EXE, except in the negative (i.e. it begins with "MZ", and is not a valid [[NE]], [[PE]], etc., file).
Line 17: Line 17:
 
* [http://wiki.osdev.org/MZ MZ], from the OSDev Wiki
 
* [http://wiki.osdev.org/MZ MZ], from the OSDev Wiki
 
* http://www.delorie.com/djgpp/doc/exe/
 
* http://www.delorie.com/djgpp/doc/exe/
 +
* [http://www.textfiles.com/programming/FORMATS/exefs.pro DOS EXE format]
 +
* [http://www.mitec.cz/exe.html EXE Explorer utility]
 +
* [http://www.ctyme.com/intr/rb-2939.htm Ralf Brown's Interrupt Reference] has an extensive list of (mostly older) MZ-based executable formats
  
 
[[Category:Microsoft]]
 
[[Category:Microsoft]]
 +
[[Category:MS-DOS]]

Revision as of 15:02, 30 June 2017

File Format
Name MS-DOS EXE
Ontology
Extension(s) .exe
PRONOM x-fmt/409
Kaitai Struct Spec dos_mz.ksy

MS-DOS EXE, also known as MZ format, is an executable file format used mainly by MS-DOS. It is the successor of COM. A number of other executable formats are extensions of it; see EXE for those formats.

Identification

An MS-DOS EXE file begins with an ASCII signature of "MZ" (or, rarely, "ZM"), followed by a series of 16-bit fields. The field at offset 24 (the relocation table offset) is usually (but apparently not always) less than 64, and at least 28. A value of 64 or more, or 0, suggests the format may not be MS-DOS EXE.

It's not clear whether there is any completely reliable way to identify an MS-DOS EXE, except in the negative (i.e. it begins with "MZ", and is not a valid NE, PE, etc., file).

Links

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox