What is .exe file and what kind of info does it store?

RiteshSingh

Beta member
Messages
1
I have all the knowledge that it is a binary file, its a kind of program like (notepad.exe), etc. What i really wanted to know is that what kind of information does it store. What is the difference between .com files and .exe files ?
I know its store all the information regarding address of stack pointer , code segment...what i doubt is mentioned below:
When i compile and link a code, its assembly code is generated. Now assembly code can easily be converted into direct binary . so does it mean that all these binary is stored in the .exe file.

One another question is that how exactly an .exe is loaded in ram., say in widows?

I request that if any body can provide me detail as much as possible ..it will be a great help ...waiting anxiously for a reply.

Thanks and regards
Ritesh
 
A little DOS history may help you understand the first question. Originally DOS had only two types of executable files, *.exe and *.com were the extensions used. The differences go beyond that. A *.com file was always smaller than 64KB total and had no header information other than blank space preceding the first instruction which was always located an offset of 100h bytes into the file.
An *.exe file was more complex and did not have the 64KB restriction. The header was composed of data blocks that held the information DOS needed to load the program into RAM correctly to be executed. It included such things as total size of instructions, starting offset of first instruction in file and the same information for any internal data members of the program.
The same sort of differences still hold true under Windows.For current information, check out the Knowledge Base articles at msdn.com.
One more type of executable file now exists, the *.dll for Windows. It allows you to separately program sub routines that can be independantly loaded and called for use by different programs at runtime from one file by any program that has the data needed to load it and make the calls. It is intended to make the OS more efficient in hard disk space and speed. I hope this will help you find what you want to know.
 
@Marxsoccer-*.com not anymore Internet than *.exe, they did/do the same thing, just load into the computer's memory differently and can be different maximum sizes.
 
by opening a .com, it isn't allowing anything to be downloaded for the most part, you would need a .exe to load..
 
MarxSoccer said:
by opening a .com, it isn't allowing anything to be downloaded for the most part, you would need a .exe to load..

.com in this context is a filetype. It's an old filetype used in the early days of MS-DOS, you'll find command.com on versions of Windows up to 2000.
 
.exe is an extention used to group executables together on Windows.

Just because a file extention is something doesn't guarantee that it's that type of file. For example. You can save a .txt file to .exe. Doesn't mean it's going to execute. You see this more in *Nix.
 
It's pretty much a program; executable. It could be x.exe.jpg and still may be a program. Formats like that often occur in IRC channel and It's guaranteed a trojan/harmful software.
 
Back
Top Bottom