| 1 | Loosely inspired by [http://martenvijn.nl/trac/wiki/ap Marten how-to build a FreeBSD AP] I will show the use of Multiple SSID aka as VAP (VirtualAccessPoints) to build [http://en.wikipedia.org/wiki/FON La Fonera] like device. Provide restricted access which expose your full personal network and a limited access for people visiting and passing by. |
| 2 | |
| 3 | = Procedure = |
| 4 | Assuming your have already setup your FreeBSD installation, else use the Handbook or my guide for [wiki:FreeBSDOnEmbeddedDevice] is you like. |
| 5 | |
| 6 | To be put into /etc/rc.conf |
| 7 | {{{ |
| 8 | # Eudoroam internal wired and wireless |
| 9 | ifconfig_sis0="up" |
| 10 | create_args_wlan0="wlanmode hostap mode 11g ssid eduroam.test up" |
| 11 | ifconfig_bridge0="addm wlan0 addm sis0 up" |
| 12 | ipv4_addrs_bridge0="192.168.42.1/24 192.168.1.2/24" |
| 13 | |
| 14 | # Wireless Leiden Hub |
| 15 | ifconfig_sis2="up" |
| 16 | create_args_wlan1="wlanmode hostap bssid mode 11g ssid |
| 17 | ap-raam.snuit.wleiden.net up" |
| 18 | ifconfig_bridge1="addm wlan1 addm sis2 DHCP" |
| 19 | |
| 20 | # Authentication enabled on my personal access point (wlan0) |
| 21 | hostapd_enable="YES" |
| 22 | }}} |
| 23 | |
| 24 | To be put in /etc/hostapd.conf |
| 25 | {{{ |
| 26 | interface=wlan0 |
| 27 | driver=bsd |
| 28 | |
| 29 | logger_syslog=-1 |
| 30 | logger_syslog_level=0 |
| 31 | logger_stdout=-1 |
| 32 | logger_stdout_level=2 |
| 33 | dump_file=/tmp/hostapd.dump |
| 34 | ctrl_interface=/var/run/hostapd |
| 35 | ctrl_interface_group=0 |
| 36 | |
| 37 | macaddr_acl=0 |
| 38 | auth_algs=1 |
| 39 | |
| 40 | wpa=1 |
| 41 | wpa_passphrase=FooBarPass |
| 42 | wpa_key_mgmt=WPA-PSK |
| 43 | wpa_pairwise=CCMP TKIP |
| 44 | EOF |
| 45 | }}} |
| 46 | |
| 47 | = Misc = |
| 48 | Wireless card used: |
| 49 | # pciconf -vl | grep -A 4 ath0 |
| 50 | {{{ |
| 51 | ath0@pci0:0:14:0: class=0x020000 card=0x1600185f chip=0x001b168c |
| 52 | rev=0x01 hdr=0x00 |
| 53 | vendor = 'Atheros Communications Inc.' |
| 54 | device = 'AR5006 family 802.11abg Wireless NIC' |
| 55 | class = network |
| 56 | }}} |