--- wikisrc/tutorials/how_to_use_wpa_supplicant.mdwn 2020/09/08 21:05:59 1.9 +++ wikisrc/tutorials/how_to_use_wpa_supplicant.mdwn 2020/09/09 14:28:56 1.10 @@ -10,11 +10,11 @@ [Wired Equivalent Privacy (WEP)](https://en.wikipedia.org/wiki/Wired_Equivalent_Privacy). Most "closed" or "locked" 802.11 wireless networks use WPA/WPA2 authentication. -On NetBSD, the [wpa_supplicant(8)](//man.NetBSD.org/wpa_supplicant.8) +On NetBSD, the [[!template id=man name="wpa_supplicant" section="8"]] daemon handles WPA/WPA2. -To configure WPA/WPA2, you must create the file - [`/etc/wpa_supplicant.conf`](//man.NetBSD.org/wpa_supplicant.conf.5). +To configure WPA/WPA2, you must create the file `/etc/wpa_supplicant.conf` +([[!template id=man name="wpa_supplicant.conf" section="5"]]). You can find examples for `/etc/wpa_supplicant.conf` in `/usr/share/examples/wpa_supplicant/wpa_supplicant.conf`. The simplest case is a network, say `my favourite network`, with a @@ -29,14 +29,14 @@ For this case, fill your `/etc/wpa_suppl } Then enable wpa_supplicant on your network interface device, say - `iwn0`, by editing [`/etc/rc.conf`](//man.NetBSD.org/wpa_supplicant.conf.5) + `iwn0`, by editing `/etc/rc.conf` ([[!template id=man name="rc.conf" section="5"]]) to add wpa_supplicant=YES wpa_supplicant_flags="-i iwn0 -c /etc/wpa_supplicant.conf" If your LAN is configured with DHCP, you will likely also want - `dhcpcd=YES` in `/etc/rc.conf` to run [dhcpcd](//man.NetBSD.org/dhcpcd.8). + `dhcpcd=YES` in `/etc/rc.conf` to run [[!template id=man name="dhcpcd" section="8"]]. Then start wpa_supplicant with the shell command: # /etc/rc.d/wpa_supplicant start @@ -61,7 +61,7 @@ For a typical laptop, you will usually w In that case, when you're booting up, you don't want to have to wait until you can associate with the network and get a DHCP lease. You can pass the `-b` flag to - [dhcpcd](//man.NetBSD.org/dhcpcd.8) + [[!template id=man name="dhcpcd" section="8"]] to make it immediately go into the background, by setting `dhcpcd_flags` in `/etc/rc.conf`: @@ -110,7 +110,7 @@ Here is a configuration if you want to d Note that you don't have to use wpa_supplicant to configure WEP -- you can also simply use - [ifconfig(8)](//man.NetBSD.org/ifconfig.8): + [[!template id=man name="ifconfig" section="8"]]: ifconfig ath0 ssid MYWEAKLYENCRYPTEDWLAN nwkey 12345 @@ -129,6 +129,6 @@ This seems to be a common configuration # See also - * [wpa_supplicant(8)](//man.NetBSD.org/wpa_supplicant.8) - * [wpa_supplicant.conf(5)](//man.NetBSD.org/wpa_supplicant.conf.5) + * [[!template id=man name="wpa_supplicant" section="8"]] + * [[!template id=man name="wpa_supplicant.conf" section="5"]] * [Official wpa_supplicant site](http://hostap.epitest.fi/wpa_supplicant/)