Q:

stack overflow code in c for writing exploit

I am attempting to launch a shell in my Linux environment (BT3) but it keeps seg faulting. The method that I'm using is out of The Shellcoder's HandBook. Note that all of this is straight out of the text.
For more reference: http://www.backtrack-linux.org/forums/old-pentesting/15508-stuck-eip-buffer-overflow.html

A:

Many buffer overflow exploits have been fixed in modern operating system patches.  It's likely you're seg faulting because the operating system is detecting a buffer overrun and killing your process.

