[IMP] point_of_sale: move POSBox AP to a less used subnet
When the POSBox boots without a network cable attached it will automatically launch a wireless AP that people can connect to. This allows them to configure what wireless network the POSBox should connect to. This wireless AP was configured to use the 10.10.0.0/24 subnet. The AP itself was on 10.10.0.1. Although this is fine if used as intended it is a quick way to take down an existing network if you where to plug in an ethernet cable after the wireless AP has started. 10.10.0.1 is commonly used by routers all over the world and plugging in a booted POSBox into their networks will cause serious issues because the POSBox will share the same IP as the router. This moves the POSBox AP to the 10.11.12.0/24 subnet, with the AP on 10.11.12.1. This also makes the DHCP server listen only on wlan0 because otherwise you can end up with two DHCP servers on the same network which would still break stuff.
This commit is contained in:
parent
fd43faac16
commit
f5a527fb0a
|
@ -28,7 +28,7 @@ if [ -z "${WIRED_IP}" ] ; then
|
|||
|
||||
service hostapd restart
|
||||
|
||||
ip addr add 10.10.0.1/24 dev wlan0
|
||||
ip addr add 10.11.12.1/24 dev wlan0
|
||||
|
||||
service isc-dhcp-server restart
|
||||
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
# Defaults for isc-dhcp-server initscript
|
||||
# sourced by /etc/init.d/isc-dhcp-server
|
||||
# installed at /etc/default/isc-dhcp-server by the maintainer scripts
|
||||
|
||||
#
|
||||
# This is a POSIX shell fragment
|
||||
#
|
||||
|
||||
# Path to dhcpd's config file (default: /etc/dhcp/dhcpd.conf).
|
||||
#DHCPD_CONF=/etc/dhcp/dhcpd.conf
|
||||
|
||||
# Path to dhcpd's PID file (default: /var/run/dhcpd.pid).
|
||||
#DHCPD_PID=/var/run/dhcpd.pid
|
||||
|
||||
# Additional options to start dhcpd with.
|
||||
# Don't use options -cf or -pf here; use DHCPD_CONF/ DHCPD_PID instead
|
||||
#OPTIONS=""
|
||||
|
||||
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
|
||||
# Separate multiple interfaces with spaces, e.g. "eth0 eth1".
|
||||
INTERFACES="wlan0"
|
|
@ -37,10 +37,10 @@ ddns-update-style none;
|
|||
# option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
|
||||
#}
|
||||
|
||||
subnet 10.10.0.0 netmask 255.255.255.0 {
|
||||
range 10.10.0.2 10.10.0.254;
|
||||
subnet 10.11.12.0 netmask 255.255.255.0 {
|
||||
range 10.11.12.2 10.11.12.254;
|
||||
option domain-name-servers 8.8.8.8, 208.67.222.222;
|
||||
option routers 10.10.0.1;
|
||||
option routers 10.11.12.1;
|
||||
}
|
||||
|
||||
# This declaration allows BOOTP clients to get dynamic addresses,
|
||||
|
|
Loading…
Reference in New Issue