# Register multiples wifi networks on OpenBSD * Author: Solène * Date: 05 August 2021 * Tags: openbsd NIL=> https://bsd.network/@solenepercent/106704700824214413 Comment on Mastodon # Introduction This is a short text to introduce you about an OpenBSD feature arrived in 2018 and that may not be known by everyone. Wifi interfaces can have a list of network and their associated passphrase to automatically connect when network is known. => https://undeadly.org/cgi?action=article;sid=20180512130811 phessler@ hackathon report including wifi join feature # How to configure The relevant configuration information is in the ifconfig man page, look for "WIRELESS DEVICES" and check the "join" keyword. => https://man.openbsd.org/ifconfig.8#join OpenBSD ifconfig man page anchored on the join keyword => https://www.openbsd.org/faq/faq6.html#Wireless OpenBSD FAQ about wireless LAN Basically, in your /etc/hostname.if file (if being replaced by the interface name like iwm0, athn0 etc...), list every access point you know and their according password. ```configuration sample join android_hotspot wpakey t00345Y4Y0U join my-home wpakey goodbyekitty join friends1 wpakey ilikeb33r5 join favorite-bar-hotspot ``` This will make the wifi interface to try to connect to the first declared network in the file if multiples access points are available. You can temporarily remove a hotspot from the list using "ifconfig iwm0 -join android_hotspot" if you don't want to connect to it.