Soekris WAP HowTo
This is a simple HowTo on how I created my Soekris-based WAP. I couldn't find an appropriate package to do what I wanted, so I decided to build it myself. There were a few considerations in making this decision, even though it violates the rule of code reuse:
- I didn't want any firewall or router functionality - I just wanted a bridge with a captive portal.
- I wanted to be able to perform in-depth monitoring on it.
- This is for development purposes - I wanted a full OS with the ability to SSH in and poke around.
- I was using a Soekris net4826 which has permanent on-board CF memory (128 Mb) and only one Ethernet interface and a 802.11b card - so I couldn't use something that requires a WAN port, like m0n0wall.
Notice: I wrote this article as I was performing the work. Since then, I've gone through about a dozen disk images from tinyBSD, m0n0bsd, and many other prebuilt images I found online. About half of them I could not get to install on the CF disk or to boot via PXE. The other half, I could not get the WLAN bridge to work.
I am not looking to make a full WAP. Realistically, I just desire a bridge to my LAN so that my wireless devices can get seemless access to LAN resources. I already have my LAN setup the way I want - DHCP, DNS, and many other machines. Therefore, I want my WLAN bridged transparently to the LAN.
I chose to use FreeBSD for this project, even though it complicated my attempt at network heterogeneity. I figured that since it's an embedded system, I wouldn't need the level of administrative tool heterogeneity that O like on my servers, and since it is only being used on the LAN, upgrades weren't as much of an issue. Also, and most importantly, there are widely available build scripts to create a small FreeBSD install for a Soekris.
All of these build scripts are run on a host system running the OS that you want to install on the embedded machine - in my case, FreeBSD 6.0. To do this, first install FreeBSD 6.0 on a spare machine (or another partition or, I guess, a virtual machine, if that's your thing) with the full development package set (all sources) and most (or all) of the software that you might want on the WAP. I also installed the FreeBSD ports collection and Linux binary compatibility. Configure the system - this is what you'll use for development. Also make sure to setup your users (root and a regular user) with your favorite shells, pagers, editors, etc. SSH will also be helpful, and we'll be using SSH, SFTP, and SCP during the process.
In preparing our build, we must choose whether we want to do this all by hand, or via build scripts. I don't have much experience with FreeBSD - only as a casual user, not as an admin or programmer, so I figured that a build script is the best way to go.
Software of Interest / To Include
- WiFiDog a captive portal suite.
- source code to read the LM75 temperature sensor.
- Bridging from Ethernet to WLAN, with captive portal
- User account for Nagios
- PHP? Or use Perl/Python for administration
- CLI (and CGI?) administrative program
- Bandwidth accounting
- pkg_add (all package utils)
- grep, less, normal GNU utils
- OpenSSH server and client
- pico?? instead of emacs??
- NO man
- general wireless tools
- Bandwidth monitoring: bwm-ng, iptraf, iftop, jnettop, nload
- su, sudo
- tar, gzip