From: hackbard Date: Thu, 14 Nov 2002 00:12:33 +0000 (+0000) Subject: - X-Git-Url: https://hackdaworld.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=14af14446a79ff647bc7270d5382fd1d4d98f2cf;p=my-code%2Fhdw-sniff.git - --- diff --git a/hdw-sniff.c b/hdw-sniff.c index 1814857..6ba9c82 100644 --- a/hdw-sniff.c +++ b/hdw-sniff.c @@ -169,27 +169,27 @@ void pcap_process(u_char *info,const struct pcap_pkthdr *pcap_header, /* frame type */ if((w_hdr->frame_ctl & IEEE802_11_STYPE_BEACON)>0) strcpy(tmp_buf,"beacon"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_ATIM)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_ATIM)>0) strcpy(tmp_buf,"announcement traffic indication message"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_DISASSOC)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_DISASSOC)>0) strcpy(tmp_buf,"disassociation"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_AUTH)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_AUTH)>0) strcpy(tmp_buf,"authentification"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_DEAUTH)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_DEAUTH)>0) strcpy(tmp_buf,"deauthentification"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_REQ)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_REQ)>0) strcpy(tmp_buf,"association request"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_RESP)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_RESP)>0) strcpy(tmp_buf,"association response"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_REQ)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_REQ)>0) strcpy(tmp_buf,"reassociation request"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_RESP)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_RESP)>0) strcpy(tmp_buf,"reassociation response"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_REQ)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_REQ)>0) strcpy(tmp_buf,"probe request"); - if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_RESP)>0) + else if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_RESP)>0) strcpy(tmp_buf,"probe response"); - else strcpy(tmp_buf,"unknown"); + else strcpy(tmp_buf,"unknown yet!"); /* print out frame type */ printf("=> %s\n",tmp_buf);