You are not logged in.

#1 2010-06-11 15:40:01

Kalidor
Member
Registered: 2004-06-18
Posts: 80

Wireless WPA2 - what to do if everything fails?

Hi guys,

it is one of those moments when I wished I was using a "normal" operating system. Already wasted way too much time on getting something to run which just works on anybody else's computer...

Anyway, here's the problem: I want to connect to a wireless network protected with a WPA2 password. I've tried Wicd, netcfg and manually with wpa_supplicant. In neither case is authentication successful. I have had no trouble yet connecting to WEP protected networks. And yes, I've checked a thousand times that the password is correct.

Some googling on the subject suggested to me that non-alphanumeric passwords _might_ be problematic. Well, the password contains a "$" and a "!", so it's not alphanumeric, but I cannot change that. Could it be the cause? Putting the password inside ' ...  ' and also backslashes do not help.

I've really tried everything I could think of, to no avail. (Why can't it just work???)

Cheers
K.

Offline

#2 2010-06-11 16:25:49

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: Wireless WPA2 - what to do if everything fails?

Show us how you connect to the network - especially with wpa_supplicant. The steps you take, commands you type, etc.

The WLAN doesn't have a hidden SSID by any chance? That frequently causes trouble with Linux, and despite what some people think it's useless as a 'security measure'.


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#3 2010-06-14 08:10:04

Kalidor
Member
Registered: 2004-06-18
Posts: 80

Re: Wireless WPA2 - what to do if everything fails?

OK, here is what I have:

# ifconfig eth1 up


# ifconfig
eth0      Link encap:Ethernet  HWaddr 07:00:52:3B:A0:7D
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:41579 errors:0 dropped:0 overruns:0 frame:0
          TX packets:191 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3272687 (3.1 Mb)  TX bytes:18135 (17.7 Kb)
          Interrupt:10 Base address:0x6800

eth1      Link encap:Ethernet  HWaddr 00:05:3A:12:EC:21
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Interrupt:3 Base address:0x100

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)



# iwconfig
lo        no wireless extensions.

eth0      no wireless extensions.

eth1      IEEE 802.11b  ESSID:"MPS_134"
          Mode:Managed  Frequency:2.462 GHz  Access Point: 00:12:A9:D1:22:08
          Bit Rate:2 Mb/s   Sensitivity:1/0
          Retry short limit:8   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=90/70  Signal level=5 dBm  Noise level=-142 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0


# iwlist scan
lo        Interface doesn't support scanning.

eth0      Interface doesn't support scanning.

eth1      Scan completed :
          Cell 01 - Address: 00:24:01:2A:41:88
                    Channel:1
                    Frequency:2.412 GHz (Channel 1)
                    Quality=70/70  Signal level=-11 dBm
                    Encryption key:on
                    ESSID:"MPS_133"
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s
                    Mode:Master
                    Extra:tsf=0000000000000000
                    Extra: Last beacon: 70ms ago
                    IE: Unknown: 00074D50535F313333
                    IE: Unknown: 010482848B96
          Cell 02 - Address: 00:12:A9:C6:91:33
                    Channel:5
                    Frequency:2.432 GHz (Channel 5)
                    Quality=70/70  Signal level=-11 dBm
                    Encryption key:on
                    ESSID:"MPS_128_74"
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s
                    Mode:Master
                    Extra:tsf=0000000000000000
                    Extra: Last beacon: 70ms ago
                    IE: Unknown: 000A4D50535F3132385F3734
                    IE: Unknown: 010482848B96
          Cell 03 - Address: 00:12:A9:D1:22:08
                    Channel:11
                    Frequency:2.462 GHz (Channel 11)
                    Quality=70/70  Signal level=-11 dBm
                    Encryption key:on
                    ESSID:"MPS_134"
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s
                    Mode:Master
                    Extra:tsf=0000000000000000
                    Extra: Last beacon: 70ms ago
                    IE: Unknown: 00074D50535F313334
                    IE: Unknown: 010482848B96

Now, with

# wpa_passphrase MPS_134 '.....' > /etc/wpa_supplicant.conf

I get a /etc/wpa_supplicant.conf that sets only "ssid" and "psk". I have tried with that one and with an augmented one, using the additional options given in the ArchWiki (and no, I do not really know what I'm doing):

network={
        ssid="MPS_134"
        proto=RSN
        key_mgmt=WPA-PSK
        pairwise=CCMP TKIP
        group=CCMP TKIP
        #psk="........."
        psk=........
}

Then:

# wpa_supplicant -B -Dwext -i eth1 -d -c /etc/wpa_supplicant.conf
Initializing interface 'eth1' conf '/etc/wpa_supplicant.conf' driver 'wext' ctrl_interface 'N/A' bridge 'N/A'
Configuration file '/etc/wpa_supplicant.conf' -> '/etc/wpa_supplicant.conf'
Reading configuration file '/etc/wpa_supplicant.conf'
Priority group 0
   id=0 ssid='MPS_134'
Initializing interface (2) 'eth1'
SIOCGIWRANGE: WE(compiled)=22 WE(source)=21 enc_capa=0x0
  capabilities: key_mgmt 0x0 enc 0x3 flags 0x0
WEXT: Operstate: linkmode=1, operstate=5
Own MAC address: 00:05:3A:12:EC:21
wpa_driver_wext_set_wpa
Driver does not support 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
RSN: flushing PMKID list in the driver
Setting scan request: 0 sec 100000 usec
WPS: UUID based on MAC address - hexdump(len=16): 22 43 45 6b 02 b0 57 b3 7 af 70 2e 4f 57 22 cc
WPS: Build Beacon and Probe Response IEs
WPS:  * Version
WPS:  * Wi-Fi Protected Setup State (0)
WPS:  * Version
WPS:  * Wi-Fi Protected Setup State (0)
WPS:  * Response Type (2)
WPS:  * UUID-E
WPS:  * Manufacturer
WPS:  * Model Name
WPS:  * Model Number
WPS:  * Serial Number
WPS:  * Primary Device Type
WPS:  * Device Name
WPS:  * Config Methods (0)
WPS:  * RF Bands (3)
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
Added interface eth1
Daemonize..


# dhcpcd -d eth1
dhcpcd: version 5.2.2 starting
dhcpcd: eth1: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks', reason PREINIT
dhcpcd: eth1: executing `/usr/lib/dhcpcd/dhcpcd-run-hooks', reason NOCARRIER
dhcpcd: eth1: waiting for carrier
dhcpcd: timed out

No connection.


As for netcfg, what I used is:

# cat /etc/network.d/mpswlan
CONNECTION='wireless'
DESCRIPTION='mpswlan'
INTERFACE='eth1'
SECURITY='wpa'
KEY='....'
IP='dhcp'

Choosing this profile with netcfg-menu gives me a "WPA Authentication/Association Failed" in the end.

As for wicd, there's not much to tell. I select "WPA 1/2 Passphrase", enter the password and when I click "Connect" I obtain "Connection failed: Bad password".

Last edited by Kalidor (2010-06-14 08:11:08)

Offline

#4 2010-06-14 08:17:03

Kalidor
Member
Registered: 2004-06-18
Posts: 80

Re: Wireless WPA2 - what to do if everything fails?

.:B:. wrote:

The WLAN doesn't have a hidden SSID by any chance? That frequently causes trouble with Linux, and despite what some people think it's useless as a 'security measure'.

I don't know about that but it doesn't seem "hidden" in any way to me (see above).

Offline

#5 2010-06-14 09:16:47

ijanos
Member
From: Budapest, Hungary
Registered: 2008-03-30
Posts: 443

Re: Wireless WPA2 - what to do if everything fails?

What kind of wireless card are you using? Did you know that wpa2 needs hw support? I had to upgrade the firmware of my Prism II card to be able to use it on wpa2 networks.

Offline

#6 2010-06-14 10:42:14

iphitus
Forum Fellow
From: Melbourne, Australia
Registered: 2004-10-09
Posts: 4,927

Re: Wireless WPA2 - what to do if everything fails?

wpa_supplicant -B -Dwext -i eth1 -d -c /etc/wpa_supplicant.conf

Take off the -B. That backgrounds wpa_supplicant it as soon as it grabs the wireless interface and _before_ it has connected - thus hiding all the useful connection debug info. That's probably why dhcp then fails, because you're starting dhcp before wpa_supplicant has had a chance to connect.

See what debug info you get without the -B. If that config file then works, it'll work with netcfg too as a wpa-configsection/wpa-config.

James

Last edited by iphitus (2010-06-14 10:43:04)

Offline

#7 2010-06-14 10:48:16

Kalidor
Member
Registered: 2004-06-18
Posts: 80

Re: Wireless WPA2 - what to do if everything fails?

ijanos wrote:

What kind of wireless card are you using?

It's a Netgear MA401.

Did you know that wpa2 needs hw support?

No, I did not think about that.

I had to upgrade the firmware of my Prism II card to be able to use it on wpa2 networks.

Hmm...

Offline

#8 2010-06-14 11:00:59

ijanos
Member
From: Budapest, Hungary
Registered: 2008-03-30
Posts: 443

Re: Wireless WPA2 - what to do if everything fails?

Kalidor wrote:
ijanos wrote:

What kind of wireless card are you using?

It's a Netgear MA401

Yeah, prism chipset.
If you omit the -B from wap_supplicant i guess you will see it finds the network but could not associate with it. If you have a windows machine you could try it to be sure, but i say the card doesnt support wpa2.

Read this: http://linux.junsun.net/intersil-prism/
Get the hostap_diag utility and check the version of the stationary firmware of your card. If it is below 1.7.0 (or 1.8.2 I am not sure)  then is not wpa2 ready.

Last edited by ijanos (2010-06-14 11:04:43)

Offline

#9 2010-06-14 11:20:01

Kalidor
Member
Registered: 2004-06-18
Posts: 80

Re: Wireless WPA2 - what to do if everything fails?

ijanos wrote:

Read this: http://linux.junsun.net/intersil-prism/
Get the hostap_diag utility and check the version of the stationary firmware of your card. If it is below 1.7.0 (or 1.8.2 I am not sure)  then is not wpa2 ready.

Without -B I get things like

ioctl[SIOCGIWSCAN]: Resource temporarily unavailable
ioctl[SIOCSIWSCAN]: Device or resource busy
Failed to initiate AP scan.

I don't know where to get hostap_diag, but dmesg gives me:

orinoco_cs 0.0: Firmware detected as Intersil 1.3.6

Seems like you're right, firmware is too old. I hope it's easy/safe to flash the thing on Linux. Right now I don't have time for this stuff, but I'll let you know when/if I can make it work.

Thank you.

Offline

Board footer

Powered by FluxBB