Enigma Group's Hacking Forum



User Info
Welcome, Guest. Please login or register.
May 18, 2012, 07:40:30 AM

Login with username, password and session length
Search:     Advanced search
News
Need a hash cracked? Use the Enigma Group Hash Cracker! It's the largest hash library on the interwebz.
Forum Stats
33911 Posts in 4170 Topics by 38418 Members
Latest Member: cbbyfhxcax
Enigma Group's Hacking Forum  |  General  |  General Computing  |  A very simple explaintion of buffer overflow
« previous next »
Pages: [1] Print
Author Topic: A very simple explaintion of buffer overflow  (Read 154 times)
re6ter
Newbie
*
Offline Offline

Posts: 27
  • Respect: 0

  • Programming Beginner

    « on: January 15, 2012, 06:14:36 PM »
    0

    note: I DID NOT WRITE THIS! I FOUND IT ON REDDIT
    Original: http://tiny.cc/ELI5

    Quite an outstanding explaintion that is very simple to understand.

    Quote
    Imagine a choose-your-own-adventure book (i.e. "If you choose to go left, turn to page 10. If you go right, turn to page 20). You have sneakily inserted a page 30 which tells the reader to give you all your money.
    At the start of the book there is a blank page where the reader can make notes. That's your buffer. If you write in a bunch of text on that page, and the reader is too dumb to notice it's happened, you could make your text overflow onto page one, and overwrite the text already there.
    So now, page one says "If you choose to go left, turn to page 30. If you choose to go right, turn to page 30".
    So the reader turns to page 30, and follows the instruction to give you all their money. You have overflowed the buffer to make the reader go to a page of your choosing rather than the legitimate pages.
    The book is your program, the blank page is the buffer, and page 30 is the malicious code. The text you dumped onto the blank page is your exploit code.

    Please add on to this explanation if you can, I am interested in hearing other ways of understanding this concept.   :)
    Logged
    Trying to learn ASM, please send me links to good learning resources!!
    Pages: [1] Print 
    « previous next »
     

    Find Us on Facebook! Find us at Facebook! - Follow Us! Follow us with Twitter! - Make sure to Stumble us! Stumble upon us! - Subscribe! Subscribe to our feed!
    Review enigmagroup.org on alexa.com

    ©Enigma Technology Group Inc. 2005-2012