On 3/2/20, John Selbie wrote: > And I just discovered that recompiling with this added to the g++ command > line: > > -Xlinker --dynamicbase > > Seems to work. Or at the least, triggers the process to show up in Process > Explorer as ASLR? > > Good idea to continue with this?
I haven't looked at this in ages, but for gcc I use LDFLAGS="${LDFLAGS} -Wl,--nxcompat" # https://en.wikipedia.org/wiki/Data_Execution_Prevention # Enable DEP with -Wl,--nxcompat LDFLAGS="${LDFLAGS} -Wl,--dynamicbase,--export-all-symbols" # https://en.wikipedia.org/wiki/Address_space_layout_randomization # https://stackoverflow.com/questions/24283918/how-can-i-enable-aslr-dep-and-safeseh-on-an-exe-in-codeblocks-using-mingw # ASLR with gcc has a problem: -Wl,--dynamicbase doesn't emit the necessary relocation table. # As a workaround, you can pass -Wl,--dynamicbase,--export-all-symbols Regards, Lee -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple