Executable Properties

When you run checksec, this will show

    Arch:     amd64-64-little
    RELRO:    Partial RELRO
    Stack:    No canary found
    NX:       NX enabled
    PIE:      PIE enabled

Relocation Read-Only

Definition : This feature controls the permissions of the relocation table

  • Full RELRO - ensures that the relocation table is read-only after the program starts

  • Partial RELRO - some parts of the relocation table are still writable

//To Enable Full
gcc -o filename filename.c -Wl,-z,relro,-z,now

//To Enable Partial
gcc -o filename filename.c -Wl,-z,relro

//To Disable
gcc -o filename filename.c

Last updated