Re: Wireless adapter associated, rx ok, tx ko

From: Sam Leffler <sam_at_errno.com>
Date: Wed, 27 Feb 2008 16:58:09 -0800
Jeremie Le Hen wrote:
> On Tue, Feb 26, 2008 at 11:56:52PM +0100, Jeremie Le Hen wrote:
>   
>> Hi list,
>>
>> I'm running -CURRENT from 2007/02/22.
>>
>> I'm currently on holidays.  There is a wireless network protected with
>> WEP.  I can successfully associate to the AP, but dhclient(8) won't
>> succeed in getting an IP address.  I also tried to configure an IP
>> address manually and ping another computer on the network without
>> success.  Nonetheless, I can see the traffic from other computers with
>> tcpdump(8).
>>
>> This behaviour occurs with if_ral and if_wi.
>> I tried with a Linux live CD (from which I'm writing this e-mail), and
>> it works.
>>     
>
> More information coming.  You will find my dmesg attached (not verbose).
> Note there are a couple of LOR, especially one related to ral0.
>
> Here are the modules I loaded (either from loader(8) or manually):
> % Id Refs Address    Size     Name
> %  1   78 0xc0400000 4eddd8   kernel (/boot/kernel/kernel)
> %  2    1 0xc08f5000 6d434    acpi.ko (/boot/kernel/acpi.ko)
> %  3    1 0xc0963000 6780     cardbus.ko (/boot/kernel/cardbus.ko)
> %  4    3 0xc096a000 2b40     exca.ko (/boot/kernel/exca.ko)
> %  5    1 0xc096d000 dd6c     cbb.ko (/boot/kernel/cbb.ko)
> %  6    8 0xc097b000 2e7d8    wlan.ko (/boot/kernel/wlan.ko)
> %  7    1 0xc09aa000 5838     wlan_scan_sta.ko (/boot/kernel/wlan_scan_sta.ko)
> %  8    1 0xc09b0000 495c     wlan_tkip.ko (/boot/kernel/wlan_tkip.ko)
> %  9    1 0xc09b5000 3204     wlan_wep.ko (/boot/kernel/wlan_wep.ko)
> % 10    1 0xc3d46000 24000    linux.ko (/boot/kernel/linux.ko)
> % 11    1 0xc3f83000 8000     umass.ko (/boot/kernel/umass.ko)
> % 12    1 0xc3f8b000 22000    usb.ko (/boot/kernel/usb.ko)
> % 13    1 0xc4046000 19000    if_ral.ko (/boot/kernel/if_ral.ko)
> % 14    1 0xc4076000 f000     if_iwi.ko (/boot/kernel/if_iwi.ko)
> % 15    1 0xc4085000 30000    iwi_bss.ko (/boot/kernel/iwi_bss.ko)
> % 16    1 0xc40b5000 1d000    if_wi.ko (/boot/kernel/if_wi.ko)
> % 17    1 0xc40d2000 d000     pccard.ko (/boot/kernel/pccard.ko)
>
> I attached a "screenshot" when dhclient(8) is run for wi0, with
> net.wlan.0.debug=0xffffffff.
>
> Likewise, there is the debug output for ral0.  Although the outcome is
> the same -- no packet seems to be sent -- debug messages are very
> different.
>
>   
> jarjarbinks:~:140# ifconfig wi0
> wi0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
>         ether 00:02:2d:4b:b9:20
>         media: IEEE 802.11 Wireless Ethernet autoselect (DS/2Mbps)
>         status: associated
>         ssid XXXXXXXXXX channel 10 (2457 Mhz 11b) bssid XX:XX:XX:XX:XX:XX
>         stationname "FreeBSD WaveLAN/IEEE node"
>         authmode OPEN privacy MIXED deftxkey UNDEF wepkey 1:104-bit bmiss 7
>         scanvalid 60 bintval 0
> jarjarbinks:~:141# sysctl net.wlan.0.debug=0xffffffff
> net.wlan.0.debug: 0 -> 2147483647
> jarjarbinks:~:142#
> jarjarbinks:~:142#
> jarjarbinks:~:142# dhclient wi0
> wi0: ieee80211_newstate: RUN -> INIT
> wi0: ieee80211_ref_node (ieee80211_send_mgmt:1574) 0xc4b28000<XX:XX:XX:XX:XX:XX> refcnt 3
> wi0: [XX:XX:XX:XX:XX:XX] send station disassociate (reason 8)
> [XX:XX:XX:XX:XX:XX] send disassoc on channel 10
> wi0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
> wi0: ieee80211_node_table_reset station table
> wi0: ieee80211_free_allnodes_locked: free all nodes in station table
> wi0: node_reclaim: remove 0xc4b28000<XX:XX:XX:XX:XX:XX> from station table, refc
> nt 1
> wi0: ieee80211_setup_node 0xc4bb9000<00:02:2d:4b:b9:20> in station table
> wi0: _ieee80211_free_node 0xc4b28000<XX:XX:XX:XX:XX:XX> in <gone> table
> wi0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
> DHCPDISCOVER on wi0 to 255.255.255.255 port 67 interval 5
> wi0: ieee80211_newstate: INIT -> RUN
> wi0: ieee80211_newstate: invalid transition
> wi0: [ff:ff:ff:ff:ff:ff] no default transmit key (ieee80211_encap) deftxkey 65535
> DHCPDISCOVER on wi0 to 255.255.255.255 port 67 interval 11
> wi0: [ff:ff:ff:ff:ff:ff] no default transmit key (ieee80211_encap) deftxkey 65535
> DHCPDISCOVER on wi0 to 255.255.255.255 port 67 interval 12
> wi0: [ff:ff:ff:ff:ff:ff] no default transmit key (ieee80211_encap) deftxkey 65535
>
>
> (Note that setting deftxkey for wi0, does not change anything.)
I don't believe you that setting the key doesn't change anything.  Your 
outbound traffic is being dropped because there is no tx keyid specified.

I note the ral log likewise says you have no deftxkey setup.

wlanstats will show you how many frames are being dropped because the 
system doesn't know what key to use to encrypt traffic.

    Sam
Received on Wed Feb 27 2008 - 23:58:13 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:28 UTC