Last active
September 29, 2019 09:57
-
-
Save DiegoCaridei/6e8fb862b4c75255fa00222714e13719 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <unistd.h> | |
int overflow () { | |
char buffer [500]; | |
int userinput; | |
userinput =read(0, buffer,700); | |
printf("\nUser provided %d bytes. Buffer content is %s\n", userinput, buffer); | |
return 0; | |
} | |
int main(int argc, const char * argv[]) { | |
overflow (); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment