+ /* frame type */
+ /* management */
+ if(!(w_hdr->frame_ctl & 0x0c)) {
+ if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_REQ)>0)
+ strcpy(tmp_buf,"association request");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_ASSOC_RESP)>0)
+ strcpy(tmp_buf,"association response");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_REQ)>0)
+ strcpy(tmp_buf,"reassociation request");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_REASSOC_RESP)>0)
+ strcpy(tmp_buf,"reassociation response");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_REQ)>0)
+ strcpy(tmp_buf,"probe request");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_PROBE_RESP)>0)
+ strcpy(tmp_buf,"probe response");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_BEACON)==IEEE802_11_STYPE_BEACON) {
+ beacon_hdr=(struct beacon_struct *)(package+p_o+w_o);
+ beacon_hdr->ssid_s.elementid==0?strcpy(tmp_buf1,"essid = ")
+ :strcpy(tmp_buf1,"ibssid = ");
+ strncpy(tmp_buf2,beacon_hdr->ssid_s.ssid,
+ beacon_hdr->ssid_s.length);
+ tmp_buf2[beacon_hdr->ssid_s.length]='\0';
+ strcpy(tmp_buf,"beacon");
+ add_ssid_2_list(tmp_buf2,my_info_struct->ssid_list);
+ }
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_ATIM)>0)
+ strcpy(tmp_buf,"announcement traffic indication message");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_DISASSOC)>0)
+ strcpy(tmp_buf,"disassociation");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_AUTH)>0)
+ strcpy(tmp_buf,"authentification");
+ else if((w_hdr->frame_ctl & IEEE802_11_STYPE_DEAUTH)>0)
+ strcpy(tmp_buf,"deauthentification");
+ else strcpy(tmp_buf,"impossible situation \%) - go mail the author.");
+ }
+ else strcpy(tmp_buf,"control & data frame type not supported yet");
+ /* print out frame type */