New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 801752 link

Starred by 2 users

Issue metadata

Status: Untriaged
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

wifi: wpa_supplicant: Add string-ified versions of error codes in the logs to ease debugging

Project Member Reported by kirtika@google.com, Jan 13 2018

Issue description

Filed based on log analysis from internal bug b/67050077, comment #80.

On a deauthentication or disconnect event, wpa-supplicant sends out a reason code like so. Other messages (don't have an example off-hand), may contain a status code.

These enums are defined in include/linux/ieee80211.h (enum ieee80211_reasoncode) and helpful translations are available on AP vendor sites like so: https://community.arubanetworks.com/t5/Technology-Blog/802-11-Reason-Codes-and-Status-Codes/ba-p/257893

We should add the string version of the error to wpa-supplicant and print it out. Otherwise, log snippets like the below will be ignored by non-wifi folks reading the logs, and even wifi folks have to look up an external site to continue. In the case below, error code 7 means that a 'class 3 frame' (a category of packets allowed only after the client/chromebook has associated with an AP) was sent by a "non-associated station". This implies the AP either forgot that it associated us, or we sent the frame prematurely, since earlier in the logs, we do see the Chromebook claiming to have associated and gotten a successful assoc response. 

2018-01-11T15:07:11.671893-05:00 DEBUG wpa_supplicant[703]: nl80211: Drv Event 20 (NL80211_CMD_DEL_STATION) received for wlan0
2018-01-11T15:07:11.671904-05:00 DEBUG wpa_supplicant[703]: nl80211: Delete station 40:01:7a:80:98:f8
2018-01-11T15:07:11.679385-05:00 DEBUG wpa_supplicant[703]: nl80211: Drv Event 39 (NL80211_CMD_DEAUTHENTICATE) received for wlan0
2018-01-11T15:07:11.679395-05:00 DEBUG wpa_supplicant[703]: nl80211: Deauthenticate event
2018-01-11T15:07:11.679404-05:00 DEBUG wpa_supplicant[703]: wlan0: Event DEAUTH (12) received
2018-01-11T15:07:11.679427-05:00 DEBUG wpa_supplicant[703]: wlan0: Deauthentication notification
2018-01-11T15:07:11.679436-05:00 DEBUG wpa_supplicant[703]: wlan0:  * reason 7
2018-01-11T15:07:11.679447-05:00 DEBUG wpa_supplicant[703]: wlan0:  * address 40:01:7a:80:98:f8
2018-01-11T15:07:11.679454-05:00 DEBUG wpa_supplicant[703]: Deauthentication frame IE(s) - hexdump(len=0): [NULL]
2018-01-11T15:07:11.679465-05:00 NOTICE wpa_supplicant[703]: wlan0: CTRL-EVENT-DISCONNECTED bssid=40:01:7a:80:98:f8 reason=7
2018-01-11T15:07:11.679472-05:00 DEBUG shill[1302]: [VERBOSE2:device.cc(296)] /device/wlan0 EnableIPv6


This should be a patch that we can upstream. 

 

Comment 1 by kirtika@google.com, Jan 13 2018

Owner: ----
Status: (was: Accepted)
This bug had an unsupported status. Updating to Untriaged so someone will reevaluate.
Status: Untriaged
Labels: Enterprise-Triaged

Sign in to add a comment