You are not logged in.

#1 2009-08-24 15:46:02

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

[solved] Can't connect WPA w/ netcfg -- wpa_cli fails

I'm trying to connect to a PEAP/MSCHAPV2 secured network with netcfg.  I had some trouble with creating a working wpa_supplicant config file, but finally got it working -- manually.  The following works like a charm:

# ifconfig wlan0 up; iwconfig wlan0 essid MyNetwork; wpa_supplicant -B -iwlan0 -c/etc/wpa_supplicant.conf; dhcpcd wlan0

But netcfg fails:

# netcfg profile
:: profile up                                                                                                [BUSY] 
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
... 11 more lines like the above ...
 - Authentication/association failed
                                                                                                             [FAIL]

I can verify that wpa_supplicant has been successfully started and daemonized.  My wpa_supplicant.conf is pretty bare (comments removed):

network={
    ssid="MyNetwork"
    key_mgmt=WPA-EAP
    eap=PEAP
    identity="MyID"
    password="MyPassword"
    phase2="auth=MSCHAPV2"
}

And my network profile:

CONNECTION="wireless"
DESCRIPTION="a description"
INTERFACE=wlan0
HOSTNAME=myhostname
IP=dhcp
ESSID=MyNetwork
SECURITY=wpa-config
SCAN="YES"
WPA_CONF=/etc/wpa_supplicant.conf

I've googled and searched the forums, but can't figure out what netcfg is doing wrong.  Any ideas/links/divine revelations are appreciated.

Trent

(edit: premature post)

Last edited by Trent (2009-08-26 12:20:28)

Offline

#2 2009-08-26 04:03:48

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: [solved] Can't connect WPA w/ netcfg -- wpa_cli fails

I can reproduce this by starting wpa_supplicant and then trying to connect to it with wpa_cli.  wpa_supplicant itself works fine (as I mentioned above) but wpa_cli can't seem to connect to it.  Possibly a bug in wpa_cli?

Since wpa_supplicant works by itself, and netcfg works on all my other networks, I did the hackish thing and commented out the wpa_check code in /usr/lib/network/connections/wireless under wpa-config.  It's not the best solution, but I have automatic wireless now. smile

If anybody can shed light on this (bug? issue? misconfiguration?) I'd still be interested to hear about it.

Offline

#3 2009-08-26 08:18:47

csstaub
Member
From: Switzerland
Registered: 2009-02-09
Posts: 37

Re: [solved] Can't connect WPA w/ netcfg -- wpa_cli fails

Do you have the ctrl_interface variable set in wpa_supplicant.conf?

Offline

#4 2009-08-26 12:20:05

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: [solved] Can't connect WPA w/ netcfg -- wpa_cli fails

Nope.  Wow, it seems so obvious when you call attention to it.  Oh well, I guess that's what forums are for.

Offline

Board footer

Powered by FluxBB