[lwlan-devel] wext: when setting keys, use default key if no key is specified

Tormod Volden lists.tormod at gmail.com
Thu Feb 7 15:06:52 EST 2008


On Feb 4, 2008 5:48 PM, Tormod Volden <lists.tormod at gmail.com> wrote:
> Sorry, the old code uses ~IW_ENCODE_NOKEY and (erq->length > 0) to
> check for keys. Maybe I should have done that as well in this part:
>
> +               /* Set current key number only if no keys are given */
> +               if (erq->flags & IW_ENCODE_NOKEY) {
> +                       result = p80211wext_dorequest(wlandev,
> DIDmib_dot11smt_dot11PrivacyTable_dot11WEPDefaultKeyID, i);

Hi Solomon,
1) What's your opinion on the above, should it rather be like this?
        if (erq->flags & IW_ENCODE_NOKEY || erq->length == 0) {

2) FWIW, this part could be tied together now:
        /* Check if there is no key information in the iwconfig request */
        if((erq->flags & IW_ENCODE_NOKEY) == 0 ) {

                /*------------------------------------------------------------
                 * If there is WEP Key for setting, check the Key Information
                 * and then set it to the firmware.
                 -------------------------------------------------------------*/

                if (erq->length > 0) {

into
       if((erq->flags & IW_ENCODE_NOKEY) == 0 && erq->length > 0) {
just for clarity and to avoid some nesting and indenting.

3) I saw you committed all the new great stuff (svn 1850), but the
extra "disable" before "fwload" in shared.prism2 is still missing.

4) Will there be a 0.2.9 release soon? Just so distributions can know
if they should package a snapshot in the meantime.

Thanks and best regards,
Tormod


More information about the Linux-wlan-devel mailing list