summaryrefslogtreecommitdiff
path: root/other/3wahas/3wahas.c
diff options
context:
space:
mode:
Diffstat (limited to 'other/3wahas/3wahas.c')
-rw-r--r--other/3wahas/3wahas.c51
1 files changed, 51 insertions, 0 deletions
diff --git a/other/3wahas/3wahas.c b/other/3wahas/3wahas.c
new file mode 100644
index 0000000..d1a119c
--- /dev/null
+++ b/other/3wahas/3wahas.c
@@ -0,0 +1,51 @@
1/* phoenix - bah, fuckup
2 *
3 * by team teso
4 *
5 *
6 */
7
8#include <stdio.h>
9#include <stdlib.h>
10#include <unistd.h>
11#include <string.h>
12#include <libnet.h>
13#include "common.h"
14#include "network.h"
15#include "packet.h"
16#include "3wahas.h"
17#include "sniff.h"
18
19
20int
21main (int argc, char **argv)
22{
23 char *interface = "eth0";
24 char *src_ip, *dst_ip;
25 u_short dst_prt;
26
27 if (argc != 5) {
28 printf ("usage: %s <ip_src> <ip_dst> <ip_dst_port> <delay>\n\n", argv[0]);
29 exit (EXIT_FAILURE);
30 }
31 src_ip = argv[1];
32 dst_ip = argv[2];
33 dst_prt = atoi (argv[3]);
34
35 if (fork () == 0) {
36 while (1) {
37 pq_syns (src_ip, dst_ip, dst_prt);
38 usleep (atoi (argv[4]));
39 }
40 }
41
42 libnet_seed_prand ();
43
44 printf ("3wahas "VERSION" by "AUTHORS" - rox0ring\n\n");
45
46 sniff_new (interface, dst_ip);
47
48 exit (EXIT_SUCCESS);
49}
50
51