WEP wireless doesn't work

Hello,

I'm new on FreeBSD and I have some problems with my WEP network. I read the FreeBSD documentation and I searched on the internet but I didn't find a solution yet.

I added wlan0 and ifconfig_wlan0 to rc.conf:
# cat /etc/rc.conf
Code:
hostname="Manaudbureau"
keymap="fr-dvorak-bepo"
ifconfig_sge0="DHCP"
sshd_enable="YES"
moused_enable="YES"
ntpd_enable="YES"
powerd_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="NO"
hald_enable="YES"
dbus_enable="YES"
wlans_wi0="wlan0"
ifconfig_wlan0="country FR WPA DHCP"

linux_enable="YES"

I configured wpa_supplicant for my WEP network GAS:
# cat /etc/wpa_supplicant.conf
Code:
ctrl_interface=/var/run/wpa_supplicant
eapol_version=2
ap_scan=1
fast_reauth=1

network={
	ssid="GAS"
	priority=1
	key_mgmt=NONE
	wep_tx_keyidx=0
	wep_key0=[I]mykey[/I]
}

And I added the wi driver to loader.conf:
# cat /boot/loader.conf
Code:
if_wi_load="YES"
if_rum_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"

But it doesn't work :(. After a ifconfig wlan0 up I have:
ifconfig wi0
Code:
wi0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 2290
	ether 00:09:5b:74:63:5f
	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
	media: IEEE 802.11 Wireless Ethernet autoselect mode 11b
	status: associated
ifconfig wlan0
Code:
wlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	ether 00:09:5b:74:63:5f
	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
	media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
	status: no carrier
	ssid "" channel 1 (2412 MHz 11b)
	regdomain ETSI country FR authmode OPEN privacy OFF txpower 30
	bmiss 7 scanvalid 60 roaming MANUAL

When I try to start wpa_supplicant I have this:
wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf
Code:
ioctl[SIOCS80211, op 26, arg 0x3]: Operation not supported
Failed to initialize driver interface
ELOOP: remaining socket: sock=4 eloop_data=0x284081c0 user_data=0x28412080 handler=0x8070bd0

So I think there is a problem with that. What am I doing wrong?
 
My wireless card is a ISL3874 Prism 2.5 and my driver is wi and boots at start (so I added
Code:
if_wi_load="YES"
in loader.conf like it is said in wi(4)).

Code:
wi0@pci0:0:9:0:	class=0x028000 card=0x41051385 chip=0x38731260 rev=0x01 hdr=0x00
    vendor     = 'Intersil Corporation'
    device     = 'ISL3874 [Prism 2.5]/ISL3872 [Prism 3]'
    class      = network
 
It seems that doesn't change anything (except for the country of course).
# ifconfig wlan0
Code:
wlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	ether 00:09:5b:74:63:5f
	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
	media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
	status: no carrier
	ssid "" channel 1 (2412 MHz 11b)
	country US authmode OPEN privacy OFF txpower 0 bmiss 7 scanvalid 60
	roaming MANUAL bintval 0

I don't understand why wpa_supplicant doesn't work.
Also, when I try to connect manually to my network with # ifconfig wlan0 ssid GAS wepmode on weptxkey 1 wepkey 1:[i]mykey[/i], it doesn't work either.
# ifconfig wlan0
Code:
wlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	ether 00:09:5b:74:63:5f
	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
	media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
	status: no carrier
	ssid GAS channel 1 (2412 MHz 11b)
	country US authmode OPEN privacy ON deftxkey 1 wepkey 1:104-bit
	txpower 0 bmiss 7 scanvalid 60 roaming MANUAL bintval 0

But the network is detected with # ifconfig wlan0 scan and I'm sure of the key.
 
The same here: FreeBSD 9.1 AMD64, iwn WiFi module and some old Linksys router. WEP connection is associated but no response from DHCP and no network traffic on manual IP assignment. Tried wpa_supplicant, tried manual ifconfig permutations. Connection to this WEP network works on Android, Linux and Windows, it does not work on FreeBSD. Network on FreeBSD works fine using wpa_supplicant to WPA networks.

It seems FreeBSD has broken WEP support :(
 
The nice thing about WEP is that you can ask the numerous neighbors sharing your connection without permission how they got it to work.

wpa_supplicant.conf(5) says the WEP key must be enclosed in quotes. Is yours? There is an example at the end of that man page.

That said... stop using WEP. Don't use WEP at all, ever, anywhere. WEP is trivially broken, by anyone, with easily available tools, in minutes. If you have equipment that only supports WEP, replace it. If you must use WEP, run IPsec over it so at least they won't be able to use your system after they have easily cracked the WEP keys. But don't do that, replace WEP with WPA2.
 
I know I can crack WEP too and I know it's insecure but sometimes I need to use it and I don't want to stop my work switch to another OS just because my FreeBSD does not support it :)
 
I replaced WEP with WPA. I changed my wpa_supplicant.conf(5) to :
Code:
ctrl_interface=/var/run/wpa_supplicant
eapol_version=2
ap_scan=1
fast_reauth=1

network={
	ssid="GAS"
	psk="[I]mynewkey[/I]"
}

But when I try to launch wpa_supplicant with # wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf I always get:
Code:
ioctl[SIOCS80211, op 26, arg 0x3]: Operation not supported
Failed to initialize driver interface
ELOOP: remaining socket: sock=4 eloop_data=0x284081c0 user_data=0x28412080 handler=0x8070bd0

So the problem is the same as before and I don't understand what it is because the driver should run with
Code:
if_wi_load="YES"
that I put in /boot/loader.conf, isn't it?
 
Don't change defaults. Remove all the unnecessary settings in wpa_supplicant.conf (that would be everything except ssid and psk) and only add them if they are required.

Also, read wi(4). It is a very old card, and may not support WPA.
 
This is not a reply that will help the original poster. It is just a follow on from what others have already said about WEP that might help others. The 'WEP' protocol should not be used at all. It was replaced by WPA2 for a very good reason.

In my view, modern access points should not even have it as an option as it can easily confuse a user into selecting it rather than WPA2 or other secure variant.

So if anyone reading this has a new wireless router you should set it up with WPA2 and use a 63 character passphrase. It only has to be entered once for each of your wireless devices.

Kind Regards
 
16 characters (128bit) WPA2 password is good enough assuming it has enough randomness. 128 bit key can not be brute forced and the key itself is not directly used in WPA2 but used as the seed for generating the actual encryption keys.
 
Back
Top