]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - wpa_supplicant/doc/docbook/wpa_supplicant.8
Import wpa_supplicant/hostapd 2.5.
[FreeBSD/FreeBSD.git] / 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" "27 September 2015" "" ""
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-BddfhKLqqsTtuvW\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 be
56 loaded. The daemon will exit immediately if the device is not already
57 available.
58 .PP
59 After \fBwpa_supplicant\fR has configured the
60 network device, higher level configuration such as DHCP may
61 proceed.  There are a variety of ways to integrate wpa_supplicant
62 into a machine's networking scripts, a few of which are described
63 in sections below.
64 .PP
65 The following steps are used when associating with an AP
66 using WPA:
67 .TP 0.2i
68 \(bu
69 \fBwpa_supplicant\fR requests the kernel
70 driver to scan neighboring BSSes
71 .TP 0.2i
72 \(bu
73 \fBwpa_supplicant\fR selects a BSS based on
74 its configuration
75 .TP 0.2i
76 \(bu
77 \fBwpa_supplicant\fR requests the kernel
78 driver to associate with the chosen BSS
79 .TP 0.2i
80 \(bu
81 If WPA-EAP: integrated IEEE 802.1X Supplicant
82 completes EAP authentication with the
83 authentication server (proxied by the Authenticator in the
84 AP)
85 .TP 0.2i
86 \(bu
87 If WPA-EAP: master key is received from the IEEE 802.1X
88 Supplicant
89 .TP 0.2i
90 \(bu
91 If WPA-PSK: \fBwpa_supplicant\fR uses PSK
92 as the master session key
93 .TP 0.2i
94 \(bu
95 \fBwpa_supplicant\fR completes WPA 4-Way
96 Handshake and Group Key Handshake with the Authenticator
97 (AP)
98 .TP 0.2i
99 \(bu
100 \fBwpa_supplicant\fR configures encryption
101 keys for unicast and broadcast
102 .TP 0.2i
103 \(bu
104 normal data packets can be transmitted and received
105 .SH "SUPPORTED FEATURES"
106 .PP
107 Supported WPA/IEEE 802.11i features:
108 .TP 0.2i
109 \(bu
110 WPA-PSK ("WPA-Personal")
111 .TP 0.2i
112 \(bu
113 WPA with EAP (e.g., with RADIUS authentication server)
114 ("WPA-Enterprise") Following authentication methods are
115 supported with an integrate IEEE 802.1X Supplicant:
116 .RS
117 .TP 0.2i
118 \(bu
119 EAP-TLS
120 .RE
121 .RS
122 .TP 0.2i
123 \(bu
124 EAP-PEAP/MSCHAPv2 (both PEAPv0 and PEAPv1)
125 .TP 0.2i
126 \(bu
127 EAP-PEAP/TLS (both PEAPv0 and PEAPv1)
128 .TP 0.2i
129 \(bu
130 EAP-PEAP/GTC (both PEAPv0 and PEAPv1)
131 .TP 0.2i
132 \(bu
133 EAP-PEAP/OTP (both PEAPv0 and PEAPv1)
134 .TP 0.2i
135 \(bu
136 EAP-PEAP/MD5-Challenge (both PEAPv0 and PEAPv1)
137 .TP 0.2i
138 \(bu
139 EAP-TTLS/EAP-MD5-Challenge
140 .TP 0.2i
141 \(bu
142 EAP-TTLS/EAP-GTC
143 .TP 0.2i
144 \(bu
145 EAP-TTLS/EAP-OTP
146 .TP 0.2i
147 \(bu
148 EAP-TTLS/EAP-MSCHAPv2
149 .TP 0.2i
150 \(bu
151 EAP-TTLS/EAP-TLS
152 .TP 0.2i
153 \(bu
154 EAP-TTLS/MSCHAPv2
155 .TP 0.2i
156 \(bu
157 EAP-TTLS/MSCHAP
158 .TP 0.2i
159 \(bu
160 EAP-TTLS/PAP
161 .TP 0.2i
162 \(bu
163 EAP-TTLS/CHAP
164 .TP 0.2i
165 \(bu
166 EAP-SIM
167 .TP 0.2i
168 \(bu
169 EAP-AKA
170 .TP 0.2i
171 \(bu
172 EAP-PSK
173 .TP 0.2i
174 \(bu
175 EAP-PAX
176 .TP 0.2i
177 \(bu
178 LEAP (note: requires special support from
179 the driver for IEEE 802.11 authentication)
180 .TP 0.2i
181 \(bu
182 (following methods are supported, but since
183 they do not generate keying material, they cannot be used
184 with WPA or IEEE 802.1X WEP keying)
185 .TP 0.2i
186 \(bu
187 EAP-MD5-Challenge 
188 .TP 0.2i
189 \(bu
190 EAP-MSCHAPv2
191 .TP 0.2i
192 \(bu
193 EAP-GTC
194 .TP 0.2i
195 \(bu
196 EAP-OTP
197 .RE
198 .TP 0.2i
199 \(bu
200 key management for CCMP, TKIP, WEP104, WEP40
201 .TP 0.2i
202 \(bu
203 RSN/WPA2 (IEEE 802.11i)
204 .RS
205 .TP 0.2i
206 \(bu
207 pre-authentication
208 .TP 0.2i
209 \(bu
210 PMKSA caching
211 .RE
212 .SH "AVAILABLE DRIVERS"
213 .PP
214 A summary of available driver backends is below. Support for each
215 of the driver backends is chosen at wpa_supplicant compile time. For a
216 list of supported driver backends that may be used with the -D option on
217 your system, refer to the help output of wpa_supplicant
218 (\fBwpa_supplicant -h\fR).
219 .TP
220 \fBwext\fR
221 Linux wireless extensions (generic).
222 .TP
223 \fBwired\fR
224 wpa_supplicant wired Ethernet driver
225 .TP
226 \fBroboswitch\fR
227 wpa_supplicant Broadcom switch driver
228 .TP
229 \fBbsd\fR
230 BSD 802.11 support (Atheros, etc.).
231 .TP
232 \fBndis\fR
233 Windows NDIS driver.
234 .SH "COMMAND LINE OPTIONS"
235 .PP
236 Most command line options have global scope. Some are given per
237 interface, and are only valid if at least one \fB-i\fR option
238 is specified, otherwise they're ignored. Option groups for different
239 interfaces must be separated by \fB-N\fR option.
240 .TP
241 \fB-b br_ifname\fR
242 Optional bridge interface name. (Per interface)
243 .TP
244 \fB-B\fR
245 Run daemon in the background.
246 .TP
247 \fB-c filename\fR
248 Path to configuration file. (Per interface)
249 .TP
250 \fB-C ctrl_interface\fR
251 Path to ctrl_interface socket (Per interface. Only used if
252 \fB-c\fR is not).
253 .TP
254 \fB-i ifname\fR
255 Interface to listen on. Multiple instances of this option can
256 be present, one per interface, separated by \fB-N\fR
257 option (see below).
258 .TP
259 \fB-d\fR
260 Increase debugging verbosity (\fB-dd\fR even
261 more).
262 .TP
263 \fB-D driver\fR
264 Driver to use (can be multiple drivers: nl80211,wext).
265 (Per interface, see the available options below.)
266 .TP
267 \fB-e entropy file\fR
268 File for \fBwpa_supplicant\fR to use to
269 maintain its internal entropy store in over restarts.
270 .TP
271 \fB-f output file\fR
272 Log output to specified file instead of stdout. (This
273 is only available if \fBwpa_supplicant\fR was
274 built with the CONFIG_DEBUG_FILE
275 option.)
276 .TP
277 \fB-g global ctrl_interface\fR
278 Path to global ctrl_interface socket. If specified, interface
279 definitions may be omitted.
280 .TP
281 \fB-K\fR
282 Include keys (passwords, etc.) in debug output.
283 .TP
284 \fB-t\fR
285 Include timestamp in debug messages.
286 .TP
287 \fB-h\fR
288 Help.  Show a usage message.
289 .TP
290 \fB-L\fR
291 Show license (BSD).
292 .TP
293 \fB-o override driver\fR
294 Override the driver parameter for new
295 interfaces.
296 .TP
297 \fB-O override ctrl_interface\fR
298 Override the ctrl_interface parameter for new
299 interfaces.
300 .TP
301 \fB-p\fR
302 Driver parameters. (Per interface)
303 .TP
304 \fB-P PID_file\fR
305 Path to PID file.
306 .TP
307 \fB-q\fR
308 Decrease debugging verbosity (\fB-qq\fR even
309 less).
310 .TP
311 \fB-s\fR
312 Log output to syslog instead of stdout. (This is only
313 available if \fBwpa_supplicant\fR was built
314 with the CONFIG_DEBUG_SYSLOG
315 option.)
316 .TP
317 \fB-T\fR
318 Log output to Linux tracing in addition to any other
319 destinations. (This is only available
320 if \fBwpa_supplicant\fR was built with
321 the CONFIG_DEBUG_LINUX_TRACING
322 option.)
323 .TP
324 \fB-t\fR
325 Include timestamp in debug messages.
326 .TP
327 \fB-u\fR
328 Enable DBus control interface. If enabled, interface
329 definitions may be omitted. (This is only available
330 if \fBwpa_supplicant\fR was built with
331 the CONFIG_DBUS option.)
332 .TP
333 \fB-v\fR
334 Show version.
335 .TP
336 \fB-W\fR
337 Wait for a control interface monitor before starting.
338 .TP
339 \fB-N\fR
340 Start describing new interface.
341 .SH "EXAMPLES"
342 .PP
343 In most common cases, \fBwpa_supplicant\fR is
344 started with:
345 .sp
346 .RS
347
348 .nf
349 wpa_supplicant -B -c/etc/wpa_supplicant.conf -iwlan0
350 .fi
351 .RE
352 .PP
353 This makes the process fork into background.
354 .PP
355 The easiest way to debug problems, and to get debug log for
356 bug reports, is to start \fBwpa_supplicant\fR on
357 foreground with debugging enabled:
358 .sp
359 .RS
360
361 .nf
362 wpa_supplicant -c/etc/wpa_supplicant.conf -iwlan0 -d
363 .fi
364 .RE
365 .PP
366 If the specific driver wrapper is not known beforehand, it is
367 possible to specify multiple comma separated driver wrappers on the command
368 line. \fBwpa_supplicant\fR will use the first driver
369 wrapper that is able to initialize the interface.
370 .sp
371 .RS
372
373 .nf
374 wpa_supplicant -Dnl80211,wext -c/etc/wpa_supplicant.conf -iwlan0
375 .fi
376 .RE
377 .PP
378 \fBwpa_supplicant\fR can control multiple
379 interfaces (radios) either by running one process for each
380 interface separately or by running just one process and list of
381 options at command line. Each interface is separated with -N
382 argument. As an example, following command would start
383 wpa_supplicant for two interfaces:
384 .sp
385 .RS
386
387 .nf
388 wpa_supplicant \\
389         -c wpa1.conf -i wlan0 -D nl80211 -N \\
390         -c wpa2.conf -i ath0 -D wext
391 .fi
392 .RE
393 .SH "OS REQUIREMENTS"
394 .PP
395 Current hardware/software requirements:
396 .TP 0.2i
397 \(bu
398 Linux kernel 2.4.x or 2.6.x with Linux Wireless
399 Extensions v15 or newer
400 .TP 0.2i
401 \(bu
402 FreeBSD 6-CURRENT
403 .TP 0.2i
404 \(bu
405 Microsoft Windows with WinPcap (at least WinXP, may work
406 with other versions)
407 .SH "SUPPORTED DRIVERS"
408 .TP
409 \fBLinux wireless extensions\fR
410 In theory, any driver that supports Linux wireless
411 extensions can be used with IEEE 802.1X (i.e., not WPA) when
412 using ap_scan=0 option in configuration file.
413 .TP
414 \fBWired Ethernet drivers\fR
415 Use ap_scan=0.
416 .TP
417 \fBBSD net80211 layer (e.g., Atheros driver)\fR
418 At the moment, this is for FreeBSD 6-CURRENT branch.
419 .TP
420 \fBWindows NDIS\fR
421 The current Windows port requires WinPcap
422 (http://winpcap.polito.it/).  See README-Windows.txt for more
423 information.
424 .PP
425 wpa_supplicant was designed to be portable for different
426 drivers and operating systems. Hopefully, support for more wlan
427 cards and OSes will be added in the future. See developer.txt for
428 more information about the design of wpa_supplicant and porting to
429 other drivers. One main goal is to add full WPA/WPA2 support to
430 Linux wireless extensions to allow new drivers to be supported
431 without having to implement new driver-specific interface code in
432 wpa_supplicant.
433 .SH "ARCHITECTURE"
434 .PP
435 The
436 \fBwpa_supplicant\fR system consists of the following
437 components:
438 .TP
439 \fB\fIwpa_supplicant.conf\fB \fR
440 the configuration file describing all networks that the
441 user wants the computer to connect to.  
442 .TP
443 \fBwpa_supplicant\fR
444 the program that directly interacts with the
445 network interface.  
446 .TP
447 \fBwpa_cli\fR
448 the
449 client program that provides a high-level interface to the
450 functionality of the daemon.  
451 .TP
452 \fBwpa_passphrase\fR
453 a utility needed to construct
454 \fIwpa_supplicant.conf\fR files that include
455 encrypted passwords.
456 .SH "QUICK START"
457 .PP
458 First, make a configuration file, e.g.
459 \fI/etc/wpa_supplicant.conf\fR, that describes the networks
460 you are interested in.  See \fBwpa_supplicant.conf\fR(5)
461 for details.
462 .PP
463 Once the configuration is ready, you can test whether the
464 configuration works by running \fBwpa_supplicant\fR
465 with following command to start it on foreground with debugging
466 enabled:
467 .sp
468 .RS
469
470 .nf
471 wpa_supplicant -iwlan0 -c/etc/wpa_supplicant.conf -d
472     
473 .fi
474 .RE
475 .PP
476 Assuming everything goes fine, you can start using following
477 command to start \fBwpa_supplicant\fR on background
478 without debugging:
479 .sp
480 .RS
481
482 .nf
483 wpa_supplicant -iwlan0 -c/etc/wpa_supplicant.conf -B
484     
485 .fi
486 .RE
487 .PP
488 Please note that if you included more than one driver
489 interface in the build time configuration (.config), you may need
490 to specify which interface to use by including -D<driver
491 name> option on the command line.
492 .SH "INTERFACE TO PCMCIA-CS/CARDMRG"
493 .PP
494 For example, following small changes to pcmcia-cs scripts
495 can be used to enable WPA support:
496 .PP
497 Add MODE="Managed" and WPA="y" to the network scheme in
498 \fI/etc/pcmcia/wireless.opts\fR\&.
499 .PP
500 Add the following block to the end of \fBstart\fR
501 action handler in \fI/etc/pcmcia/wireless\fR:
502 .sp
503 .RS
504
505 .nf
506 if [ "$WPA" = "y" -a -x /usr/local/bin/wpa_supplicant ]; then
507     /usr/local/bin/wpa_supplicant -B -c/etc/wpa_supplicant.conf -i$DEVICE
508 fi
509     
510 .fi
511 .RE
512 .PP
513 Add the following block to the end of \fBstop\fR
514 action handler (may need to be separated from other actions) in
515 \fI/etc/pcmcia/wireless\fR:
516 .sp
517 .RS
518
519 .nf
520 if [ "$WPA" = "y" -a -x /usr/local/bin/wpa_supplicant ]; then
521     killall wpa_supplicant
522 fi
523     
524 .fi
525 .RE
526 .PP
527 This will make \fBcardmgr\fR start
528 \fBwpa_supplicant\fR when the card is plugged
529 in.
530 .SH "SEE ALSO"
531 .PP
532 \fBwpa_background\fR(8)
533 \fBwpa_supplicant.conf\fR(5)
534 \fBwpa_cli\fR(8)
535 \fBwpa_passphrase\fR(8)
536 .SH "LEGAL"
537 .PP
538 wpa_supplicant is copyright (c) 2003-2015,
539 Jouni Malinen <j@w1.fi> and
540 contributors.
541 All Rights Reserved.
542 .PP
543 This program is licensed under the BSD license (the one with
544 advertisement clause removed).