From aac4f0a3f47f66a35722e564a2e57c20cc8a70ee Mon Sep 17 00:00:00 2001 From: hackbard Date: Tue, 23 Aug 2005 13:06:46 +0000 Subject: [PATCH] small fixes in documentation + initial checkin of wep - crack tool --- README | 3 +- wep.c | 118 +++++++++++++++++++++++++++++++++++++++++++++++++++------ wep.h | 32 ++++++++++++++++ 3 files changed, 141 insertions(+), 12 deletions(-) create mode 100644 wep.h diff --git a/README b/README index ab0d0c7..4f799a4 100644 --- a/README +++ b/README @@ -10,7 +10,8 @@ install - required: - my minimalistic apis (get it via cvs from hackdaworld.org) - - libpcap (freshmeat may help) + - ncurses, libpcap (freshmeat may help) + - flite - wlan card supporting monitor mode - build: (an example) diff --git a/wep.c b/wep.c index 886ac37..8686469 100644 --- a/wep.c +++ b/wep.c @@ -1,25 +1,121 @@ /* * - * wep.c - bruteforce wep key + * wep.c - wordlist/bruteforce wep key attack * */ +#include "wep.h" + #include #include #include #include -#define MAX_C 20 +#include + +#include "network.h" +#include "list.h" +#include "event.h" + +int usage(void) { + puts("usage:"); + put(""); + puts("-p "); + puts("-s "); + puts("-f /path/to/flite"); + puts("-w /path/to/wordlist"); + return 1; +} + +int main(int argc,char **argv) { + + /* data */ + t_wep wep; + int i; + time_t time; + char buf[MAX_BUF]; + unsigned char text[MAX_TEXT]; + + /* default values */ + memset(&wep,0,sizeof(t_wep)); + wep.port=PORT; + strncpy(wep.flite,"/usr/bin/flite",MAX_C_FLITE); + strncpy(wep.savefile,"",MAX_C_SF); + strncpy(wep.wordlist,"",MAX_C_WL); + + time(&time); + + /* parse argv */ + for(i=0;i0) - c=read(file_fd,my_buf,MAX_C); - for(i=0;i