48

Plain DOS executables, in either COM or MZ format, don’t provide this information in their headers (when there is one — COM format doesn’t have a header). The only reliable way to determine whether a program requires a given CPU is to try running it on some less capable system (or emulation, e.g. with PCem which has accurate emulations of different x86 ...


35

Executable files for 16-bit Windows are usually laid out in the now-rather-inaccurately-named New Executable format. Most current Windows executable analysis tools do not support this format; they can only read files in the 32-bit and 64-bit Portable Executable format. This is what the error message you cited is trying to tell you. As for how to extract ...


30

Most large files (over 64KiB) with a .COM extension are really MZ executables; the DOS loader doesn’t care whether the extension is .EXE or .COM, it uses the MZ signature to identify the format. This is the only documented way for a .COM file larger than 64KiB to work, so it’s the only approach which can be relied upon. However it is possible to build a ....


19

As others have mentioned, “Program too big to fit in memory” means that DOS can’t find a large enough memory block to fit the amount of memory that your program’s header requests. This can be either because you have too little available conventional memory (extended memory isn’t taken into account), or because your executable is corrupted. To answer your ...


18

DOS programs always start in real mode (or an emulation thereof), so it’s best to start disassembling them assuming that. When disassembling, you should assume real mode, with 16-bit data and 16-bit addresses, until the code you’re disassembling changes that. The DOS-based disassemblers I’ve used generally know about the executable formats involved, and don’...


17

There is no easy way. The original DOS "MZ" type executable header do not contain such information about what kind of code it contains or what CPU type it needs. It just contains a binary image that is loaded to memory and information about how to start it in real mode, so there are no separate 16-bit or 32-bit binaries. The binary image may ...


13

If you change the lengths of strings in a binary, or indeed move any part of a binary around in any way, then you’re likely to break it: offsets to the data (and code) that the program expects to find are stored in the binary, and won’t be adjusted when you alter it. Thus changing text (or anything else, including code) while preserving the lengths is ...


10

The simplest way to patch a .com file is DEBUG, which comes with any DOS installation. DEBUG is partially usable for .exe files as well, but cannot reverse their relocation process, and so cannot save them once they have been relocated (If you load them as a plain binary file instead of an executable, you can, however, save them, but have limitations with ...


9

a bit off topic to your actual question but to make your game/exe whatever usable again: Too much memory common on MS-DOS for 32MByte and 64MByte (IIRC some versions use 32 some 64). The memory manager reports negative value of free or total memory causing this problem. To repair simply use Smart Drive and fill memory to it until only 32MByte or slightly ...


9

Is there some simple method for determining if a DOS binary (.exe or .dll) is 16-bit or 32-bit? For one, DOS doesn't know about 32 bit, it's a strict 16 bit system. Second, .DLL are not DOS executables but Windows libraries. The Linux file command just says "executable". Because all EXE start out as 16 bit programs, marked by the magic number &...


9

Given that those files are not regular executables, why were they given the COM extension in the first place? They are executable files. They are loadable binary images. In so far they are exactly like COM files, except, when loaded, they are not loaded at offset 0100h, after a prepared PSP, and started with CS:IP as segment:0100h, but segment:0000h. ...


7

Adding or removing some text has the effect that things coming later in the EXE file are now found at a different absolute location, machine code as well as the EXE file format rely a lot on absolute locations. So, it's important to keep the exact same byte length of the file. So, replacing characters is mostly safe (if you're sure that the bytes are really ...


6

The original Spectrum +3 manual has a comprehensive description of the disk format: http://www.worldofspectrum.org/ZXSpectrum128+3Manual/chapter8pt27.html For TR-DOS, it's worth knowing that the .TRD file format is a simple sector-by-sector dump of the disk contents with no additional headers, so any description of the .TRD format (such as this one on zx-...


6

com files are not segmented (its just single segment). They have limitation that it can not cross 64K of code (filesize). They always starts in real mode but I do not think there is any restriction to switch to protected from the code. So while disassembling set real mode any switching from the code should be recognized by the tool. However that is ...


5

The state of the art in assembly-level debugging of DOS programs is almost certainly SoftICE. I've never used it, but my understanding is that it was for a very long time the tool of choice of software copyright protection scheme crackers, as well as low-level operating system/device driver developers. That said, it may well be overkill for your problem. ...


3

I have an old game I would like to run, but my DOS machine has too much RAM. The most proper way to run DOS applications in Windows is using DOSbox. "Program too big to fit in memory" It may happen that you have corrupt executable. Obviously I would want to be able to have basic debugging functionality as well, breakpoints, watchpoints, etc. In ...


1

There was a tool from Borland that came with Borland Delphi 1.0. You pointed it at an EXE and it would show you all the resources that were embedded in the file. It was extremely useful. I don't remember the name of the application, maybe something like "Resource Viewer" or "Resource Manager"? Maybe something like that. If I recall, ...


1

For reference, I am posting the .txt and .ini files from the exetype program. ********************************************************************* EXETYPE 1.0 is a tool to determine the nature of an executable file. Syntax: EXETYPE <filename> NOTE: EXETYPE does not yet support file wildcards. It is necessary to have the EXETYPE.INI file ...


1

Even within "16-bit mode", various 8086-compatible processors that have appeared over the years have extended the 8086 instruction set with instructions that weren't supported by earlier processors. Programs that only need to run on the later processors may exploit such instructions to perform various tasks more easily and efficiently than would ...


1

There is in the windows nt resource kit, a program called 'exetype'. The 3.1 version is a DOS program, while liter ones, like 3.51, is a win32 program. You type exetype filename.ext to get its type. It even tells you whether it's a vio (command line), or PM program.


1

Since the coco cassette interface used 1200 baud psk audio encoding in it, the tape format of the coco was 4X faster loading files from the tape and the tape files were 1/4th the size of similar files on atari and commodore systems, which used 300 baud afsk encoding. it became common to stack multiple files on a single tape. many magazines sold software ...


1

TR-DOS Files themselves have no header at all. Metadata is stored in the directory section of the disk, along with the filename. The metadata has a type field, which is also the file extension. Depending on this field you interpret some of the other fields in different ways. "B" for Basic programs. "C" for machine code, or any binary file ...


Only top voted, non community-wiki answers of a minimum length are eligible