source: networking/netprogs/wpa_supplicant.xml@ 26c1bdd

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 26c1bdd was 26c1bdd, checked in by Ragnar Thomsen <rthomsen@…>, 12 years ago

wpa_supplicant 1.0

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@10214 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 11.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-md5sum "8650f6aa23646ef634402552d0669640">
10 <!ENTITY wpa_supplicant-size "1.9 MB">
11 <!ENTITY wpa_supplicant-buildsize "16 MB">
12 <!ENTITY wpa_supplicant-time "0.1 SBU">
13]>
14
15<sect1 id="wpa_supplicant" xreflabel="wpa_supplicant-&wpa_supplicant-version;">
16 <?dbhtml filename="wpa_supplicant.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>wpa_supplicant-&wpa_supplicant-version;</title>
24
25 <indexterm zone="wpa_supplicant">
26 <primary sortas="a-wpa_supplicant">wpa_supplicant</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to wpa_supplicant</title>
31
32 <para><application>wpa_supplicant</application> is a Wi-Fi Protected Access
33 (WPA) client and IEEE 802.1X supplicant. It implements WPA key negotiation
34 with a WPA Authenticator and Extensible Authentication Protocol (EAP)
35 authentication with an Authentication Server. In addition, it controls the
36 roaming and IEEE 802.11 authentication/association of the wireless LAN
37 driver. This is useful for connecting to a password protected wireless
38 access point.</para>
39
40 &lfs71_checked;
41
42 <bridgehead renderas="sect3">Package Information</bridgehead>
43 <itemizedlist spacing="compact">
44 <listitem>
45 <para>Download (HTTP):
46 <ulink url="&wpa_supplicant-download-http;"/></para>
47 </listitem>
48 <listitem>
49 <para>Download MD5 sum: &wpa_supplicant-md5sum;</para>
50 </listitem>
51 <listitem>
52 <para>Download size: &wpa_supplicant-size;</para>
53 </listitem>
54 <listitem>
55 <para>Estimated disk space required: &wpa_supplicant-buildsize;</para>
56 </listitem>
57 <listitem>
58 <para>Estimated build time: &wpa_supplicant-time;</para>
59 </listitem>
60 </itemizedlist>
61<!--
62 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
63 <itemizedlist spacing="compact">
64 <listitem>
65 <para>Required patch: <ulink
66 url="&patch-root;/wpa_supplicant-&wpa_supplicant-version;-libnl-3-fixes-1.patch"/></para>
67 </listitem>
68 </itemizedlist>
69-->
70 <bridgehead renderas="sect3">wpa_supplicant Dependencies</bridgehead>
71
72 <bridgehead renderas="sect4">Optional</bridgehead>
73 <para role="optional">
74 <xref linkend="openssl"/>,
75 <xref linkend="libnl"/> (required to use the nl80211 kernel interface),
76 <!-- using CONFIG_TLS=gnutls fails as
77 src/crypto/tls_gnutls.c uses functions like gnutls_session_get_client_random
78 and gnutls_session_get_server_random which have been removed from current
79 <xref linkend="gnutls"/> -->
80 <xref linkend="dbus"/>,
81 <ulink url="http://libtom.org/">libtommath</ulink>,
82 <xref linkend="libpcap"/> and
83 <ulink url="http://libdnet.sourceforge.net/">libdnet</ulink>.
84 </para>
85
86 <para condition="html" role="usernotes">User Notes:
87 <ulink url="&blfs-wiki;/wpa_supplicant"/></para>
88 </sect2>
89
90 <sect2 role="kernel" id="wpa_supplicant-kernel">
91 <title>Kernel Configuration</title>
92
93 <para>Enable the following options in the kernel configuration
94 and recompile the kernel if necessary:</para>
95
96<screen><literal>[*] Networking support --->
97 [*] Wireless --->
98 [*] cfg80211 - wireless configuration API
99 [*] cfg80211 wireless extensions compatibility
100 [*] Generic IEEE 802.11 Networking Stack (mac80211)
101
102Device Drivers --->
103 [*] Network device support --->
104 [*] Wireless LAN --->
105</literal></screen>
106
107 <para>Select the options that support your hardware:
108 <command>lspci</command> from <xref linkend="pciutils"/> can be used to
109 view your hardware configuration.</para>
110
111 <indexterm zone="wpa_supplicant wpa_supplicant-kernel">
112 <primary sortas="d-wpa_supplicant">wpa_supplicant</primary>
113 </indexterm>
114 </sect2>
115
116 <sect2 role="installation">
117 <title>Installation of wpa_supplicant</title>
118
119 <para>Install <application>wpa_supplicant</application> by running the
120 following commands:</para>
121
122<screen><userinput>cd wpa_supplicant &amp;&amp;
123cat &gt; .config &lt;&lt; "HERE_DOC"
124CONFIG_DRIVER_WEXT=y
125CONFIG_EAP_GPSK=y
126CONFIG_EAP_GPSK_SHA256=y
127CONFIG_EAP_GTC=y
128CONFIG_EAP_IKEV2=y
129CONFIG_EAP_LEAP=y
130CONFIG_EAP_MD5=y
131CONFIG_EAP_MSCHAPV2=y
132CONFIG_EAP_OTP=y
133CONFIG_EAP_PAX=y
134CONFIG_EAP_PEAP=y
135CONFIG_EAP_PSK=y
136CONFIG_EAP_TLS=y
137CONFIG_EAP_TTLS=y
138CONFIG_PEERKEY=y
139CONFIG_PKCS12=y
140CONFIG_CTRL_IFACE=y
141CONFIG_READLINE=y
142CONFIG_IPV6=y
143CONFIG_LIBNL32=y
144CFLAGS += -I/usr/include/libnl3
145
146# If you have not installed openssl, uncomment the next line:
147# CONFIG_TLS=internal
148
149# If you want to use the internal TLS and have
150# not installed libtommath, uncomment the next line:
151# CONFIG_INTERNAL_LIBTOMMATH=y
152
153# Uncomment the next line if you want to build the nl80211 driver:
154# CONFIG_DRIVER_NL80211=y
155
156# Uncomment the next line if you have a ralink chipset:
157# CONFIG_DRIVER_RALINK=y
158
159# Uncomment the next line if you have an Agere Hermes chipset:
160# CONFIG_DRIVER_HERMES=y
161
162# Uncomment the next line if you have an Atmel chipset:
163# CONFIG_DRIVER_ATMEL=y
164
165# Uncomment the next line if you've installed dbus:
166# CONFIG_CTRL_IFACE_DBUS_NEW=y
167
168# Uncomment the next line if you've installed libpcap and libdnet:
169# CONFIG_L2_PACKET=pcap
170HERE_DOC
171make</userinput></screen>
172
173 <para>This package does not come with a test suite.</para>
174
175 <para>Now, as the <systemitem class="username">root</systemitem>
176 user:</para>
177
178<screen role="root"><userinput>cp wpa_{cli,passphrase,supplicant} /sbin &amp;&amp;
179cp doc/docbook/wpa_supplicant.conf.5 /usr/share/man/man5 &amp;&amp;
180cp doc/docbook/wpa_{cli,passphrase,supplicant}.8 /usr/share/man/man8</userinput></screen>
181 </sect2>
182
183 <sect2 role="commands">
184 <title>Command Explanations</title>
185
186 <para><command>cat > .config ...</command>: This creates a default
187 configuration that should work in most situations. It uses the WEXT kernel
188 driver which most wireless cards seem to use. For an explanation of these
189 options (and to see what other options you could choose) read the
190 <filename>wpa_supplicant/defconfig</filename> file in the source.</para>
191 </sect2>
192
193 <sect2 role="configuration">
194 <title>Configuring wpa_supplicant</title>
195
196 <sect3 id="wpa_supplicant-config">
197 <title>Config File</title>
198 <para><filename>/etc/wpa_supplicant.conf</filename></para>
199
200 <indexterm zone="wpa_supplicant wpa_supplicant-config">
201 <primary
202 sortas="e-etc-wpa_supplicant.conf">/etc/wpa_supplicant.conf</primary>
203 </indexterm>
204 </sect3>
205
206 <sect3>
207 <title>Configuration Information</title>
208
209 <para>To connect to an access point that uses a password you need to put
210 the pre-shared key in <filename>/etc/wpa_supplicant.conf</filename>. Use
211 <command>wpa_passphrase</command> to generate this. SSID is the string
212 that the access point/router transmits to identify itself. As the
213 <systemitem class="username">root</systemitem> user:</para>
214
215<screen role="root"><userinput>wpa_passphrase <replaceable>SSID</replaceable> <replaceable>SECRET_PASSWORD</replaceable> &gt; /etc/wpa_supplicant.conf</userinput></screen>
216
217 <para>/etc/wpa_supplicant.conf can hold the details of several access
218 points. When you run wpa_supplicant it will scan for the SSIDs it can see
219 and choose the appropriate password to connect.</para>
220
221 <para>If you want to connect to an access point that isn't password
222 protected, put an entry like this in
223 <filename>/etc/wpa_supplicant.conf</filename>. Replace
224 "Some-SSID" with the SSID of the access point/router.</para>
225
226<screen>network={
227 ssid="<replaceable>Some-SSID</replaceable>"
228 key_mgmt=NONE
229}</screen>
230
231 <para>There are many options that you could use to tweak how you connect
232 to each access point. They are described in some detail in the
233 <filename>wpa_supplicant/wpa_supplicant.conf</filename> file in the
234 source.</para>
235
236 <para>To use <command>wpa_cli</command> to control the running
237 wpa_supplicant daemon, add a control interface to
238 <filename>/etc/wpa_supplicant.conf</filename>. As the
239 <systemitem class="username">root</systemitem> user:</para>
240
241<screen role="root"><userinput>echo ctrl_interface=/run/wpa_supplicant &gt;&gt; /etc/wpa_supplicant.conf</userinput></screen>
242 </sect3>
243
244 <sect3>
245 <title>Connecting to an Access Point</title>
246
247 <para>If your router/access point uses DHCP to allocate IP addresses you
248 can install <xref linkend="dhcpcd"/> and use it to connect. As the
249 <systemitem class="username">root</systemitem> user:</para>
250
251<screen role="root"><userinput>wpa_supplicant -B -c/etc/wpa_supplicant.conf -iwlan0 -Dwext
252sleep 2 # let it settle
253dhcpcd</userinput></screen>
254
255 <para>Alternatively, you can use static addresses on your local network.
256 This has the advantage that you can put the hostnames in
257 <filename>/etc/hosts</filename>. Replace 192.168.1.6 with the static
258 address you've chosen. Replace 192.168.1.1 with the local IP address of
259 the access point/router. As the
260 <systemitem class="username">root</systemitem> user:</para>
261
262<screen role="root"><userinput>ip addr add 192.168.1.6 dev wlan0
263ip link set wlan0 up
264wpa_supplicant -B -c/etc/wpa_supplicant.conf -iwlan0 -Dwext
265ip route add 192.168.1.1 dev wlan0
266ip route add default via 192.168.1.1 dev wlan0</userinput></screen>
267
268 </sect3>
269 </sect2>
270
271 <sect2 role="content">
272 <title>Contents</title>
273
274 <segmentedlist>
275 <segtitle>Installed Programs</segtitle>
276 <segtitle>Installed Libraries</segtitle>
277 <segtitle>Installed Directories</segtitle>
278
279 <seglistitem>
280 <seg>wpa_supplicant, wpa_passphrase and wpa_cli</seg>
281 <seg>none</seg>
282 <seg>none</seg>
283 </seglistitem>
284 </segmentedlist>
285
286 <variablelist>
287 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
288 <?dbfo list-presentation="list"?>
289 <?dbhtml list-presentation="table"?>
290
291 <varlistentry id="wpa_supplicant-prog">
292 <term><command>wpa_supplicant</command></term>
293 <listitem>
294 <para>is a daemon that can connect to a password protected wireless
295 access point.</para>
296 <indexterm zone="wpa_supplicant wpa_supplicant-prog">
297 <primary sortas="b-wpa_supplicant">wpa_supplicant</primary>
298 </indexterm>
299 </listitem>
300 </varlistentry>
301
302 <varlistentry id="wpa_passphrase">
303 <term><command>wpa_passphrase</command></term>
304 <listitem>
305 <para>takes an SSID and a password and generates a simple
306 configuration that <command>wpa_supplicant</command> can
307 understand.</para>
308 <indexterm zone="wpa_supplicant wpa_passphrase">
309 <primary sortas="b-wpa_passphrase">wpa_passphrase</primary>
310 </indexterm>
311 </listitem>
312 </varlistentry>
313
314 <varlistentry id="wpa_cli">
315 <term><command>wpa_cli</command></term>
316 <listitem>
317 <para>is a command line interface to control a running wpa_supplicant
318 daemon.</para>
319 <indexterm zone="wpa_supplicant wpa_cli">
320 <primary sortas="b-wpa_cli">wpa_cli</primary>
321 </indexterm>
322 </listitem>
323 </varlistentry>
324 </variablelist>
325 </sect2>
326</sect1>
Note: See TracBrowser for help on using the repository browser.