Subject: Re: Persistent WEP keys
To: Atsushi Onoe <firstname.lastname@example.org>
From: Feico Dillema <email@example.com>
Date: 03/09/2001 15:08:08
On Fri, Mar 09, 2001 at 05:14:19PM +0900, Atsushi Onoe wrote:
> > Hrumpf! I spoke to quickly again. I had tested with a 1.5.x kernel but
> > looked at -current source. I'm sorry for wasting your resources here
> > somewhat. I can get my card to use the persistent key with -current
> > kernel, simply by configuring an arbitrary temporary key, like:
> > ifconfig an0 nwid "blah" nwkey " " up
> Wow! I didn't know such *feature*. It also works fine for me.
> I guess the firmware automatically switch to persistent key if
> temporary key is invalid.
> > Still, maybe the above split in ifconfig parameters would still be
> > more elegant?
> What should happen if user delete key and enable wep simultaneously?
> ifconfig an0 wep -nwkey temp -nwkey persist
What will happen I think (at least with the an driver/card) is that it
will just fail to connect to any network. Having no key should be
equivalent to having not the right one (for the networks around). But
I am not sure. The same way I am not entirely sure the nwkey " "
should be considered a temporary hack, or causes some trouble (but
works to certain degree) or sub-optimal behaviour. With it on a
-current machine, I get these errors from the driver:
an0: RID 0xff68 access failed
an0: RID 0xff50 access failed
an0: RID 0xff50 record length mismatch -- expected 138, got 8192
an0: RID 0xff50 record length mismatch -- expected 138, got 255
an0: RID 0xff68 record length mismatch -- expected 432, got 8192
on a regular basis. They might be caused (this is just an uninformed
guess) by the card trying the bogus temporary key now and then and
> I'd like to make setting key and enabling wep as an atomic action
> from the command usage point of view.
Fine with me.
> How about this?
> ifconfig <if> nwkey <key> # enable WEP with temporary key <key>
> ifconfig <if> nwkey persist # enable WEP with persistent key
> ifconfig <if> -nwkey # disable WEP (also delete temp key)
> Programming persistent key can be a different interface (anconfig).
I wouldn't like that. I really like these things part of ifconfig and
believe that's where they belong in a way. Maybe we should just use a
different parameter for persistent and temporary keys, i.e. like
ifconfig <if> nwkey <key> # enable WEP with temporary key <key>
ifconfig <if> -nwkey # disable WEP (also delete temp key, but not persisten one if any)
ifconfig <if> nwkey persist [key] # enable WEP with persistent key, with optional argument for setting it