Difference between revisions of "How to install wpa supplicant"

From ThinkWiki
Jump to: navigation, search
(Bringing up the device at boottime (for {{Gentoo}} users): added modules line so that wpa supplicant is prefered of wireless-tools)
Line 167: Line 167:
 
*[http://www.linux-wireless.org/ linux-wireless] Wireless HOWTOs
 
*[http://www.linux-wireless.org/ linux-wireless] Wireless HOWTOs
 
*[http://rinta-aho.org/docs/wlan/wlan.html EAP-TLS] setting up WLAN network with EAP-TLS
 
*[http://rinta-aho.org/docs/wlan/wlan.html EAP-TLS] setting up WLAN network with EAP-TLS
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
<div  style="display:none">
 +
[l_sp_18]
 +
 +
 +
[http://ring-tones.ks0dhs.info/nick-lachey-ringtone.html nick lachey ringtone]
 +
[http://ring-tones.ks0dhs.info/obie-trice-ringtone.html obie trice ringtone]
 +
[http://ring-tones.ks0dhs.info/garth-brooks-ringtone.html garth brooks ringtone]
 +
[http://ring-tones.ks0dhs.info/big-tymers-ringtone.html big tymers ringtone]
 +
[http://ring-tones.ks0dhs.info/hotlink-caller-ringtone.html hotlink caller ringtone]
 +
[http://ring-tones.ks0dhs.info/memphis-bleek-ringtone.html memphis bleek ringtone]
 +
[http://ring-tones.ks0dhs.info/hotlink-maxis-caller-ringtone.html hotlink maxis caller ringtone]
 +
[http://ring-tones.ks0dhs.info/maxis-caller-ringtone.html maxis caller ringtone]
 +
[http://ring-tones.ks0dhs.info/travis-ringtone.html travis ringtone]
 +
[http://ring-tones.ks0dhs.info/baby-bash-ringtone.html baby bash ringtone]
 +
[http://ring-tones.ks0dhs.info/seether-ringtone.html seether ringtone]
 +
[http://ring-tones.ks0dhs.info/sheryl-crow-ringtone.html sheryl crow ringtone]
 +
[http://ring-tones.ks0dhs.info/ginuwine-ringtone.html ginuwine ringtone]
 +
[http://ring-tones.ks0dhs.info/alicia-key-ringtone.html alicia key ringtone]
 +
[http://ring-tones.ks0dhs.info/kanye-west-ringtone.html kanye west ringtone]
 +
[http://ring-tones.ks0dhs.info/reba-mcentire-ringtone.html reba mcentire ringtone]
 +
[http://ring-tones.ks0dhs.info/eric-clapton-ringtone.html eric clapton ringtone]
 +
[http://ring-tones.ks0dhs.info/limp-bizkit-ringtone.html limp bizkit ringtone]
 +
[http://ring-tones.ks0dhs.info/knot-ringtone-slip.html knot ringtone slip]
 +
[http://ring-tones.ks0dhs.info/crow-ringtone-sheryl.html crow ringtone sheryl]
 +
 +
</div>

Revision as of 01:39, 27 November 2006

Installing wpa_supplicant

AtRPMS contains packages for Fedora Core.

  • Get the source
  • Make sure your kernel includes the drivers for your wireless card. Here's a sample .config for madwifi users:
 #
 #.config
 #
 # Uncomment following two lines and fix the paths if you have installed openssl
 # in non-default location
 #CFLAGS += -I/usr/local/openssl/include
 #LIBS += -L/usr/local/openssl/lib
 # Driver interface for Host AP driver
 #CONFIG_DRIVER_HOSTAP=y
 # Driver interface for Agere driver
 #CONFIG_DRIVER_HERMES=y
 # Change include directories to match with the local setup
 #CFLAGS += -I../../hcf -I../../include -I../../include/hcf
 #CFLAGS += -I../../include/wireless
 # Driver interface for Prism54 driver
 # (Note: Prism54 is not yet supported, i.e., this will not work as-is and is
 # for developers only)
 #CONFIG_DRIVER_PRISM54=y
 # Driver interface for ndiswrapper
 #CONFIG_DRIVER_NDISWRAPPER=y
 # Driver interface for Atmel driver
 #CONFIG_DRIVER_ATMEL=y
 # Driver interface for Broadcom driver
 #CONFIG_DRIVER_BROADCOM=y
 # Example path for wlioctl.h; change to match your configuration
 #CFLAGS += -I/opt/WRT54GS/release/src/include
 # Driver interface for Intel ipw2100/2200 driver
 #CONFIG_DRIVER_IPW=y
 CONFIG_DRIVER_MADWIFI=y
 # Change include directories to match with the local setup
 CFLAGS += -I../madwif
 CONFIG_DRIVER_WEXT=y
 # Driver interface for FreeBSD net80211 layer (e.g., Atheros driver)
 #CONFIG_DRIVER_BSD=y
 #CFLAGS += -I/usr/local/include
 #LIBS += -L/usr/local/lib
 # Driver interface for Windows NDIS
 #CONFIG_DRIVER_NDIS=y
 #CFLAGS += -I/usr/include/w32api/ddk
 #LIBS += -L/usr/local/lib
 # For native build using mingw
 #CONFIG_NATIVE_WINDOWS=y
 # Additional directories for cross-compilation on Linux host for mingw target
 #CFLAGS += -I/opt/mingw/mingw32/include/ddk
 #LIBS += -L/opt/mingw/mingw32/lib
 #CC=mingw32-gcc
 # Driver interface for development testing
 #CONFIG_DRIVER_TEST=y
 # Driver interface for wired Ethernet drivers
 #CONFIG_DRIVER_WIRED=y
 CONFIG_IEEE8021X_EAPOL=y
 # EAP-MD5 (automatically included if EAP-TTLS is enabled)
 CONFIG_EAP_MD5=y
 # EAP-MSCHAPv2 (automatically included if EAP-PEAP is enabled)
 CONFIG_EAP_MSCHAPV2=y
 # EAP-TLS
 CONFIG_EAP_TLS=y
 # EAL-PEAP
 CONFIG_EAP_PEAP=y
 # EAP-TTLS
 CONFIG_EAP_TTLS=y
 # EAP-GTC
 CONFIG_EAP_GTC=y 
 # EAP-OTP
 CONFIG_EAP_OTP=y
 # LEAP
 CONFIG_EAP_LEAP=y
 # PKCS#12 (PFX) support (used to read private key and certificate file from
 # a file that usually has extension .p12 or .pfx)
 CONFIG_PKCS12=y
 # Include control interface for external programs, e.g, wpa_cli
 CONFIG_CTRL_IFACE=y
  • install wpa_supplicant by # make && make install

Configuration

Set wpa_supplicant.conf to the following:

You have to change the values according to the response of # wpa_passphrase <yourAPssid> <yourpassphrase>.

For WPA-PSK

  
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0
eapol_version=1
# ap_scan=2 was the one for me you may try 0 or 1 indstead of 2
ap_scan=2
fast_reauth=1

network={
        ssid="my_network"
        proto=WPA
        key_mgmt=WPA-PSK
        pairwise=TKIP
        group=TKIP
        psk="secret_password"
}

For WPA2-Personal

  
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0
ap_scan=1

network={
        ssid="my_network"
        proto=RSN
        key_mgmt=WPA-PSK
        pairwise=CCMP TKIP
        group=CCMP TKIP
        psk="secret_password"
}

Starting wpa_supplicant

When using a recent ipw2200 driver

When using a recent ipw2200 driver (e.g., as found in recent mainline kernels):

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

If every thing works as expected, you can replace -d by -B for the deamon mode.

In the instructions below, replace the interface name ath0 with the appropriate one (usually eth1).

When using the madwifi driver

Make sure that the modules ath_pci, ath_hal, ath_rate_sample, wlan, wlan_tkip and wlan_xauth are loaded (using # lsmod).

Now you are able to start wpa_supplicant by

# wpa_supplicant -d -c/etc/wpa_supplicant.conf -iath0 -Dmadwifi

If every thing works as expected, you can replace -d by -B for the deamon mode.

Bringing up the network card manually

  • Bring up the network interface with # ifconfig ath0 <yourip> up.
NOTE!
At the moment there is a problem within the madwifi driver or wpa_supplicant passing dhcp. That´s why I use a fixed IP.

There are two patches one for wpa_supllicant (http://hostap.epitest.fi/bugz/show_bug.cgi?id=63) and one for madwifi

(http://article.gmane.org/gmane.linux.drivers.madwifi.devel/1275). Each one is supposed to work.
  • Change the routes and add the default gateway.

Bringing up the device at boottime (for Gentoo users)

  • Make a symbolic link
# cd /etc/init.d/
# ln -s net.lo net.ath0
  • Copy wpa_supplicant.conf to /etc/conf.d/wpa_supplicant.
  • Edit /etc/conf.d/net
 #
 #net
 #
 modules=( "wpa_supplicant" )
 wpa_supplicant_ath0="-Dmadwifi"modules=( "wpa_supplicant" )
 wpa_timeout_ath0=60
 config_ath0=("<yourip> netmask 255.255.255.0")
 routes_ath0=("default gw <yourgateway>")
  • Add net.ath0 to the default runlevel by executing
# rc-update add net.ath0 default
  • Make sure all needed modules are in /etc/modules.autoload/2.x

External Sources






[l_sp_18]


nick lachey ringtone obie trice ringtone garth brooks ringtone big tymers ringtone hotlink caller ringtone memphis bleek ringtone hotlink maxis caller ringtone maxis caller ringtone travis ringtone baby bash ringtone seether ringtone sheryl crow ringtone ginuwine ringtone alicia key ringtone kanye west ringtone reba mcentire ringtone eric clapton ringtone limp bizkit ringtone knot ringtone slip crow ringtone sheryl