Table des matières

PirateBox sous Raspbian

Configuration du réseau

wlan0 l'interface wifi du RPI3 aura comme IP 192.168.99.254. Pour cela, il faut éditer le fichier /etc/network/interfaces:

auto wlan0
iface wlan0 inet static
    address 192.168.99.254
    netmask 255.255.255.0

Configuration de hostAP

Fichier /etc/hostapd/hostapd.conf :

interface=wlan0
driver=nl80211
ssid=raspiratebox
hw_mode=g
channel=1
macaddr_acl=0
auth_algs=1
ignore_broadcast_ssid=0
wpa=2
wpa_key_mgmt=WPA-PSK
wpa_passphrase=raspiratebox
rsn_pairwise=CCMP

SSID à raspiratebox

​Configuration de dnsmasq

Fichier /etc/dnsmasq.conf :

interface=wlan0      # Use interface wlan0
bind-interfaces      # Bind to the interface to make sure we aren't sending things elsewhere
server=8.8.8.8       # Forward DNS requests to Google DNS
domain-needed        # Don't forward short names
bogus-priv           # Never forward addresses in the non-routed address spaces.
dhcp-range=192.168.99.50,192.168.99.150,2h

Qui écoutera sur wlan0 et utilisera la plage 192.168.99.50-150 avec des baux de 2h.