This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TiWi-BLE has problem with TKIP cipher

We have a custom board (i.MX28) with a TiWi-BLE device on it, running Linux kernel 3.12.

We have a working Wifi and Bluetooth expect for one issue.

When the Wifi Access Point supports only TKIP ciphers we do not get a connection.

wpa_supplicant shows the error WPA: Failed to set PTK to the driver (alg=2 keylen=32 bssid=00:11:50:7d:05:c0)

WPA: 4-Way Handshake failed - pre-shared key may be incorrect

And the wl12xx driver shows:

wl12xx_driver wl12xx.0.auto wlan0: disabling HT/VHT due to WEP/TKIP use
wl12xx_driver wl12xx.0.auto wlan0: disabling HT as WMM/QoS is not supported by the AP
wl12xx_driver wl12xx.0.auto wlan0: disabling VHT as WMM/QoS is not supported by the AP

When switching to another cipher on the access point like AES then all works well. We made no changes to the custom board configuration.

Can anyone give me a hint on what maybe wrong?

  • Hi,

    Please share the wl12xx driver/firmware release that you are using.

    Regards,
    Gigi Joseph.

  • Hi,

    we are using the default driver wl12xx from 3.12.32 (main-line kernel).

    It loads firmware version: 6.3.10.0.133


    When I enable debug output on wpa_supplicant, I see:

    wpa_driver_nl80211_set_key: ifindex=5 (wlan0) alg=2 addr=0xdbcc8 key_idx=0 set_tx=1 seq_len=6 key_len=32
    nl80211: KEY_DATA - hexdump(len=32): [REMOVED]
    nl80211: KEY_SEQ - hexdump(len=6): 00 00 00 00 00 00
       addr=00:11:50:7d:05:c0
    nl80211: set_key failed; err=-22 Invalid argument)
    wlan0: WPA: Failed to set PTK to the driver (alg=2 keylen=32 bssid=00:11:50:7d:05:c0)

  • Hi,

    I think it is a build issue. The build script is available at: https://github.com/TI-ECS/build-utilites/blob/master/wl12xx_build.sh (Latest release tag: "ol_R5.SP7.01"). 

    The feature itself (STA Security "WPA TKIP") is marked as validated in the official releases.

    Regards,
    Gigi Joseph.

  • Hi,

    we are using the OpenEmbbeded/Bitbake build environment.So we can not use the build-script, just parts of it.

    We did use the wpa_supplicant from the build script, but no improvement.

    The kernel in the git://github.com/TI-OpenLink/wl12xx.git repo is 3.2, we are using 3.12.

    It is very difficult so switch to another kernel, since we have a lot of other peripherals up and running (LCD, capacitive touch screen, adc, ethernet, etc.)

    That's why we use the mainline kernel driver (wl12xx) from 3.12.

    Any advice on the OE/Bitbake?

  • Hi,

    This was something that was working from a very long time - and never broken.

    Anyways, can you share the exact commands that you are executing along with the wpa_supplicant.conf and the full supplicant debug logs?

    Regards,
    Gigi Joseph.

  • Hi,

    It must be something with our configuration, I can not find anyone with the same issues. Other routers (not using tkip) work like a charm.


    We have tested a bare wpa_supplicant.conf and a more configured one. See attachments in zip 8883.TI MAIL.ZIP.

    Command line wpa_supplicant:

    /usr/sbin/wpa_supplicant -B -P /var/run/wpa_supplicant.wlan0.pid -i wlan0 -c /etc/wpa_supplicant.conf -D nl80211

    for Debug:

    /usr/sbin/wpa_supplicant -dd -P /var/run/wpa_supplicant.wlan0.pid -i wlan0 -c /etc/wpa_supplicant.conf -D nl80211 -f log.txt

  • Found it, as always something simple when you know it.

    The crypto module arc4 was not loaded on my system. When this this not loaded we get an illegal argument (strange but true).

    Our build system does not automatically add all kernel modules to the filesystem. So I am investigating which other crypt modules I am missing.

    Any hints anyone on the crypto modules needed?