Skip to content

Instantly share code, notes, and snippets.

@amigojapan
Created September 6, 2018 05:45
Show Gist options
  • Select an option

  • Save amigojapan/5fae7f6290b78d78cfc88c914fccd4b3 to your computer and use it in GitHub Desktop.

Select an option

Save amigojapan/5fae7f6290b78d78cfc88c914fccd4b3 to your computer and use it in GitHub Desktop.
#include <string.h> │aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
│aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
void premio() │aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
{ │aaaaaaaa
printf("I have altered the programs│
flow\n"); │Program received signal SIGSEGV, Segmen
} │tation fault.
│0x0000006161616161 in ?? () (this is th
int main(int argc, char *argv[]) │e value of EIP beacuse of the letter a)
{ │(gdb)
char buffer[100]; │
if (argc != 2) ├───────────────────────────────────────
{ │where should I insert my shellcode, I n
printf("Use: %s argument\n",arg│eed to find the right point in the stac
v[0]); │k.
return -1; │~
} │~
strcpy(buffer,argv[1]); │~
printf ("%s\n",buffer); │~
return 0; │~
} │~
│~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment