# WPA supplicant problems ipw3945 [Solved]

## djhomeless

I have been trying to get my laptop working with wpa_supplicant for a very long time, have ripped most of the

hair from my head, mostly because it is the last hurdle to get all of my laptop hardware working with gentoo!...

I have gone through the how-to probably about 5 times now just in case I missed anything,

tried solutions I saw in the forums and still nothing.  I have gotten the wireless to work with WEP using iwconfig

Although everytime I wanted to connect I had to set things manually and even then some times it just didnt work.

Basically I want 2 things:

1) connect to home network (WPA)

2) connect to unsecured/open networks(school, coffee shops, etc....)

Here is the relevant info.....

Toshiba Satellite A105-S4074

Intel PRO Wireless 3945ABG

kernel 2.6.19.2

```

$lsmod

Module                  Size  Used by

ieee80211_crypt_tkip    14464  0 

ipw3945               108576  1 

ieee80211              30792  1 ipw3945

ieee80211_crypt         9216  2 ieee80211_crypt_tkip,ieee80211

```

/etc/conf.d/net

```

#config_eth0=( "dhcp" )

modules=( "wpa_supplicant" )

dhcp_eth0="-t 10"

wpa_supplicant_eth1="-Dwext"

wpa_timeout_eth1=10

dhcp_eth1="-t 10"

```

/etc/wpa_supplicant/wpa_supplicant.conf

```

ctrl_interface=/var/run/wpa_supplicant

ctrl_interface_group=0

eapol_version=1

ap_scan=2

network={

  ssid="DBM 802.11n"

  scan_ssid=1

  proto=WPA

  key_mgmt=WPA-PSK

  psk="XXXXX"             #not really x's

  priority=5

}

```

Any ideas?Last edited by djhomeless on Sun Feb 18, 2007 10:28 pm; edited 1 time in total

----------

## cakoolen

About the same trouble here.

When trying to connect to an unprotected wireless connection there are no problems. Trying to enable WPA, and the trouble starts. What configuration I try does not matter it says that it is scanning and thats it. This evening I will try to use the fix in bug report https://bugs.gentoo.org/show_bug.cgi?id=155330

----------

## tarpman

try modprobing ieee80211_crypt_wep and ieee80211_crypt_ccmp as well - I've had problems before when those were missing, even if they shouldn't have been needed for that particular access point.

----------

## djhomeless

 *tarpman wrote:*   

> try modprobing ieee80211_crypt_wep and ieee80211_crypt_ccmp as well - I've had problems before when those were missing, even if they shouldn't have been needed for that particular access point.

 

Gave it a try...still no activity....

----------

## cakoolen

all ieee80211 stuff is compiled in the kernel. So I've got no modules to modprobe.

```
CONFIG_IEEE80211=y

# CONFIG_IEEE80211_DEBUG is not set

CONFIG_IEEE80211_CRYPT_WEP=y

CONFIG_IEEE80211_CRYPT_CCMP=y

CONFIG_IEEE80211_CRYPT_TKIP=y

CONFIG_IEEE80211_SOFTMAC=y

# CONFIG_IEEE80211_SOFTMAC_DEBUG is not set

CONFIG_WIRELESS_EXT=y

```

I don't think the problem is over there

----------

## schiotz

Are you sure you have not hidden the SSID?  Many do that in the belief that it increases security, but it prevents wpa_supplicant from working.  Note that even if you hide your SSID, it is still broadcast in clear text in every package, just with a bit added meaning "this SSID is a secret, don't tell it to the user".  Needless to say, the hacker's tools don't respect that bit  :Smile: 

----------

## cakoolen

I'm sure the SSID is 'visible'.

I've tried to boot windows on the same machine, and it worked flawlessly.

----------

## djhomeless

 *schiotz wrote:*   

> Are you sure you have not hidden the SSID?  Many do that in the belief that it increases security, but it prevents wpa_supplicant from working.  Note that even if you hide your SSID, it is still broadcast in clear text in every package, just with a bit added meaning "this SSID is a secret, don't tell it to the user".  Needless to say, the hacker's tools don't respect that bit 

 

My SSID is not hidden....

I still have no idea why this isnt working correctly....

----------

## djhomeless

Here is the output from firing up wpa_supplicant manually...

```

Initializing interface 'eth1' conf '/etc/wpa_supplicant/wpa_supplicant.conf' driver 'wext' ctrl_interface 'N/A' bridge 'N/A'

Configuration file '/etc/wpa_supplicant/wpa_supplicant.conf' -> '/etc/wpa_supplicant/wpa_supplicant.conf'

Reading configuration file '/etc/wpa_supplicant/wpa_supplicant.conf'

ctrl_interface='/var/run/wpa_supplicant'

ctrl_interface_group=0

eapol_version=1

ap_scan=2

Line: 15 - start of a new network block

ssid - hexdump_ascii(len=11):

     44 42 4d 20 38 30 32 2e 31 31 6e                  DBM 802.11n     

proto: 0x1

key_mgmt: 0x2

PSK (ASCII passphrase) - hexdump_ascii(len=10): [REMOVED]

PSK (from passphrase) - hexdump(len=32): [REMOVED]

Priority group 0

   id=0 ssid='DBM 802.11n'

Initializing interface (2) 'eth1'

EAPOL: SUPP_PAE entering state DISCONNECTED

EAPOL: KEY_RX entering state NO_KEY_RECEIVE

EAPOL: SUPP_BE entering state INITIALIZE

EAP: EAP entering state DISABLED

EAPOL: External notification - portEnabled=0

EAPOL: External notification - portValid=0

SIOCGIWRANGE: WE(compiled)=21 WE(source)=16 enc_capa=0xf

  capabilities: key_mgmt 0xf enc 0xf

WEXT: Operstate: linkmode=1, operstate=5

Own MAC address: 00:13:02:c7:93:f7

wpa_driver_wext_set_wpa

wpa_driver_wext_set_key: alg=0 key_idx=0 set_tx=0 seq_len=0 key_len=0

wpa_driver_wext_set_key: alg=0 key_idx=1 set_tx=0 seq_len=0 key_len=0

wpa_driver_wext_set_key: alg=0 key_idx=2 set_tx=0 seq_len=0 key_len=0

wpa_driver_wext_set_key: alg=0 key_idx=3 set_tx=0 seq_len=0 key_len=0

wpa_driver_wext_set_countermeasures

wpa_driver_wext_set_drop_unencrypted

Setting scan request: 0 sec 100000 usec

Added interface eth1

Wireless event: cmd=0x8b06 len=8

RTM_NEWLINK, IFLA_IFNAME: Interface 'eth1' added

RTM_NEWLINK, IFLA_IFNAME: Interface 'eth1' added

State: DISCONNECTED -> SCANNING

Trying to associate with SSID 'DBM 802.11n'

Cancelling scan request

WPA: clearing own WPA/RSN IE

Automatic auth_alg selection: 0x1

WPA: No WPA/RSN IE available from association info

WPA: Set cipher suites based on configuration

WPA: Selected cipher suites: group 30 pairwise 24 key_mgmt 2

WPA: clearing AP WPA IE

WPA: clearing AP RSN IE

WPA: using GTK CCMP

WPA: using PTK CCMP

WPA: using KEY_MGMT WPA-PSK

WPA: Set own WPA IE default - hexdump(len=24): dd 16 00 50 f2 01 01 00 00 50 f2 04 01 00 00 50 f2 04 01 00 00 50 f2 02

No keys have been configured - skip key clearing

wpa_driver_wext_set_drop_unencrypted

State: SCANNING -> ASSOCIATING

WEXT: Operstate: linkmode=-1, operstate=5

wpa_driver_wext_associate

Setting authentication timeout: 60 sec 0 usec

EAPOL: External notification - EAP success=0

EAPOL: External notification - EAP fail=0

EAPOL: External notification - portControl=Auto

Wireless event: cmd=0x8b06 len=8

Wireless event: cmd=0x8b1a len=19

CTRL-EVENT-TERMINATING - signal 2 received

Removing interface eth1

State: ASSOCIATING -> DISCONNECTED

WEXT: Operstate: linkmode=-1, operstate=5

No keys have been configured - skip key clearing

EAPOL: External notification - portEnabled=0

EAPOL: External notification - portValid=0

wpa_driver_wext_set_wpa

wpa_driver_wext_set_drop_unencrypted

wpa_driver_wext_set_countermeasures

No keys have been configured - skip key clearing

WEXT: Operstate: linkmode=0, operstate=6

```

----------

## Evincar

I have a very similar problem, except that I am using static IP...shall I explain it here on in another thread?

I can make the wireless work perfectly with wireless-tools, but then of course I am stuck with WEP encryption.   :Crying or Very sad: 

----------

## djhomeless

 *Evincar wrote:*   

> I have a very similar problem, except that I am using static IP...shall I explain it here on in another thread?
> 
> I can make the wireless work perfectly with wireless-tools, but then of course I am stuck with WEP encryption.  

 

You can try here...

I haven't gotten too many responses though.

I tried using the latest ipw3945d and wpa_supplicant and still nothing...

----------

## sdfg

I've got this too, on a Toshiba Satellite P100-430.

Same as you, I've followed the how-to for ipw3945 so many times it's not true, and followed the wpa_supplicant one as well (which to be honest is pretty useless). 

I've unmerged and remerged all the various packages. I've updated the kernel to 2.6.19-r5, using the built in 802.11 stack. I've tried the stand-alone stack under 2.6.19-r4. I've tried sacrificing a goat to the Elder Gods and Cthuhlu himself (no, not really). Still nothing. And it's driving me utterly round the bend.

I almost had it at my friends house, kwifimanager was reporting that I was connecting to the SSID, but then it would fall over when trying to get an IP. I don't think it's even doing that anymore.

I really need this to work so I can use my laptop at uni. 

That's three people now, does that count as a plea for someone to have a look for us?  :Very Happy: 

----------

## Evincar

Well, if your uni has open or WEP wireless, iwconfig can do the trick, it's simply that I would like to have some "real" security in my network...

----------

## quat

i used to have problems if had compiled in ieee modules.

you can try to emerge ieee80211 and ipw3945 (outside your kernel tree). you _need_ to have disabled ieee80211 modules in your kernel. they are not compatible with new ipw3945 driver. anyway during emerge if ieee80211, you will be asked if the stuff (ieee80211 headers) from your kernel should be deleted.

hth

----------

## sdfg

 *Evincar wrote:*   

> Well, if your uni has open or WEP wireless, iwconfig can do the trick, it's simply that I would like to have some "real" security in my network...

 

Yeah, the uni have just switched over to WPA, which I'm glad about. Just trying to get this sodding thing working!

 *quat wrote:*   

> i used to have problems if had compiled in ieee modules. 
> 
> you can try to emerge ieee80211 and ipw3945 (outside your kernel tree). you _need_ to have disabled ieee80211 modules in your kernel. they are not compatible with new ipw3945 driver. anyway during emerge if ieee80211, you will be asked if the stuff (ieee80211 headers) from your kernel should be deleted. 
> 
> hth

 

I tried that as well. I read somewhere that someone had compiled the ipw3945 driver into the kernel, but that can't be right, can it? It's proprietry isn't it?

----------

## quat

the driver itself it is not proprietry, but the daemon and the firmware is  :Smile: 

for me sometimes it works after unloading _all_ modules connected with ipw3945 and loading them again.

especially for WPA.

maybe it it'll work or you.

what versions of driver, ieee80211 and wpa_supplicant do you have installed?

----------

## djhomeless

 *quat wrote:*   

> the driver itself it is not proprietry, but the daemon and the firmware is 
> 
> for me sometimes it works after unloading _all_ modules connected with ipw3945 and loading them again.
> 
> especially for WPA.
> ...

 

Right now:

ipw3945-1.2.0

ieee80211: Whatever is included in kernel 2.6.19.2 compile

the new ipw3945 made me do it for some reason...

* Genereic 802.11 Networking

  * IEEE 802.11 WEP

  * IEEE 802.11i CCMP

  * IEEE 802.11i TKIP

wpa_supplicant 0.5.7

I would love to get rid of everything and just start over with the how-to except that the 

i3945 how-to is either dated or just wrong....

----------

## djhomeless

 *Kasyx wrote:*   

> I've got this too, on a Toshiba Satellite P100-430.
> 
> Same as you, I've followed the how-to for ipw3945 so many times it's not true, and followed the wpa_supplicant one as well (which to be honest is pretty useless). 
> 
> I've unmerged and remerged all the various packages. I've updated the kernel to 2.6.19-r5, using the built in 802.11 stack. I've tried the stand-alone stack under 2.6.19-r4. I've tried sacrificing a goat to the Elder Gods and Cthuhlu himself (no, not really). Still nothing. And it's driving me utterly round the bend.
> ...

 

I had similar experiences with Kwifimanager, it would start connecting... then die trying to get an IP

Also tried gnome network applet (network manager?) and no help with that either...

----------

## madisonicus

I think you need a pairwise and a proto entry in your wpa_suplicant.conf.  Which you set is going to depend on the way the AP has things set.  As much as I hate to admit it, the wpa_gui is able to find out this information quickly and so I use it to set up new networks.  I'd suggest using the scan feature and double-clicking on the network to let the gui set things up for you.

Beyond that I'm fairly ignorant about the internals of how wpa_supplicant works; it still seems like a lot of black magic to me.  You might try the mailing list if all else fails.

HTH, 

m

----------

## TenPin

I just got ipw3945 to work beautifully. To do this I did the following:

```

emerge --sync

emerge -C coldplug

emerge -C ipw3945 ipw3945d ipw3945-ucode ieee80211

[installed kernel 2.6.20 manually with built in ieee80211 stack then rebooted]

emerge wpa_supplicant

emerge ipw3945 ipw3945d ipw3945-ucode

emerge module-init-tools (this needed updgrading for udev to work properly for me)

rc-update del ipw3945d

modprobe ipw3945

```

First I tested connecting to an unencrypted access point using only iwconfig and dhcpcd. Then I tested connecting to a WPA access point using:

```

#/etc/wpa_supplicant/wpa_supplicant.conf

ctrl_interface=/var/run/wpa_supplicant

ctrl_interface_group=wheel

eapol_version=1

ap_scan=1

fast_reauth=1

network={

        ssid="Boiler"

        psk="password"

        priority=10

        scan_ssid=1

}

```

```

wpa_supplicant -Dwext -ieth1 -c/etc/wpa_supplicant/wpa_supplicant.conf

```

If you can get the above command to work then the only thing left to do is making your network boot scripts work the way you want.

----------

## sdfg

 *TenPin wrote:*   

> I just got ipw3945 to work beautifully. To do this I did the following:
> 
> ```
> 
> emerge --sync
> ...

 

Confirmed! This works wonderfully. At least, it gets me onto the network. I'm having trouble now getting any traffic through. I can ping the router and other devices on the network, but can't get out. The gateway has been set for the interface. I know it's going kinda off topic now, but any ideas what could cause that?

Oooh, solved it. When I took out the cable before, I just unplugged it, and I couldn't get out to the internet. I'm thinking it could be because of the network init script being a bit odd, because when I stop eth0 (wired), eth1 takes over fine and I can get out. I'm not going to test any further than that incase wireless breaks, it's taken me a month to get it working  :Very Happy: 

----------

## Evincar

Well, I got it working yesterday, after emerging the latest ipw3945 and UDEV. I don't know what happenned maybe I simply had incompatible stuff, or the new drivers solve the problem. No idea, I also noticed that my firewire is also detected now (not that it matters, I have never used it yet...)

Well, well, this keeps getting better and better  :Very Happy: .

----------

## djhomeless

 *TenPin wrote:*   

> I just got ipw3945 to work beautifully. To do this I did the following:
> 
> ```
> 
> emerge --sync
> ...

 

I will have to try this out when I get back home,

Thanks in advance!

----------

## djhomeless

TenPin!!!! thank you so much it works wonderfully now, after like a month of F*cking with everything it finally works!

Now my laptop is complete! thank you so much for the help!!!!

----------

## aysther

OMG. I can't believe it. Wow... You solved my problem as well. I am now up and running! Thank you so much!!!

----------

## jeanfrancis

Working here too  :Smile: 

----------

## janwolff

Worked for me too; the reemerge of module-init-tools was essential in my case.

Another point to notice is the importance of the rc_coldplug settings.

This setting has been broken by the update of udev.

```

# /etc/conf.d/rc

RC_COLDPLUG="no"

RC_PLUG_SERVICES=""

```

This setting fixed it.

```

# /etc/conf.d/rc

RC_COLDPLUG="yes"

RC_PLUG_SERVICES="ipw3945d !*"

```

This made udev start ipw3945d on boot.

----------

## WildChild

See this thread:

https://forums.gentoo.org/viewtopic-t-542290.html

It may be your problem!

----------

