wireless access point
Posted on .
$ uname -a
$ cd /usr/ports/net/isc-dhcp30-server/FreeBSD malkia 7.0-RELEASE-p7 FreeBSD 7.0-RELEASE-p7 #0: Sun Dec 21 12:33:45 UTC 2008 root@i386-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC i386
$ sudo make install clean
$ less /etc/rc.conf
$ less /boot/loader.confifconfig_ath0="inet 192.168.2.1 netmask 255.255.255.0 ssid mysid channel 10 mediaopt hostap" hostapd_enable="YES" dhcpd_enable="YES" dhcpd_ifaces="ath0" pf_enable="YES" pf_rules="/etc/pf.conf" pf_flags="" pflog_enable="YES" pflog_logfile="/var/log/pflog" pflog_flags=""
$ less /etc/hostapd.confhint.acpi.0.disabled=1 wlan_wep_load="YES" wlan_tkip_load="YES" wlan_ccmp_load="YES" wlan_xauth_load="YES" wlan_acl_load="YES"
$ less /usr/local/etc/dhcpd.confinterface=ath0 driver=bsd logger_syslog=-1 logger_syslog_level=0 logger_stdout=-1 logger_stdout_level=0 debug=3 dump_file=/tmp/hostapd.dump ctrl_interface=/var/run/hostapd ctrl_interface_group=wheel #### IEEE 802.11 related config #### ssid=mysid macaddr_acl=0 auth_algs=1 #### IEEE 802.1X related config #### ieee8021x=0 #### WPA/IEEE 802.11i config #### wpa=1 wpa_passphrase=donttellme wpa_key_mgmt=WPA-PSK wpa_pairwise=CCMP TKIP
$ less /etc/pf.confddns-update-style none; subnet 192.168.2.0 netmask 255.255.255.0 { range 192.168.2.100 192.168.2.200; default-lease-time 144000; max-lease-time 192000; option subnet-mask 255.255.255.0; option broadcast-address 192.168.2.255; option routers 192.168.2.1; option domain-name-servers 192.168.2.1; option domain-name "local.net"; option netbios-name-servers 192.168.2.1; } use-host-decl-names on; host pc1 { hardware ethernet 00:f1:3a:83:8e:1b; fixed-address 192.168.2.86; }
ext_if="ste0" wlan_if="ath0" wlannet = $wlan_if:network set loginterface $ext_if set block-policy return nat on $ext_if from $wlannet to any -> ($ext_if) antispoof for $ext_if antispoof for $wlan_if pass all