Systemsicherheit/Assignment 6 - Software Security - Teil 2/ret2libc/ret2libc.c
2024-06-14 15:57:52 +02:00

23 lines
323 B
C

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int vuln(char* input) {
char buff[100];
strcpy(buff, input);
return 0;
}
int main(int argc, char *argv[])
{
if(argc < 2)
{
printf("Syntax: %s <input string>\n", argv[0]);
exit (0);
}
vuln(argv[1]);
return 0;
}