An open API service indexing awesome lists of open source software.

https://github.com/jech/sroamd


https://github.com/jech/sroamd

Last synced: 5 months ago
JSON representation

Awesome Lists containing this project

README

          

Sroamd -- the Simple Roaming Daemon
===================================

Sroamd makes it possible to seamlessly roam between IP links (e.g. WiFi
access points) with no changes to clients. There is no central controller,
and no tunnelling is involved.

The daemon implements a custom DHCPv4 server, an IPv4 RA server and
a custom peer-to-peer flooding algorithm. It depends on hostapd for
link-layer configuration, and a routing protocol able to efficiently deal
with host routes (for example Babel).

Usage
-----

Your routers need to all belong to a single routing domain (typically
a single Babel domain with no internal firewalling), but the nodes running
sroamd do not need to be neighbours. In the following, we assume that
your nodes run Babel over eth0 and use wlan0 as the roaming interface. We
also assume that you use 2001:db8:4444::/48 and 192.168.44/24 as the
prefixes used for roaming hosts.

### Set up the link layer

Run hostapd on the wlan0 interface. Your `/etc/hostapd/hostapd.conf`
should say something like

interface=wlan0
channel=11
hw_mode=g
wmm_enabled=1
ieee80211n=1
ssid=sroam
wpa=2
wpa_passphrase=topsecret
wpa_pairwise=CCMP

### Set up the IP layer

All of your roaming interfaces must have the same IPv4 address, and they
should have the same IPv6 link-local address.

ip addr flush dev wlan0
ip addr add 192.168.44.1/24 dev wlan0
ip -6 addr flush dev wlan0
ip -6 addr add fe80::44/64 dev wlan0

### Run Babel, redistributing routes to roaming clients

Your routing daemon must be configured to redistribute routes with
protocol 44. If using babeld, you could say

babeld -C 'redistribute proto 44 allow' eth0

If you're running BIRD, you're on your own.

### Run sroamd

Choose an IPv4 prefix (at least /24) and an IPv6 prefix (at least /56) for
your roaming clients.

v4prefix=192.168.44.0/24
v6prefix=2001:0db8:1234::/48

Choose a set of nameservers to advertise to your clients:

ns1=192.168.43.43
ns2=2001:0db8:4343::43

Pick one or two stable sroamd instances, call them A and B, to act as
flooding servers:

On A:

sroamd -P $v4prefix -P $v6prefix -N $ns1 -N $ns2 -f 4444 wlan0

On B:

sroamd -P $v4prefix -P $v6prefix -N $ns1 -N $ns2 -f 4444 -F A:4444 wlan0

On all other sroamd instances:

sroamd -P $v4prefix -P $v6prefix -N $nameserver -f 4444 -F A:4444 -F B:4444 wlan0

Notes:

* you must use the same prefixes (-P) on all instances, but you may use
different nameservers;
* the servers need not act as DHCPv4 and RA servers, in which case they
need not run babeld or hostapd and you should omit the interface name.

### Find the bugs

This is experimental software. Things will break.