get_network requests yield poor informatoin for preseeding networkconfig form
Kel Modderman
kel
Wed Jan 23 06:27:52 PST 2008
Hi Jouni,
When doing some work on wpa_gui, I noticed that when editing a network
configuration that uses no wep, pre-shared key or other means of
authentication, the network form preselects WEP Encryption in the combobox
(and other enabling of widgets).
When investigating why, I see that NetworkConfig::paramsFromConfig() calls a
few GET_NETWORK requests for group, pairwise, key_mgmt and so on, but these
seem to be returning information that is not really true for the network in
question in most cases.
For example:
# cat /etc/wpa_supplicant/conf.ath0
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid=""
key_mgmt=NONE
id_str=""
}
network={
ssid="kelnet"
key_mgmt=NONE
wep_key0=xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
id_str="kelnet"
}
> status
bssid=xx:xx:xx:xx:xx:xx
ssid=kelnet
id=1
id_str=kelnet
pairwise_cipher=WEP-104
group_cipher=WEP-104
key_mgmt=NONE
wpa_state=COMPLETED
ip_address=192.168.0.5
> get_network 1 proto
WPA RSN
> get_network 1 key_mgmt
NONE
> get_network 1 pairwise
CCMP TKIP
>
The same data is returned for network id 0 for the above get_network requests.
This causes miscalculations in what forms to prepare/preselect/present to
user at edit network time.
I tried to edit a WPA-PSK2 config:
network={
ssid="wpanetwork"
psk="abcdefghijklmnop"
}
And it preselects WPA2-EAP, disables PSK input field, until correct settings
are chosen from Authentication combobox.
I'm using 0.6.2 plus all the patches I sent you, one that Dan sent recently
but no other difference.
Can you reproduce and do you know where the problem may be?
Thanks, Kel.
More information about the Hostap
mailing list