mirror of
https://github.com/adulau/aha.git
synced 2024-12-26 18:56:14 +00:00
Add insulting program
This commit is contained in:
parent
6b61d01bb4
commit
efcbc9b988
1 changed files with 26 additions and 0 deletions
26
aha/insult.c
Normal file
26
aha/insult.c
Normal file
|
@ -0,0 +1,26 @@
|
|||
/*
|
||||
* Insulting program that should be installed on the honeypot.
|
||||
* The kernel then swaps the filename for do_execve with this one
|
||||
*
|
||||
* (c) 2010 Gerard Wagener
|
||||
* LICENSE GPL
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#define N 4
|
||||
char* list[] = {"Fuck you",
|
||||
"Is that all? I want to do more ...",
|
||||
"Go away",
|
||||
"I love you"};
|
||||
|
||||
int main(int argc, char* argv[]){
|
||||
int idx;
|
||||
if (argc==2){
|
||||
idx=atoi(argv[1]);
|
||||
if ((idx>=0) && (idx<N))
|
||||
printf("%s\n",list[idx]);
|
||||
return 0;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
Loading…
Reference in a new issue