0

I'm currently studying return-oriented programming and I only have the basic knowledge of daily uses for linux. I am using Ubuntu 32-bit server 12.04. While I disabled aslr and am trying to get a segmentation fault(just by inserting like, 400 A's) on the program, it only shows me the following in gdb:

[Inferior 1 (process 1965) exited with code 015]

edit: the code is a simple one:

#include <stdio.h>
int main(int argc, char *argv[])
{
char buf[256];
memcpy(buf, argv[1],strlen(argv[1]));
printf(buf);
}

When I just do it on the command line, it doesn't show me anything. How do I make it so that it gives me a segmentation fault? Plus, does anyone know if this is the appropriate OS version for running ctf problems?

Thanks.

0 Answers0