Skip to content

Instantly share code, notes, and snippets.

@kjmancuso
Created December 15, 2015 20:51
Show Gist options
  • Save kjmancuso/fae07ed40d081d73700f to your computer and use it in GitHub Desktop.
Save kjmancuso/fae07ed40d081d73700f to your computer and use it in GitHub Desktop.
ubnt wizard
ubnt@ubnt:~$ show configuration
firewall {
name WAN_IN {
default-action drop
description "WAN to internal"
rule 10 {
action accept
description "Allow established/related"
state {
established enable
related enable
}
}
rule 20 {
action drop
description "Drop invalid state"
state {
invalid enable
}
}
}
name WAN_LOCAL {
default-action drop
description "WAN to router"
rule 10 {
action accept
description "Allow established/related"
state {
established enable
related enable
}
}
rule 20 {
action drop
description "Drop invalid state"
state {
invalid enable
}
}
}
}
interfaces {
ethernet eth0 {
address 192.168.1.1/24
description Local
}
ethernet eth1 {
address dhcp
description Internet
firewall {
in {
name WAN_IN
}
local {
name WAN_LOCAL
}
}
}
ethernet eth2 {
address 192.168.2.1/24
description "Local 2"
}
ethernet eth3 {
}
ethernet eth4 {
}
ethernet eth5 {
}
ethernet eth6 {
}
ethernet eth7 {
}
loopback lo {
}
}
service {
dhcp-server {
shared-network-name LAN1 {
subnet 192.168.1.0/24 {
default-router 192.168.1.1
dns-server 192.168.1.1
start 192.168.1.21 {
stop 192.168.1.240
}
}
}
shared-network-name LAN2 {
subnet 192.168.2.0/24 {
default-router 192.168.2.1
dns-server 192.168.2.1
start 192.168.2.21 {
stop 192.168.2.240
}
}
}
}
dns {
forwarding {
listen-on eth0
listen-on eth2
}
}
gui {
}
nat {
rule 5010 {
outbound-interface eth1
type masquerade
}
}
ssh {
}
}
system {
login {
user ubnt {
authentication {
encrypted-password ****************
}
level admin
}
}
ntp {
server 0.ubnt.pool.ntp.org {
}
server 1.ubnt.pool.ntp.org {
}
server 2.ubnt.pool.ntp.org {
}
server 3.ubnt.pool.ntp.org {
}
}
syslog {
global {
facility all {
level notice
}
facility protocols {
level debug
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment