NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: wireless configuration



Youri Mouton <youri.mout%gmail.com@localhost> writes:

> On 24/04/16 09:23, Graham Jenkins wrote:
>> With OpenBSD, one can completely configure a wireless interface by creating a file like:
>> 
>> == /etc/hostname.urtw0
>> nwid 'My SSID'
>> wpakey my_key
>> dhcp
>> ==
>> 
>> This is Really Neat if you are using USB wifi dongles .. it will only
>> get actioned when you insert a 'urtw0' dongle.  And you can have a
>> similar file called /etc/hostname.urtwn0 which will only get actioned
>> when you insert a 'urtwn0' dongle.  No wpa_supplicant file, no
>> entries for wpa_supplicant or dhclient in /etc/rc.local!
>
> Have a look at the -M option in wpa_supplicant(8). You'll need
> NetBSD-current.
> http://netbsd.gw.com/cgi-bin/man-cgi?wpa_supplicant++NetBSD-current
>
> You can use something like this (in rc.conf):
>
> wpa_supplicant_flags="-B -M -i iwn* -c /etc/wpa_supplicant_iwn.conf -M
> -i iwi* /etc/wpa_supplicant_iwi.conf"

To me the point is that wpa_supplicant is hard to configure.  In the old
days, one just specified a nwid and key.  Now, WPA2 is more complicated
than WEP, but from the usual user viewpoint it's mostly the same thing:
a network name and a password.   So it would be really nice if it could
be configured that simply.

I have the feeling wpa_supplicant exists as a process with a config file
partly because some of the things it can do are complicated, and partly
because of structuring the code to be like the entities in the standard.

Overall, I wonder about:

  letting ifconfig store ssid (I would avoid nwid as a term) as it does
  now

  adding a new ifconfig variable wpakey that stores the wpa/wpa2
  password

  letting wpa_supplicant have a mode where it looks for the above and
  does the right thing, without a config file

or alternatively, do none of that and:

  have a new /etc/wpa.conf file that just has a bunch of lines
     "ssid password"
  and have wpa_supplicant's default mode to try to join the first-listed
  ssid on every 802.11 that is up, with no other config file.

and also maybe

  starting wpa_supplicant by default in the auto mode, letting people
  turn it off if they don't want it to run.


Right now you have to put the network in the config file in a syntax
that you have to look up (even thought it isn't that bad) and then you
have to give the right flags to point wpa_supplicant at a particular
interface.  Just running "wpa_supplicant" seems not to work.
So perhaps making it automatic with the current config format would be a
big step in UX.

Attachment: signature.asc
Description: PGP signature



Home | Main Index | Thread Index | Old Index