Skip to content

Instantly share code, notes, and snippets.

View kaiwan's full-sized avatar

Kaiwan N Billimoria kaiwan

View GitHub Profile
@kaiwan
kaiwan / gcc-security.txt
Last active July 30, 2024 04:52 — forked from jrelo/gcc-security.txt
GCC security related flags reference.
Source material:
http://security.stackexchange.com/questions/24444/what-is-the-most-hardened-set-of-options-for-gcc-compiling-c-c
https://wiki.gentoo.org/wiki/Hardened_Gentoo
https://wiki.debian.org/Hardening
================================================================================================================>
GCC Security related flags and options:
CFLAGS="-fPIE -fstack-protector-all -D_FORTIFY_SOURCE=2"
LDFLAGS="-Wl,-z,now -Wl,-z,relro"
@kaiwan
kaiwan / 0_reuse_code.js
Created March 3, 2014 06:35
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console