source: networking/netprogs/wpa_supplicant.xml@ c67fbf64

systemd-11177
Last change on this file since c67fbf64 was c67fbf64, checked in by Krejzi <krejzi@…>, 11 years ago

Remove packages that are now in lfs systemd from blfs.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/branches/systemd@11302 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 15.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY wpa_supplicant-download-http
8 "http://hostap.epitest.fi/releases/wpa_supplicant-&wpa_supplicant-version;.tar.gz">
9 <!ENTITY wpa_supplicant-download-ftp " ">
10 <!ENTITY wpa_supplicant-md5sum "3be2ebfdcced52e00eda0afe2889839d">
11 <!ENTITY wpa_supplicant-size "2.0 MB">
12 <!ENTITY wpa_supplicant-buildsize "32 MB">
13 <!ENTITY wpa_supplicant-time "0.2 SBU">
14]>
15
16<sect1 id="wpa_supplicant" xreflabel="wpa_supplicant-&wpa_supplicant-version;">
17 <?dbhtml filename="wpa_supplicant.html"?>
18
19 <sect1info>
20 <othername>$LastChangedBy$</othername>
21 <date>$Date$</date>
22 </sect1info>
23
24 <title>wpa_supplicant-&wpa_supplicant-version;</title>
25
26 <indexterm zone="wpa_supplicant">
27 <primary sortas="a-wpa_supplicant">wpa_supplicant</primary>
28 </indexterm>
29
30 <sect2 role="package">
31 <title>Introduction to WPA Supplicant</title>
32
33 <para>
34 <application>WPA Supplicant</application> is a Wi-Fi Protected Access
35 (WPA) client and IEEE 802.1X supplicant. It implements WPA key negotiation
36 with a WPA Authenticator and Extensible Authentication Protocol (EAP)
37 authentication with an Authentication Server. In addition, it controls the
38 roaming and IEEE 802.11 authentication/association of the wireless LAN
39 driver. This is useful for connecting to a password protected wireless
40 access point.
41 </para>
42
43 &lfs73_checked;
44
45 <bridgehead renderas="sect3">Package Information</bridgehead>
46 <itemizedlist spacing="compact">
47 <listitem>
48 <para>
49 Download (HTTP): <ulink url="&wpa_supplicant-download-http;"/>
50 </para>
51 </listitem>
52 <listitem>
53 <para>
54 Download (FTP): <ulink url="&wpa_supplicant-download-ftp;"/>
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Download MD5 sum: &wpa_supplicant-md5sum;
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Download size: &wpa_supplicant-size;
65 </para>
66 </listitem>
67 <listitem>
68 <para>
69 Estimated disk space required: &wpa_supplicant-buildsize;
70 </para>
71 </listitem>
72 <listitem>
73 <para>
74 Estimated build time: &wpa_supplicant-time;
75 </para>
76 </listitem>
77 </itemizedlist>
78
79 <bridgehead renderas="sect3">WPA Supplicant Dependencies</bridgehead>
80
81 <bridgehead renderas="sect4">Recommended</bridgehead>
82 <para role="recommended">
83 <xref linkend="libnl"/> and
84 <xref linkend="openssl"/>
85 </para>
86
87 <bridgehead renderas="sect4">Optional</bridgehead>
88 <para role="optional">
89 <xref linkend="qt4"/>
90 </para>
91
92 <para condition="html" role="usernotes">User Notes:
93 <ulink url="&blfs-wiki;/wpa_supplicant"/>
94 </para>
95 </sect2>
96
97 <sect2 role="kernel" id="wpa_supplicant-kernel">
98 <title>Kernel Configuration</title>
99
100 <para>
101 Enable the following options in the kernel configuration
102 and recompile the kernel if necessary:
103 </para>
104
105<screen><literal>[*] Networking support --->
106 [*] Wireless --->
107 [*] cfg80211 - wireless configuration API
108 [*] cfg80211 wireless extensions compatibility
109 [*] Generic IEEE 802.11 Networking Stack (mac80211)
110
111Device Drivers --->
112 [*] Network device support --->
113 [*] Wireless LAN --->
114</literal></screen>
115
116 <para>
117 Select the options that support your hardware:
118 <command>lspci</command> from <xref linkend="pciutils"/> can be used to
119 view your hardware configuration.
120 </para>
121
122 <indexterm zone="wpa_supplicant wpa_supplicant-kernel">
123 <primary sortas="d-wpa_supplicant">wpa_supplicant</primary>
124 </indexterm>
125 </sect2>
126
127 <sect2 role="installation">
128 <title>Installation of WPA Supplicant</title>
129
130 <para>
131 First you will need to create an initial configuration file for the
132 build process. You can read <filename>wpa_supplicant/README</filename>
133 and <filename>wpa_supplicant/defconfig</filename> for the explanation
134 of the following options as well as other options that can be used.
135 Create a build configuration file that should work for standard WiFi
136 setups by running the following command:
137 </para>
138
139<screen><userinput>cat &gt; wpa_supplicant/.config &lt;&lt; "EOF"
140CONFIG_BACKEND=file
141CONFIG_CTRL_IFACE=y
142CONFIG_DEBUG_FILE=y
143CONFIG_DEBUG_SYSLOG=y
144CONFIG_DEBUG_SYSLOG_FACILITY=LOG_DAEMON
145CONFIG_DRIVER_NL80211=y
146CONFIG_DRIVER_WEXT=y
147CONFIG_DRIVER_WIRED=y
148CONFIG_EAP_GTC=y
149CONFIG_EAP_LEAP=y
150CONFIG_EAP_MD5=y
151CONFIG_EAP_MSCHAPV2=y
152CONFIG_EAP_OTP=y
153CONFIG_EAP_PEAP=y
154CONFIG_EAP_TLS=y
155CONFIG_EAP_TTLS=y
156CONFIG_IEEE8021X_EAPOL=y
157CONFIG_IPV6=y
158CONFIG_LIBNL32=y
159CONFIG_PEERKEY=y
160CONFIG_PKCS12=y
161CONFIG_READLINE=y
162CONFIG_SMARTCARD=y
163CONFIG_WPS=y
164CFLAGS += -I/usr/include/libnl3
165CONFIG_CTRL_IFACE_DBUS=y
166CONFIG_CTRL_IFACE_DBUS_NEW=y
167CONFIG_CTRL_IFACE_DBUS_INTRO=y
168EOF</userinput></screen>
169
170 <para>
171 Install <application>WPA Supplicant</application> by running the
172 following commands:
173 </para>
174
175<screen><userinput>cd wpa_supplicant &amp;&amp;
176make BINDIR=/sbin LIBDIR=/lib</userinput></screen>
177
178 <para>
179 If you have installed <xref linkend="qt4"/> and wish to build
180 the <application>WPA Supplicant</application> GUI program, run
181 the following commands:
182 </para>
183
184<screen><userinput>pushd wpa_gui-qt4 &amp;&amp;
185qmake wpa_gui.pro &amp;&amp;
186make &amp;&amp;
187popd</userinput></screen>
188
189 <para>
190 This package does not come with a test suite.
191 </para>
192
193 <para>
194 Now, as the <systemitem class="username">root</systemitem> user:
195 </para>
196
197<screen role="root"><userinput>install -v -m755 wpa_{cli,passphrase,supplicant} /sbin/ &amp;&amp;
198install -v -m644 doc/docbook/wpa_supplicant.conf.5 /usr/share/man/man5/ &amp;&amp;
199install -v -m644 doc/docbook/wpa_{cli,passphrase,supplicant}.8 /usr/share/man/man8/ &amp;&amp;
200install -v -m644 dbus/fi.{epitest.hostap.WPASupplicant,w1.wpa_supplicant1}.service \
201 /usr/share/dbus-1/system-services/ &amp;&amp;
202install -v -m644 dbus/dbus-wpa_supplicant.conf \
203 /etc/dbus-1/system.d/wpa_supplicant.conf</userinput></screen>
204
205 <para>
206 If you have built the <application>WPA Supplicant</application> GUI
207 program, install it by running the following commands as the
208 <systemitem class="username">root</systemitem> user:
209 </para>
210
211<screen role="root"><userinput>install -v -m755 wpa_gui-qt4/wpa_gui /usr/bin/ &amp;&amp;
212install -v -m644 doc/docbook/wpa_gui.8 /usr/share/man/man8/ &amp;&amp;
213install -v -m644 wpa_gui-qt4/wpa_gui.desktop /usr/share/applications/ &amp;&amp;
214install -v -m644 wpa_gui-qt4/icons/wpa_gui.svg /usr/share/pixmaps/</userinput></screen>
215
216 <note>
217 <para>
218 You will need to restart the system <application>D-Bus</application> daemon
219 before you can use the <application>WPA Supplicant</application>
220 <application>D-Bus</application> interface.
221 </para>
222 </note>
223
224 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
225 href="../../xincludes/update-desktop-database.xml"/>
226
227 </sect2>
228
229 <sect2 role="configuration">
230 <title>Configuring wpa_supplicant</title>
231
232 <sect3 id="wpa_supplicant-config">
233 <title>Config File</title>
234
235 <para>
236 <filename>/etc/sysconfig/wpa_supplicant-*.conf</filename>
237 </para>
238
239 <indexterm zone="wpa_supplicant wpa_supplicant-config">
240 <primary
241 sortas="e-etc-sysconfig-wpa_supplicant-star.conf">/etc/sysconfig/wpa_supplicant-*.conf</primary>
242 </indexterm>
243
244 </sect3>
245
246 <sect3>
247 <title>Configuration Information</title>
248
249 <para>
250 To connect to an access point that uses a password, you need to put
251 the pre-shared key in <filename>
252 /etc/sysconfig/wpa_supplicant-<replaceable>wifi0</replaceable>.conf</filename>.
253 SSID is the string that the access point/router transmits to
254 identify itself. Run the following command as the
255 <systemitem class="username">root</systemitem> user:
256 </para>
257
258<screen role="root"><userinput>wpa_passphrase <replaceable>SSID</replaceable> <replaceable>SECRET_PASSWORD</replaceable> &gt; /etc/sysconfig/wpa_supplicant-<replaceable>wifi0</replaceable>.conf</userinput></screen>
259
260 <para>
261 <filename>/etc/sysconfig/wpa_supplicant-<replaceable>wifi0</replaceable>.conf
262 </filename> can hold the details of several access points. When
263 <command>wpa_supplicant</command> is started, it will scan for the
264 SSIDs it can see and choose the appropriate password to connect.
265 </para>
266
267 <para>
268 If you want to connect to an access point that isn't password
269 protected, put an entry like this in <filename>
270 /etc/sysconfig/wpa_supplicant-<replaceable>wifi0</replaceable>.conf</filename>.
271 Replace "Some-SSID" with the SSID of the access point/router.
272 </para>
273
274<screen>network={
275 ssid="<replaceable>Some-SSID</replaceable>"
276 key_mgmt=NONE
277}</screen>
278
279 <para>
280 There are many options that you could use to tweak how you connect
281 to each access point. They are described in some detail in the
282 <filename>wpa_supplicant/wpa_supplicant.conf</filename> file in the
283 source tree.
284 </para>
285
286 </sect3>
287
288 <sect3>
289 <title>Connecting to an Access Point</title>
290
291 <para id="wpa-service">
292 If you want to configure network interfaces at boot using
293 <command>wpa_supplicant</command>, you need to install the
294 <filename>/lib/services/wpa</filename> script
295 included in <xref linkend="bootscripts"/> package:
296 </para>
297
298<screen role="root"><userinput>make install-service-wpa</userinput></screen>
299
300 <indexterm zone="wpa_supplicant wpa-service">
301 <primary sortas="f-wpa">wpa</primary>
302 </indexterm>
303
304 <para>
305 If your router/access point uses DHCP to allocate IP addresses, you
306 can install <xref linkend="dhcp"/> client and use it to
307 automatically obtain network addresses. Create the
308 <filename>/etc/sysconfig/ifconfig-<replaceable>wifi0</replaceable>
309 </filename> by running the following command as the
310 <systemitem class="username">root</systemitem> user:
311 </para>
312
313<screen role="root"><userinput>cat &gt; /etc/sysconfig/ifconfig.<replaceable>wifi0</replaceable> &lt;&lt; "EOF"
314<literal>ONBOOT="yes"
315IFACE="<replaceable>wlan0</replaceable>"
316SERVICE="wpa"
317
318# Additional arguments to wpa_supplicant
319WPA_ARGS=""
320
321WPA_SERVICE="dhclient"
322DHCP_START=""
323DHCP_STOP=""
324
325# Set PRINTIP="yes" to have the script print
326# the DHCP assigned IP address
327PRINTIP="no"
328
329# Set PRINTALL="yes" to print the DHCP assigned values for
330# IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
331PRINTALL="no"</literal>
332EOF</userinput></screen>
333
334 <para>
335 If you prefer <xref linkend="dhcpcd"/> instead of
336 <xref linkend="dhcp"/> client, then create the
337 <filename>/etc/sysconfig/ifconfig-<replaceable>wifi0</replaceable>
338 </filename> by running the following command as the
339 <systemitem class="username">root</systemitem> user:
340 </para>
341
342<screen role="root"><userinput>cat &gt; /etc/sysconfig/ifconfig.<replaceable>wifi0</replaceable> &lt;&lt; "EOF"
343<literal>ONBOOT="yes"
344IFACE="<replaceable>wlan0</replaceable>"
345SERVICE="wpa"
346
347# Additional arguments to wpa_supplicant
348WPA_ARGS=""
349
350WPA_SERVICE="dhcpcd"
351DHCP_START="-b -q <replaceable>&lt;insert appropriate start options here&gt;</replaceable>"
352DHCP_STOP="-k <replaceable>&lt;insert additional stop options here&gt;</replaceable>"</literal>
353EOF</userinput></screen>
354
355 <para>
356 Alternatively, if you use static addresses on your local network,
357 then create the
358 <filename>/etc/sysconfig/ifconfig-<replaceable>wifi0</replaceable>
359 </filename> by running the following command as the
360 <systemitem class="username">root</systemitem> user:
361 </para>
362
363<screen role="root"><userinput>cat &gt; /etc/sysconfig/ifconfig.<replaceable>wifi0</replaceable> &lt;&lt; "EOF"
364<literal>ONBOOT="yes"
365IFACE="<replaceable>wlan0</replaceable>"
366SERVICE="wpa"
367
368# Additional arguments to wpa_supplicant
369WPA_ARGS=""
370
371WPA_SERVICE="ipv4-static"
372IP="192.168.1.1"
373GATEWAY="192.168.1.2"
374PREFIX="24"
375BROADCAST="192.168.1.255"</literal>
376EOF</userinput></screen>
377
378 <para>
379 You can connect to the wireless access point by
380 running the following command as the
381 <systemitem class="username">root</systemitem> user:
382 </para>
383
384<screen role="root"><userinput>ifup <replaceable>wifi0</replaceable></userinput></screen>
385
386 <para>
387 Replace <replaceable>wlan0</replaceable> with the correct
388 wireless interface and <replaceable>wifi0</replaceable>
389 with desired name for the configuration file. Please note
390 that <filename>wpa_supplicant-*.conf</filename> and
391 <filename>ifconfig.*</filename> configuration files need
392 to have identical names, ie both contain
393 <replaceable>wifi0</replaceable> in their name.
394 </para>
395
396 </sect3>
397
398 </sect2>
399
400 <sect2 role="content">
401 <title>Contents</title>
402
403 <segmentedlist>
404 <segtitle>Installed Programs</segtitle>
405 <segtitle>Installed Libraries</segtitle>
406 <segtitle>Installed Directories</segtitle>
407
408 <seglistitem>
409 <seg>
410 wpa_gui, wpa_supplicant, wpa_passphrase and wpa_cli
411 </seg>
412 <seg>
413 None
414 </seg>
415 <seg>
416 None
417 </seg>
418 </seglistitem>
419 </segmentedlist>
420
421 <variablelist>
422 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
423 <?dbfo list-presentation="list"?>
424 <?dbhtml list-presentation="table"?>
425
426 <varlistentry id="wpa_gui">
427 <term><command>wpa_gui</command></term>
428 <listitem>
429 <para>
430 is a graphical frontend program for interacting with
431 <application>wpa_supplicant</application>.
432 </para>
433 <indexterm zone="wpa_supplicant wpa_gui">
434 <primary sortas="b-wpa_gui">wpa_gui</primary>
435 </indexterm>
436 </listitem>
437 </varlistentry>
438
439 <varlistentry id="wpa_supplicant-prog">
440 <term><command>wpa_supplicant</command></term>
441 <listitem>
442 <para>
443 is a daemon that can connect to a password protected wireless
444 access point.
445 </para>
446 <indexterm zone="wpa_supplicant wpa_supplicant-prog">
447 <primary sortas="b-wpa_supplicant">wpa_supplicant</primary>
448 </indexterm>
449 </listitem>
450 </varlistentry>
451
452 <varlistentry id="wpa_passphrase">
453 <term><command>wpa_passphrase</command></term>
454 <listitem>
455 <para>
456 takes an SSID and a password and generates a simple
457 configuration that <command>wpa_supplicant</command> can
458 understand.
459 </para>
460 <indexterm zone="wpa_supplicant wpa_passphrase">
461 <primary sortas="b-wpa_passphrase">wpa_passphrase</primary>
462 </indexterm>
463 </listitem>
464 </varlistentry>
465
466 <varlistentry id="wpa_cli">
467 <term><command>wpa_cli</command></term>
468 <listitem>
469 <para>
470 is a command line interface used to control a running
471 <command>wpa_supplicant</command> daemon.
472 </para>
473 <indexterm zone="wpa_supplicant wpa_cli">
474 <primary sortas="b-wpa_cli">wpa_cli</primary>
475 </indexterm>
476 </listitem>
477 </varlistentry>
478
479 </variablelist>
480
481 </sect2>
482
483</sect1>
Note: See TracBrowser for help on using the repository browser.