February 28, 2009
I recently wrote a Bash script called checkrelro.sh that can be used to check if Executable and Linkable Format (ELF) executables or processes support the RELRO (Relocation Read-Only) exploit mitigation technique. I extended that script to also support other mitigation techniques. The extended version of the script is now called checksec.sh.
The checksec.sh script is designed to test for the following mitigation techniques: Relocation Read-Only (RELRO), NoExecute (NX), Stack Canaries, Address Space Layout Randomization (ASLR) and Position Independent Executables (PIE).