64 character WPA2 hex key in Ubuntu

If you’re security conscious like me and have secured your wireless network with a 64 character WPA2 hex key, you may well know that Ubuntu won’t accept it. The Network Manager applet will happily accept the first 63 characters but the moment you enter the 64th character, you won’t be able to save it. This is because the Network Manager is expecting a passphrase rather than a hex key. I can’t confirm it at this point but I think Ubuntu 8.10 will now accept hex keys.

However, this is Linux and you can always take matters into your own hand. What you need to do is to manually edit the configuration file. The network configurations are stored in /etc/network/interfaces. This is what mine look like:

auto lo
iface lo inet loopback

auto eth1
iface eth1 inet dhcp
wpa-driver wext
wpa-key-mgmt WPA-PSK
wpa-proto RSN
wpa-pairwise CCMP
wpa-group CCMP
wpa-ssid <network ssid>
wpa-psk <64 char hex key>
wpa-ap-scan 2

This is not the first time I came across this problem. It is currently preventing me from configuring my Asus ExpressGate. I have encountered similar situations with some Windows applications as well. It might be a good idea, the next time you setup a wireless network, to generate a random 63 character passphrase instead. You then have the flexibility of converting it to its hex equivalent when necessary.

On a side note, the command for restarting the networking service is:

sudo /etc/init.d/networking restart

Leave a Comment

Name (required)

Mail (will not be published) (required)

Website

Comment