[comp.sys.ibm.pc] .EXE header infor_{_{{_}i_

hoctor@osiris.cso.uiuc.edu (12/16/87)

I am in the process of writing a program the requires me to read past
the header information on a .EXE file, unfortunately I have no way
of knowing how long the header information is.  Could someone:
	  -describe how a .EXE header is set up  -or-
	  -give me a method to calculate the length of the header  -or-
	  -direct me to a source that describes the structure of the
	   header.

To give you some background as to what I am doing:
I am "Coordinator of Microcomputers" for a manufacturing firm and
trying to put some controls on our previously uncontrolled end users.
I have found that there are illegal copies of software that some
users have put on their hard disk ({knowin{{{{gl{y and 
unintentionaly).  What I am trying to do is write a program that will
recusively scan a hard disk for .COM and .EXE files and pull out a 
unique character string that will become an identifying "tag" for that
file.  I need some technique for calculating an offset to read into
the file so that I can {     pull out a 12 character string.  This
string should be a seemingly random sequence of machine instructions.

{
In theory, once this system is complete, I will be able to run this on
any hard disk and it will tell me what software is installed on it. 
Of course this will require that I have a table set up that indicates
what Identification String is associated what file and software
package.  If the system turns out nicely, I would be happy to
distribute it to all you net-landers.  (If it REALLY turns out, I will
sell it! :-))
{
Thanx,
hoctor@osiris