Skip to main content

Questions tagged [buffer-overflow]

A buffer overflow, or buffer overrun, is an anomaly where a program, while writing data to a buffer, overruns the buffer's boundary and overwrites adjacent memory.

Filter by
Sorted by
Tagged with
3 votes
1 answer
1k views

Background: So when exploiting a Buffer Overflow vulnerability, the attacker needs to not only generate the payload (Let's say to create a binding shell), but also set up the corrupted buffer with ...
0x5929's user avatar
  • 375
3 votes
1 answer
8k views

Background: Currently trying to exploit a BoF vulnerability. After setting up the environment, running a compiled C program that contains the strcpy function, I disassembled the program as it's ...
0x5929's user avatar
  • 375
6 votes
1 answer
581 views

I have a 32 bit linux binary that is susceptible to a buffer overflow. I figured out I need to input 1040 bytes before I can control the EIP register. I have a shellcode size of 28 bytes. How do I ...
user1710563's user avatar
2 votes
2 answers
4k views

I've written a vulnerable program (below) and some shellcode (also below) to use in a buffer overflow exploit. I've had the same problems as in this link, and solved those using the answers there (-z ...
Henrik Oldcorn's user avatar
2 votes
1 answer
2k views

i'm having problem to buffer overflow a simple c program that takes input from command line, this is the main.c code: #include <stdio.h> #include <string.h> void func(char *name) { ...
Marco_81's user avatar
19 votes
5 answers
6k views

I had an interesting conversation with a pentester who told me he had found a buffer overflow in Wordpress. The person in question was really adamant that this was true. The client is a bit skeptical ...
Wealot's user avatar
  • 929
-2 votes
2 answers
5k views

Why in buffer overflow attacks do we reverse the address? Why do we use little endian format?
Inj3ct0r's user avatar
1 vote
2 answers
7k views

I'm new to secure code review. I know that strlen will calculates the length until it finds a null character. This is a part of a larger code. char* executeMount(char* password, char* path, int ...
Rochelle's user avatar
1 vote
1 answer
1k views

I am attempting to learn about buffer overflows. I have written a simple C program that calls a function called checkpw() which allocates a char array of 10 bytes large. When I analyze the op code I ...
Matthew's user avatar
  • 121
1 vote
1 answer
2k views

I know that upon a overflow, the stack gets partially overwritten, but I do not understand why registers such as EIP or RIP get changed in this process. How come some registers are modified by such ...
Ra'Jiska's user avatar
  • 229
2 votes
1 answer
579 views

I'm looking at the following code and am trying to figure out how this bug would be helpful for something like launching a shell. int func(int i, double *data1, double data2) { double *p = data1; ...
Nathan Reitinger's user avatar
0 votes
1 answer
641 views

I'm trying to understand why my buffer overflow will not work. I've been strugling with this for a few days now, so thought it was about time to ask professionals. I've only recent began to understand ...
Ludisposed's user avatar
0 votes
1 answer
298 views

Why do I see a filler being used in some exploits? Take as an example the code below: exploit = junk + eip + nops + shellcode fill = "\x43"*(BUF_SIZE-len(exploit)) buf = exploit + fill I guess the ...
Fabio's user avatar
  • 183
7 votes
1 answer
3k views

My class is without a textbook, or any structured learning material for that matter. I am doing all my learning through googling and while I am picking it up as I am doing it, it is slow going to be ...
Dylan Slater's user avatar
0 votes
2 answers
1k views

Is it possible to reliably execute arbitrary code from a single overwrite of the Global Offset Table when W^X is enabled? By "reliably" I mean assuming I control only the location pointed to by the ...
camercu's user avatar
  • 103
6 votes
2 answers
2k views

During the security assessment of Android applications, I have encountered multiple instances where .so (Shared Objects) files are present in lib directory. What can be possible security test cases ...
Shiv Sahni's user avatar
1 vote
1 answer
2k views

I'm learning about stack buffer overflow and I'd appreciate help. I'm exploiting simple web server containing this log function. Argument s1 is the input that I supply via HTTP. Server is running on ...
Jan Luxemburk's user avatar
6 votes
2 answers
47k views

So I tried performing a return-to-libc according to https://sploitfun.wordpress.com/2015/05/08/bypassing-nx-bit-using-return-to-libc/ . I found libc's address by using "ldd vuln", and found system's ...
Jonathan's user avatar
3 votes
2 answers
7k views

I'm trying to replicate a simple buffer overflow for which I have the following code (strcpy_ex.c): #include <string.h> int main( int argc, char** argv ) { char buffer[500]; ...
Jausk's user avatar
  • 209
1 vote
0 answers
308 views

I am learning about ROP chains. I am facing a behavior I cannot explain. This is my sample code: int main(int argc, char* args[]) { char text[200]; scanf("%s", text); return 0; } I ...
alive-and-well's user avatar
9 votes
2 answers
1k views

I am trying to exploit a small program. The program looks somewhat like this: int func(void) { char text[100]; scanf("%s", text); return 0; } int foo(unsigned short rand) { char ...
alive-and-well's user avatar
2 votes
1 answer
3k views

I have a assignment where i must exploit a buffer overflow vulnerability on a remote machine. I have only execute permission on the program, so i cant use gdb. I managed to take control of the rip and ...
George Sp's user avatar
  • 151
2 votes
2 answers
554 views

I am trying to detect buffer overflow by using OSSEC (a HIDS software) as mentioned in OSSEC rules example and OSSEC book. How can I configure OSSEC for detect a simple buffer overflow example as the ...
khant's user avatar
  • 201
1 vote
2 answers
2k views

I am currently working on a buffer overflow using my own program to learn the very basics. I have already successfully executed functions already present in the code by overwrite RIP/EIP, but right ...
Ra'Jiska's user avatar
  • 229
0 votes
1 answer
2k views

I have an vulnerable program exploitable through the cmdline: ./vuln $(perl -e 'print "\x90"x22'; cat shell; perl -e 'print "\x90"x22';perl -e 'print "\xf4\xdd\xff\xff\xff\x7f"') ���������������������...
Yvain's user avatar
  • 89

1
3 4
5
6 7
11