2 * parse.c - parsing of pcap packages
4 * author: hackbard@hackdaworld.dyndns.org
12 /* all the parsing stuff will go here
14 * different protocols should get to seperated files though ...
17 void parse_package(unsigned char *ptr,const struct pcap_pkthdr *pcap_header,const unsigned char *package) {
28 if(info->dump_fd!=0) {
29 ret=write(info->dump_fd,pcap_header,sizeof(struct pcap_pkthdr));
30 if(ret!=sizeof(struct pcap_pkthdr))
31 display_console(info->display,"warning, pcap header write failed!");
32 ret=write(info->dump_fd,package,pcap_header->caplen);
33 if(ret!=pcap_header->caplen)
34 display_console(info->display,"warning, package write failed!");
37 /* maybe there is offset to the actual ieee802.11 frame,
38 for example prism header ... */
41 /* go on parsing frame ctl header here ... */