Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Kali Linux - An Ethical Hacker's Cookbook

You're reading from   Kali Linux - An Ethical Hacker's Cookbook End-to-end penetration testing solutions

Arrow left icon
Product type Paperback
Published in Oct 2017
Publisher Packt
ISBN-13 9781787121829
Length 376 pages
Edition 1st Edition
Arrow right icon
Author (1):
Arrow left icon
Himanshu Sharma Himanshu Sharma
Author Profile Icon Himanshu Sharma
Himanshu Sharma
Arrow right icon
View More author details
Toc

Table of Contents (13) Chapters Close

Preface 1. Kali – An Introduction FREE CHAPTER 2. Gathering Intel and Planning Attack Strategies 3. Vulnerability Assessment 4. Web App Exploitation – Beyond OWASP Top 10 5. Network Exploitation on Current Exploitation 6. Wireless Attacks – Getting Past Aircrack-ng 7. Password Attacks – The Fault in Their Stars 8. Have Shell Now What? 9. Buffer Overflows 10. Playing with Software-Defined Radios 11. Kali in Your Pocket – NetHunters and Raspberries 12. Writing Reports

Introduction


In a software program, buffer overflow occurs when a program, while writing data to a buffer, overruns the buffer size allocated and starts overwriting data to adjacent memory locations.

A buffer can be considered a temporary area in the memory allocated to a program to store and retrieve data when needed.

Buffer overflows have been known to be exploited since long back.

When exploiting buffer overflows, our main focus is on overwriting some control information so that the flow of control of the program changes, which will allow our code to take control of the program.

Here is a diagram that will give us a basic idea of an overflow happening in a buffer:

 

From the preceding diagram, we can assume this is what a program looks like. Since it is a stack, it starts from bottom and moves toward the top of the stack.

Seeing the preceding diagram, we also notice that the program has a fixed buffer to store 16 letters/bytes of data.

We first enter the 8 characters (1 char=1 byte); on the right...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime