2000-11-21 23:03:56

by Forever shall I be.

[permalink] [raw]
Subject: page 0 mapped memory in ELF binaries

Ok, I'm sure this isn't any sort of show stopper for the 2.4.0 series
(or any other series for that matter, and they probably all have it),
but when mapping memory to page 0 in the program header of an ELF,
linux completely ignores the ph_memsz field.. I've attached a program
to demonstrate.. nasm is needed for compilation... (nasm is available
at http://www.cryogen.com/Nasm/)

Just so you know, what I want to do is have x bytes at 0x0, when
only y bytes are in the file, and y will almost always be less than x..

And yes, this is a little odd, but I really want to do it ;)

--
Zinx Verituse (See headers for gpg/pgp key info)


Attachments:
(No filename) (656.00 B)
zeromap.asm (3.12 kB)
Download all attachments