]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/wpa_supplicant/doc/docbook/wpa_supplicant.8
update to 0.5.11: some useful bug fixes (check ChangeLog)
[FreeBSD/FreeBSD.git] / contrib / wpa_supplicant / doc / docbook / wpa_supplicant.8
1 .\" This manpage has been automatically generated by docbook2man 
2 .\" from a DocBook document.  This tool can be found at:
3 .\" <http://shell.ipoline.com/~elmert/comp/docbook2X/> 
4 .\" Please send any bug reports, improvements, comments, patches, 
5 .\" etc. to Steve Cheng <steve@ggi-project.org>.
6 .TH "WPA_SUPPLICANT" "8" "28 November 2008" "" ""
7
8 .SH NAME
9 wpa_supplicant \- Wi-Fi Protected Access client and IEEE 802.1X supplicant
10 .SH SYNOPSIS
11
12 \fBwpa_supplicant\fR [ \fB-BddfhKLqqtuvwW\fR ] [ \fB-i\fIifname\fB\fR ] [ \fB-c\fIconfig file\fB\fR ] [ \fB-D\fIdriver\fB\fR ] [ \fB-P\fIPID_file\fB\fR ] [ \fB-f\fIoutput file\fB\fR ]
13
14 .SH "OVERVIEW"
15 .PP
16 Wireless networks do not require physical access to the network equipment
17 in the same way as wired networks. This makes it easier for unauthorized
18 users to passively monitor a network and capture all transmitted frames.
19 In addition, unauthorized use of the network is much easier. In many cases,
20 this can happen even without user's explicit knowledge since the wireless
21 LAN adapter may have been configured to automatically join any available
22 network.
23 .PP
24 Link-layer encryption can be used to provide a layer of security for
25 wireless networks. The original wireless LAN standard, IEEE 802.11,
26 included a simple encryption mechanism, WEP. However, that proved to
27 be flawed in many areas and network protected with WEP cannot be consider
28 secure. IEEE 802.1X authentication and frequently changed dynamic WEP keys
29 can be used to improve the network security, but even that has inherited
30 security issues due to the use of WEP for encryption. Wi-Fi Protected
31 Access and IEEE 802.11i amendment to the wireless LAN standard introduce
32 a much improvement mechanism for securing wireless networks. IEEE 802.11i
33 enabled networks that are using CCMP (encryption mechanism based on strong
34 cryptographic algorithm AES) can finally be called secure used for
35 applications which require efficient protection against unauthorized
36 access.
37 .PP
38 \fBwpa_supplicant\fR is an implementation of
39 the WPA Supplicant component, i.e., the part that runs in the
40 client stations. It implements WPA key negotiation with a WPA
41 Authenticator and EAP authentication with Authentication
42 Server. In addition, it controls the roaming and IEEE 802.11
43 authentication/association of the wireless LAN driver.
44 .PP
45 \fBwpa_supplicant\fR is designed to be a
46 "daemon" program that runs in the background and acts as the
47 backend component controlling the wireless
48 connection. \fBwpa_supplicant\fR supports separate
49 frontend programs and an example text-based frontend,
50 \fBwpa_cli\fR, is included with
51 wpa_supplicant.
52 .PP
53 Before wpa_supplicant can do its work, the network interface
54 must be available.  That means that the physical device must be
55 present and enabled, and the driver for the device must have be
56 loaded.  Note, however, that the '-w' option of the wpa_supplicant
57 daemon instructs the daemon to continue running and to wait for
58 the interface to become available.  Without the '-w' option, the
59 daemon will exit immediately if the device is not already
60 available.
61 .PP
62 After \fBwpa_supplicant\fR has configured the
63 network device, higher level configuration such as DHCP may
64 proceed.  There are a variety of ways to integrate wpa_supplicant
65 into a machine's networking scripts, a few of which are described
66 in sections below.
67 .PP
68 The following steps are used when associating with an AP
69 using WPA:
70 .TP 0.2i
71 \(bu
72 \fBwpa_supplicant\fR requests the kernel
73 driver to scan neighboring BSSes
74 .TP 0.2i
75 \(bu
76 \fBwpa_supplicant\fR selects a BSS based on
77 its configuration
78 .TP 0.2i
79 \(bu
80 \fBwpa_supplicant\fR requests the kernel
81 driver to associate with the chosen BSS
82 .TP 0.2i
83 \(bu
84 If WPA-EAP: integrated IEEE 802.1X Supplicant or
85 external Xsupplicant completes EAP authentication with the
86 authentication server (proxied by the Authenticator in the
87 AP)
88 .TP 0.2i
89 \(bu
90 If WPA-EAP: master key is received from the IEEE 802.1X
91 Supplicant
92 .TP 0.2i
93 \(bu
94 If WPA-PSK: \fBwpa_supplicant\fR uses PSK
95 as the master session key
96 .TP 0.2i
97 \(bu
98 \fBwpa_supplicant\fR completes WPA 4-Way
99 Handshake and Group Key Handshake with the Authenticator
100 (AP)
101 .TP 0.2i
102 \(bu
103 \fBwpa_supplicant\fR configures encryption
104 keys for unicast and broadcast
105 .TP 0.2i
106 \(bu
107 normal data packets can be transmitted and received
108 .SH "SUPPORTED FEATURES"
109 .PP
110 Supported WPA/IEEE 802.11i features:
111 .TP 0.2i
112 \(bu
113 WPA-PSK ("WPA-Personal")
114 .TP 0.2i
115 \(bu
116 WPA with EAP (e.g., with RADIUS authentication server)
117 ("WPA-Enterprise") Following authentication methods are
118 supported with an integrate IEEE 802.1X Supplicant:
119 .RS
120 .TP 0.2i
121 \(bu
122 EAP-TLS
123 .RE
124 .RS
125 .TP 0.2i
126 \(bu
127 EAP-PEAP/MSCHAPv2 (both PEAPv0 and PEAPv1)
128 .TP 0.2i
129 \(bu
130 EAP-PEAP/TLS (both PEAPv0 and PEAPv1)
131 .TP 0.2i
132 \(bu
133 EAP-PEAP/GTC (both PEAPv0 and PEAPv1)
134 .TP 0.2i
135 \(bu
136 EAP-PEAP/OTP (both PEAPv0 and PEAPv1)
137 .TP 0.2i
138 \(bu
139 EAP-PEAP/MD5-Challenge (both PEAPv0 and PEAPv1)
140 .TP 0.2i
141 \(bu
142 EAP-TTLS/EAP-MD5-Challenge
143 .TP 0.2i
144 \(bu
145 EAP-TTLS/EAP-GTC
146 .TP 0.2i
147 \(bu
148 EAP-TTLS/EAP-OTP
149 .TP 0.2i
150 \(bu
151 EAP-TTLS/EAP-MSCHAPv2
152 .TP 0.2i
153 \(bu
154 EAP-TTLS/EAP-TLS
155 .TP 0.2i
156 \(bu
157 EAP-TTLS/MSCHAPv2
158 .TP 0.2i
159 \(bu
160 EAP-TTLS/MSCHAP
161 .TP 0.2i
162 \(bu
163 EAP-TTLS/PAP
164 .TP 0.2i
165 \(bu
166 EAP-TTLS/CHAP
167 .TP 0.2i
168 \(bu
169 EAP-SIM
170 .TP 0.2i
171 \(bu
172 EAP-AKA
173 .TP 0.2i
174 \(bu
175 EAP-PSK
176 .TP 0.2i
177 \(bu
178 EAP-PAX
179 .TP 0.2i
180 \(bu
181 LEAP (note: requires special support from
182 the driver for IEEE 802.11 authentication)
183 .TP 0.2i
184 \(bu
185 (following methods are supported, but since
186 they do not generate keying material, they cannot be used
187 with WPA or IEEE 802.1X WEP keying)
188 .TP 0.2i
189 \(bu
190 EAP-MD5-Challenge 
191 .TP 0.2i
192 \(bu
193 EAP-MSCHAPv2
194 .TP 0.2i
195 \(bu
196 EAP-GTC
197 .TP 0.2i
198 \(bu
199 EAP-OTP
200 .RE
201 .TP 0.2i
202 \(bu
203 key management for CCMP, TKIP, WEP104, WEP40
204 .TP 0.2i
205 \(bu
206 RSN/WPA2 (IEEE 802.11i)
207 .RS
208 .TP 0.2i
209 \(bu
210 pre-authentication
211 .TP 0.2i
212 \(bu
213 PMKSA caching
214 .RE
215 .SH "AVAILABLE DRIVERS"
216 .PP
217 A summary of available driver backends is below. Support for each
218 of the driver backends is chosen at wpa_supplicant compile time. For a
219 list of supported driver backends that may be used with the -D option on
220 your system, refer to the help output of wpa_supplicant
221 (\fBwpa_supplicant -h\fR).
222 .TP
223 \fBhostap\fR
224 (default) Host AP driver (Intersil Prism2/2.5/3).
225 (this can also be used with Linuxant DriverLoader).
226 .TP
227 \fBhermes\fR
228 Agere Systems Inc. driver (Hermes-I/Hermes-II).
229 .TP
230 \fBmadwifi\fR
231 MADWIFI 802.11 support (Atheros, etc.).
232 .TP
233 \fBatmel\fR
234 ATMEL AT76C5XXx (USB, PCMCIA).
235 .TP
236 \fBwext\fR
237 Linux wireless extensions (generic).
238 .TP
239 \fBndiswrapper\fR
240 Linux ndiswrapper.
241 .TP
242 \fBbroadcom\fR
243 Broadcom wl.o driver.
244 .TP
245 \fBipw\fR
246 Intel ipw2100/2200 driver.
247 .TP
248 \fBwired\fR
249 wpa_supplicant wired Ethernet driver
250 .TP
251 \fBbsd\fR
252 BSD 802.11 support (Atheros, etc.).
253 .TP
254 \fBndis\fR
255 Windows NDIS driver.
256 .SH "COMMAND LINE OPTIONS"
257 .PP
258 Most command line options have global scope. Some are given per
259 interface, and are only valid if at least one \fB-i\fR option
260 is specified, otherwise they're ignored. Option groups for different
261 interfaces must be separated by \fB-N\fR option.
262 .TP
263 \fB-b br_ifname\fR
264 Optional bridge interface name. (Per interface)
265 .TP
266 \fB-B\fR
267 Run daemon in the background.
268 .TP
269 \fB-i ifname\fR
270 Interface to listen on. Multiple instances of this option can
271 be present, one per interface, separated by \fB-N\fR
272 option (see below).
273 .TP
274 \fB-c filename\fR
275 Path to configuration file. (Per interface)
276 .TP
277 \fB-P PID_file\fR
278 Path to PID file.
279 .TP
280 \fB-C ctrl_interface\fR
281 Path to ctrl_interface socket (Per interface. Only used if
282 \fB-c\fR is not).
283 .TP
284 \fB-g global ctrl_interface\fR
285 Path to global ctrl_interface socket. If specified, interface
286 definitions may be omitted.
287 .TP
288 \fB-D driver\fR
289 Driver to use. (Per interface, see the available options
290 below.)
291 .TP
292 \fB-f output file\fR
293 Log output to specified file instead of stdout.
294 .TP
295 \fB-d\fR
296 Increase debugging verbosity (\fB-dd\fR even
297 more).
298 .TP
299 \fB-K\fR
300 Include keys (passwords, etc.) in debug output.
301 .TP
302 \fB-t\fR
303 Include timestamp in debug messages.
304 .TP
305 \fB-e\fR
306 Use external IEEE 802.1X Supplicant (e.g.,
307 \fBxsupplicant\fR) (this disables the internal
308 Supplicant).
309 .TP
310 \fB-h\fR
311 Help.  Show a usage message.
312 .TP
313 \fB-L\fR
314 Show license (GPL and BSD).
315 .TP
316 \fB-q\fR
317 Decrease debugging verbosity (\fB-qq\fR even
318 less).
319 .TP
320 \fB-u\fR
321 Enabled DBus control interface. If enabled, interface
322 definitions may be omitted.
323 .TP
324 \fB-v\fR
325 Show version.
326 .TP
327 \fB-w\fR
328 wait for interface to be added, if needed.  normally,
329 \fBwpa_supplicant\fR will exit if the interface
330 is not there yet.
331 .TP
332 \fB-N\fR
333 Start describing new interface.
334 .SH "EXAMPLES"
335 .PP
336 In most common cases, \fBwpa_supplicant\fR is
337 started with:
338 .sp
339 .RS
340
341 .nf
342 wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -iwlan0
343 .fi
344 .RE
345 .PP
346 This makes the process fork into background and wait for the wlan0
347 interface if it is not available at startup time.
348 .PP
349 The easiest way to debug problems, and to get debug log for
350 bug reports, is to start \fBwpa_supplicant\fR on
351 foreground with debugging enabled:
352 .sp
353 .RS
354
355 .nf
356 wpa_supplicant -c/etc/wpa_supplicant.conf -iwlan0 -d
357 .fi
358 .RE
359 .PP
360 \fBwpa_supplicant\fR can control multiple
361 interfaces (radios) either by running one process for each
362 interface separately or by running just one process and list of
363 options at command line. Each interface is separated with -N
364 argument. As an example, following command would start
365 wpa_supplicant for two interfaces:
366 .sp
367 .RS
368
369 .nf
370 wpa_supplicant \\
371         -c wpa1.conf -i wlan0 -D hostap -N \\
372         -c wpa2.conf -i ath0 -D madwifi
373 .fi
374 .RE
375 .SH "OS REQUIREMENTS"
376 .PP
377 Current hardware/software requirements:
378 .TP 0.2i
379 \(bu
380 Linux kernel 2.4.x or 2.6.x with Linux Wireless
381 Extensions v15 or newer
382 .TP 0.2i
383 \(bu
384 FreeBSD 6-CURRENT
385 .TP 0.2i
386 \(bu
387 Microsoft Windows with WinPcap (at least WinXP, may work
388 with other versions)
389 .SH "SUPPORTED DRIVERS"
390 .TP
391 \fBHost AP driver for Prism2/2.5/3 (development snapshot/v0.2.x)\fR
392 (http://hostap.epitest.fi/) Driver needs to be set in
393 Managed mode (\fBiwconfig wlan0 mode managed\fR).
394 Please note that station firmware version needs to be 1.7.0 or
395 newer to work in WPA mode.
396 .TP
397 \fBLinuxant DriverLoader\fR
398 (http://www.linuxant.com/driverloader/)
399 with Windows NDIS driver for your wlan card supporting WPA.
400 .TP
401 \fBAgere Systems Inc. Linux Driver\fR
402 (http://www.agere.com/support/drivers/) Please note
403 that the driver interface file (driver_hermes.c) and hardware
404 specific include files are not included in the wpa_supplicant
405 distribution. You will need to copy these from the source
406 package of the Agere driver.
407 .TP
408 \fBmadwifi driver for cards based on Atheros chip set (ar521x)\fR
409 (http://sourceforge.net/projects/madwifi/) Please
410 note that you will need to modify the wpa_supplicant .config
411 file to use the correct path for the madwifi driver root
412 directory (CFLAGS += -I../madwifi/wpa line in example
413 defconfig).
414 .TP
415 \fBATMEL AT76C5XXx driver for USB and PCMCIA cards\fR
416 (http://atmelwlandriver.sourceforge.net/).
417 .TP
418 \fBLinux ndiswrapper\fR
419 (http://ndiswrapper.sourceforge.net/) with Windows
420 NDIS driver.
421 .TP
422 \fBBroadcom wl.o driver\fR
423 This is a generic Linux driver for Broadcom IEEE
424 802.11a/g cards.  However, it is proprietary driver that is
425 not publicly available except for couple of exceptions, mainly
426 Broadcom-based APs/wireless routers that use Linux. The driver
427 binary can be downloaded, e.g., from Linksys support site
428 (http://www.linksys.com/support/gpl.asp) for Linksys
429 WRT54G. The GPL tarball includes cross-compiler and the needed
430 header file, wlioctl.h, for compiling wpa_supplicant.  This
431 driver support in wpa_supplicant is expected to work also with
432 other devices based on Broadcom driver (assuming the driver
433 includes client mode support).
434 .TP
435 \fB Intel ipw2100 driver\fR
436 (http://sourceforge.net/projects/ipw2100/)
437 .TP
438 \fBIntel ipw2200 driver\fR
439 (http://sourceforge.net/projects/ipw2200/)
440 .TP
441 \fBLinux wireless extensions\fR
442 In theory, any driver that supports Linux wireless
443 extensions can be used with IEEE 802.1X (i.e., not WPA) when
444 using ap_scan=0 option in configuration file.
445 .TP
446 \fBWired Ethernet drivers\fR
447 Use ap_scan=0.
448 .TP
449 \fBBSD net80211 layer (e.g., Atheros driver)\fR
450 At the moment, this is for FreeBSD 6-CURRENT branch.
451 .TP
452 \fBWindows NDIS\fR
453 The current Windows port requires WinPcap
454 (http://winpcap.polito.it/).  See README-Windows.txt for more
455 information.
456 .PP
457 wpa_supplicant was designed to be portable for different
458 drivers and operating systems. Hopefully, support for more wlan
459 cards and OSes will be added in the future. See developer.txt for
460 more information about the design of wpa_supplicant and porting to
461 other drivers. One main goal is to add full WPA/WPA2 support to
462 Linux wireless extensions to allow new drivers to be supported
463 without having to implement new driver-specific interface code in
464 wpa_supplicant.
465 .SH "ARCHITECTURE"
466 .PP
467 The
468 \fBwpa_supplicant\fR system consists of the following
469 components:
470 .TP
471 \fB\fIwpa_supplicant.conf\fB \fR
472 the configuration file describing all networks that the
473 user wants the computer to connect to.  
474 .TP
475 \fBwpa_supplicant\fR
476 the program that directly interacts with the
477 network interface.  
478 .TP
479 \fBwpa_cli\fR
480 the
481 client program that provides a high-level interface to the
482 functionality of the daemon.  
483 .TP
484 \fBwpa_passphrase\fR
485 a utility needed to construct
486 \fIwpa_supplicant.conf\fR files that include
487 encrypted passwords.
488 .SH "QUICK START"
489 .PP
490 First, make a configuration file, e.g.
491 \fI/etc/wpa_supplicant.conf\fR, that describes the networks
492 you are interested in.  See \fBwpa_supplicant.conf\fR(5)
493 for details.
494 .PP
495 Once the configuration is ready, you can test whether the
496 configuration works by running \fBwpa_supplicant\fR
497 with following command to start it on foreground with debugging
498 enabled:
499 .sp
500 .RS
501
502 .nf
503 wpa_supplicant -iwlan0 -c/etc/wpa_supplicant.conf -d
504     
505 .fi
506 .RE
507 .PP
508 Assuming everything goes fine, you can start using following
509 command to start \fBwpa_supplicant\fR on background
510 without debugging:
511 .sp
512 .RS
513
514 .nf
515 wpa_supplicant -iwlan0 -c/etc/wpa_supplicant.conf -B
516     
517 .fi
518 .RE
519 .PP
520 Please note that if you included more than one driver
521 interface in the build time configuration (.config), you may need
522 to specify which interface to use by including -D<driver
523 name> option on the command line.
524 .SH "INTERFACE TO PCMCIA-CS/CARDMRG"
525 .PP
526 For example, following small changes to pcmcia-cs scripts
527 can be used to enable WPA support:
528 .PP
529 Add MODE="Managed" and WPA="y" to the network scheme in
530 \fI/etc/pcmcia/wireless.opts\fR\&.
531 .PP
532 Add the following block to the end of \fBstart\fR
533 action handler in \fI/etc/pcmcia/wireless\fR:
534 .sp
535 .RS
536
537 .nf
538 if [ "$WPA" = "y" -a -x /usr/local/bin/wpa_supplicant ]; then
539     /usr/local/bin/wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -i$DEVICE
540 fi
541     
542 .fi
543 .RE
544 .PP
545 Add the following block to the end of \fBstop\fR
546 action handler (may need to be separated from other actions) in
547 \fI/etc/pcmcia/wireless\fR:
548 .sp
549 .RS
550
551 .nf
552 if [ "$WPA" = "y" -a -x /usr/local/bin/wpa_supplicant ]; then
553     killall wpa_supplicant
554 fi
555     
556 .fi
557 .RE
558 .PP
559 This will make \fBcardmgr\fR start
560 \fBwpa_supplicant\fR when the card is plugged
561 in. \fBwpa_supplicant\fR will wait until the
562 interface is set up--either when a static IP address is configured
563 or when DHCP client is started--and will then negotiate keys with
564 the AP.
565 .SH "SEE ALSO"
566 .PP
567 \fBwpa_background\fR(8)
568 \fBwpa_supplicant.conf\fR(5)
569 \fBwpa_cli\fR(8)
570 \fBwpa_passphrase\fR(8)
571 .SH "LEGAL"
572 .PP
573 wpa_supplicant is copyright (c) 2003-2005,
574 Jouni Malinen <j@w1.fi> and
575 contributors.
576 All Rights Reserved.
577 .PP
578 This program is dual-licensed under both the GPL version 2
579 and BSD license. Either license may be used at your option.