Delphi 2007 supports ASLR and NX
POSTED BY MIKE D1396 ON THURSDAY, 5 APRIL 2007 IN BLOGS
Delphi 2007, available now, supports ASLR and NX.
The CodeGear Delphi 2007 compiler supports ASLR via any of these three techniques:
add the command-line switch --dynamicbase when compiling with dcc32
add the preprocessor command '{$DYNAMICBASE ON}' to the source code
manually OR in the bit in the header, with '{$SETPEOPTFLAGS $40}' in the source code
The CodeGear Delphi 2007 compiler supports NX via this technique:
manually OR in the bit in the header, with '{$SETPEOPTFLAGS $100}' in the source code
The easiest way to enable both ASLR and NX is to do this:
add '{$SETPEOPTFLAGS $140}' to the project source file (.dpr or .dpk)
Thanks to Barry Kelly for prodviding this information!
Partager