-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #22 from danielhmetro/master
Added faster LiteBeam scanning and New MikroTik configs
- Loading branch information
Showing
6 changed files
with
270 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# NYC Mesh Mikrotik SXTsq 5ac OSPF config | ||
# OSPF mesh node | ||
:global nodenumber {{nodenumber}} | ||
|
||
/delay 15 | ||
|
||
:foreach x in=[/interface wireless find] do={ /interface wireless reset-configuration $x } | ||
|
||
/interface bridge | ||
add auto-mac=yes name=bridge fast-forward=no | ||
|
||
/interface bridge settings | ||
set use-ip-firewall=yes | ||
|
||
/interface wireless security-profiles | ||
add authentication-types=wpa-psk,wpa2-psk management-protection=allowed mode=\ | ||
dynamic-keys name=nycmeshnet supplicant-identity=nycmesh \ | ||
wpa-pre-shared-key=nycmeshnet wpa2-pre-shared-key=nycmeshnet | ||
|
||
/interface wireless | ||
set [ find default-name=wlan1 ] band=5ghz-a/n/ac channel-width=20/40/80mhz-Ceee country="united states3" disabled=no distance=dynamic antenna-gain=0 installation=any frequency=5180 mode=station-bridge security-profile=nycmeshnet wireless-protocol=802.11 wps-mode=disabled ssid="nycmesh-xxxx-omni" radio-name=("nycmesh-" . $nodenumber . "-sxt") comment="uses nycmesh-xxxx-omni via bridge" | ||
|
||
/interface wireless connect-list | ||
add allow-signal-out-of-range=3s disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-75..120 | ||
add connect=no disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-120..-75 | ||
|
||
/ip dhcp-client | ||
add dhcp-options=hostname,clientid disabled=no interface=bridge | ||
|
||
/interface bridge port | ||
add bridge=bridge interface=ether1 | ||
add bridge=bridge interface=wlan1 | ||
|
||
/ip dns | ||
set allow-remote-requests=yes servers=10.10.10.10,1.1.1.1 | ||
|
||
/ip firewall address-list | ||
add address=10.0.0.0/8 list=meshaddr | ||
add address=199.167.59.0/24 list=meshaddr | ||
add address=199.170.132.0/24 list=meshaddr | ||
|
||
/ip firewall filter | ||
add action=accept chain=input protocol=icmp | ||
add action=accept chain=input dst-port=53 protocol=udp | ||
add action=accept chain=input connection-state=established,related | ||
add action=drop chain=input src-address-list=!meshaddr | ||
|
||
/ip firewall service-port | ||
set ftp disabled=yes | ||
set tftp disabled=yes | ||
set irc disabled=yes | ||
set h323 disabled=yes | ||
set sip disabled=yes | ||
set pptp disabled=yes | ||
set udplite disabled=yes | ||
set dccp disabled=yes | ||
set sctp disabled=yes | ||
|
||
/snmp set enabled=yes | ||
|
||
/system identity set name=("nycmesh-" . $nodenumber . "-sxt") | ||
|
||
/system clock set time-zone-name=America/New_York | ||
/system ntp client | ||
set enabled=yes primary-ntp=10.10.10.123 server-dns-names=0.pool.ntp.org | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,106 @@ | ||
# NYC Mesh Mikrotik SXTsq 5ac OSPF config | ||
# OSPF mesh node | ||
:global nodenumber {{nodenumber}} | ||
|
||
:global cidr ("10." . ((96+(nodenumber>>10))+0) . "." . (((nodenumber>>2)&255)+0) . "." . (((nodenumber&3)<<6)+0) . "/26") | ||
:global ipthirdoctet ( [ :pick $nodenumber ([:len $nodenumber] - 5) ([:len $nodenumber] - 2) ] + 0 ) | ||
:global ipfourthoctet ( [ :pick $nodenumber ([:len $nodenumber] - 2) ([:len $nodenumber]) ] + 0 ) | ||
|
||
:global cidrleft [ :pick $cidr 0 ( [ :find $cidr "/" ] ) ] | ||
:global cidrright [ :pick $cidr (( [ :find $cidr "/" ] )+1) 100 ] | ||
:global netmask (255.255.255.255<<(32-$cidrright)) | ||
:global subnet ($cidrleft&$netmask) | ||
:global firstip ($subnet+1) | ||
:global lastip ($subnet + (~($subnet|$netmask)) - 1) | ||
:global dhcprange (($firstip+5) . "-" . ($lastip-5)) | ||
:global meship ("10.69." . $ipthirdoctet . "." . (100 + $ipfourthoctet)) | ||
:global wdsip ("10.68." . $ipthirdoctet . "." . (100 + $ipfourthoctet)) | ||
|
||
/delay 15 | ||
|
||
|
||
:foreach x in=[/interface wireless find] do={ /interface wireless reset-configuration $x } | ||
|
||
/interface bridge | ||
add auto-mac=yes name=local fast-forward=no | ||
add auto-mac=yes name=mesh fast-forward=no protocol-mode=none | ||
add auto-mac=yes name=wds fast-forward=no protocol-mode=none | ||
|
||
/interface bridge settings | ||
set use-ip-firewall=yes | ||
|
||
/interface wireless security-profiles | ||
add authentication-types=wpa-psk,wpa2-psk management-protection=allowed mode=\ | ||
dynamic-keys name=nycmeshnet supplicant-identity=nycmesh \ | ||
wpa-pre-shared-key=nycmeshnet wpa2-pre-shared-key=nycmeshnet | ||
|
||
/interface wireless | ||
set [ find default-name=wlan1 ] band=5ghz-a/n/ac channel-width=20/40/80mhz-Ceee country="united states3" disabled=no distance=dynamic antenna-gain=0 installation=any frequency=5180 mode=station-bridge security-profile=nycmeshnet wireless-protocol=802.11 wps-mode=disabled ssid="nycmesh-xxxx-omni" radio-name=("nycmesh-" . $nodenumber . "-sxt") comment="uses nycmesh-xxxx-omni via mesh bridge" | ||
|
||
/interface wireless connect-list | ||
add allow-signal-out-of-range=3s disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-75..120 | ||
add connect=no disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-120..-75 | ||
|
||
/ip address | ||
add address=($firstip . "/" . $cidrright) interface=local | ||
add address=($meship . "/16") interface=mesh | ||
add address=($wdsip . "/16") interface=wds | ||
|
||
/interface bridge port | ||
add bridge=local interface=ether1 | ||
add bridge=mesh interface=wlan1 | ||
add bridge=wds interface=dynamic internal-path-cost=100 path-cost=100 | ||
|
||
/interface bridge filter | ||
add action=drop chain=forward in-bridge=mesh | ||
add action=drop chain=forward in-bridge=wds | ||
|
||
/ip pool | ||
add name=local ranges=$dhcprange | ||
|
||
/ip dhcp-server | ||
add address-pool=local disabled=no interface=local name=localdhcp | ||
|
||
/ip dhcp-server network | ||
add address=$cidr dns-server=( "10.10.10.10," . $firstip) gateway=$firstip netmask=$cidrright | ||
|
||
/ip dns | ||
set allow-remote-requests=yes servers=10.10.10.10,1.1.1.1 | ||
|
||
/routing ospf instance set [ find default=yes ] router-id=$meship redistribute-connected=as-type-1 | ||
/routing filter add chain="ospf-in" set-bgp-communities=65000:110 set-distance=205 | ||
/routing ospf interface add interface=mesh network-type=ptmp | ||
/routing ospf interface add interface=wds network-type=ptmp cost=30 | ||
/routing ospf network add area=backbone network=10.69.0.0/16 | ||
/routing ospf network add area=backbone network=10.68.0.0/16 | ||
|
||
/ip firewall address-list | ||
add address=10.0.0.0/8 list=meshaddr | ||
add address=199.167.59.0/24 list=meshaddr | ||
add address=199.170.132.0/24 list=meshaddr | ||
|
||
/ip firewall filter | ||
add action=accept chain=input protocol=icmp | ||
add action=accept chain=input dst-port=53 protocol=udp | ||
add action=accept chain=input connection-state=established,related | ||
add action=drop chain=input src-address-list=!meshaddr | ||
|
||
/ip firewall service-port | ||
set ftp disabled=yes | ||
set tftp disabled=yes | ||
set irc disabled=yes | ||
set h323 disabled=yes | ||
set sip disabled=yes | ||
set pptp disabled=yes | ||
set udplite disabled=yes | ||
set dccp disabled=yes | ||
set sctp disabled=yes | ||
|
||
/snmp set enabled=yes | ||
|
||
/system identity set name=("nycmesh-" . $nodenumber . "-sxt") | ||
|
||
/system clock set time-zone-name=America/New_York | ||
/system ntp client | ||
set enabled=yes primary-ntp=10.10.10.123 server-dns-names=0.pool.ntp.org | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
# NYC Mesh Mikrotik SXTsq 5ac OSPF config | ||
# OSPF mesh node | ||
:global nodenumber {{nodenumber}} | ||
|
||
:global cidr ("10." . ((96+(nodenumber>>10))+0) . "." . (((nodenumber>>2)&255)+0) . "." . (((nodenumber&3)<<6)+0) . "/26") | ||
:global ipthirdoctet ( [ :pick $nodenumber ([:len $nodenumber] - 5) ([:len $nodenumber] - 2) ] + 0 ) | ||
:global ipfourthoctet ( [ :pick $nodenumber ([:len $nodenumber] - 2) ([:len $nodenumber]) ] + 0 ) | ||
|
||
:global cidrleft [ :pick $cidr 0 ( [ :find $cidr "/" ] ) ] | ||
:global cidrright [ :pick $cidr (( [ :find $cidr "/" ] )+1) 100 ] | ||
:global netmask (255.255.255.255<<(32-$cidrright)) | ||
:global subnet ($cidrleft&$netmask) | ||
:global firstip ($subnet+1) | ||
:global lastip ($subnet + (~($subnet|$netmask)) - 1) | ||
:global meship ("10.69." . $ipthirdoctet . "." . (100 + $ipfourthoctet)) | ||
:global wdsip ("10.68." . $ipthirdoctet . "." . (100 + $ipfourthoctet)) | ||
|
||
/delay 15 | ||
|
||
|
||
:foreach x in=[/interface wireless find] do={ /interface wireless reset-configuration $x } | ||
|
||
/interface bridge | ||
add auto-mac=yes name=local fast-forward=no | ||
add auto-mac=yes name=mesh fast-forward=no protocol-mode=none | ||
add auto-mac=yes name=wds fast-forward=no protocol-mode=none | ||
|
||
/interface bridge settings | ||
set use-ip-firewall=yes | ||
|
||
/interface wireless security-profiles | ||
add authentication-types=wpa-psk,wpa2-psk management-protection=allowed mode=\ | ||
dynamic-keys name=nycmeshnet supplicant-identity=nycmesh \ | ||
wpa-pre-shared-key=nycmeshnet wpa2-pre-shared-key=nycmeshnet | ||
|
||
/interface wireless | ||
set [ find default-name=wlan1 ] band=5ghz-a/n/ac channel-width=20/40/80mhz-Ceee country="united states3" disabled=no distance=dynamic antenna-gain=0 installation=any frequency=5180 mode=station-bridge security-profile=nycmeshnet wireless-protocol=802.11 wps-mode=disabled ssid="nycmesh-xxxx-omni" radio-name=("nycmesh-" . $nodenumber . "-sxt") comment="uses nycmesh-xxxx-omni via mesh bridge" | ||
|
||
/interface wireless connect-list | ||
add allow-signal-out-of-range=3s disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-75..120 | ||
add connect=no disabled=yes interface=wlan1 security-profile=nycmeshnet signal-range=-120..-75 | ||
|
||
/ip address | ||
add address=($meship . "/16") interface=mesh | ||
add address=($wdsip . "/16") interface=wds | ||
|
||
/interface bridge port | ||
add bridge=mesh interface=ether1 | ||
add bridge=mesh interface=wlan1 | ||
add bridge=wds interface=dynamic internal-path-cost=100 path-cost=100 | ||
|
||
/interface bridge filter | ||
add action=drop chain=forward in-bridge=mesh | ||
add action=drop chain=forward in-bridge=wds | ||
|
||
/ip dns | ||
set allow-remote-requests=yes servers=10.10.10.10,1.1.1.1 | ||
|
||
/routing ospf instance set [ find default=yes ] router-id=$meship redistribute-connected=as-type-1 | ||
/routing filter add chain="ospf-in" set-bgp-communities=65000:110 set-distance=205 | ||
/routing ospf interface add interface=mesh network-type=ptmp | ||
/routing ospf interface add interface=wds network-type=ptmp cost=30 | ||
/routing ospf network add area=backbone network=10.69.0.0/16 | ||
/routing ospf network add area=backbone network=10.68.0.0/16 | ||
|
||
/ip firewall address-list | ||
add address=10.0.0.0/8 list=meshaddr | ||
add address=199.167.59.0/24 list=meshaddr | ||
add address=199.170.132.0/24 list=meshaddr | ||
|
||
/ip firewall filter | ||
add action=accept chain=input protocol=icmp | ||
add action=accept chain=input dst-port=53 protocol=udp | ||
add action=accept chain=input connection-state=established,related | ||
add action=drop chain=input src-address-list=!meshaddr | ||
|
||
/ip firewall service-port | ||
set ftp disabled=yes | ||
set tftp disabled=yes | ||
set irc disabled=yes | ||
set h323 disabled=yes | ||
set sip disabled=yes | ||
set pptp disabled=yes | ||
set udplite disabled=yes | ||
set dccp disabled=yes | ||
set sctp disabled=yes | ||
|
||
/snmp set enabled=yes | ||
|
||
/system identity set name=("nycmesh-" . $nodenumber . "-sxt") | ||
|
||
/system clock set time-zone-name=America/New_York | ||
/system ntp client | ||
set enabled=yes primary-ntp=10.10.10.123 server-dns-names=0.pool.ntp.org | ||
|