[fpc-pascal][OT] Changing Executables.

Adam Naumowicz adamn at math.uwb.edu.pl
Fri Dec 22 13:59:09 CET 2000


On Fri, 22 Dec 2000, Marco van de Voort wrote:

> > I am trying to find a way to include my own code
> > in an existing executable in a way that my code
> > is executed first and after that, the original
> > executable is executed. I have very little
> > knowledge of assembler, but (I think) when I
> > write a C(++) app and then compile it to
> > assembler, and someone can tell me how I can
> > modify existing executable in a way that my app
> > is executed first, I don't need to have very much
> > assembler knowledge.
>
> Unless possibilities to expand a program (dll hooks etc, plugin support)
> already exists, there is nothing possible without very thorough assembler
> knowledge.

There is a solution some lame pseudo-virus writers use to achive a similar
goal. You just write a starter program, that is concatenated with the
program you want to run first, the original program, and some additional
information (sizes of glued programs). The resulting program must
extract from its body two programs you added together using incorporated
information, and simply run them.
Hope it helps,

Adam Naumowicz

--------------------------------------
WWW: http://math.uwb.edu.pl/~adamn/
--------------------------------------





More information about the fpc-pascal mailing list