- Messages
- 22
- Reaction score
- 0
- Points
- 26
# sep/07/2017 12:03:33 by RouterOS 6.38.3
# software id = YEY6-IB61
#
/interface bridge
add name=bridge1
/interface ethernet
set [ find default-name=ether1 ] comment=WAN
set [ find default-name=ether2 ] comment="LAN et2 to et5"
set [ find default-name=ether3 ] master-port=ether2
set [ find default-name=ether4 ] master-port=ether2
set [ find default-name=ether5 ] master-port=ether2
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
add authentication-types=wpa-psk,wpa2-psk eap-methods="" \
management-protection=allowed mode=dynamic-keys name=WPA2 \
supplicant-identity="" wpa-pre-shared-key=superboy21 wpa2-pre-shared-key=\
superboy21
/interface wireless
set [ find default-name=wlan1 ] band=2ghz-b/g/n disabled=no frequency=auto \
mode=ap-bridge security-profile=WPA2
/ip firewall layer7-protocol
add name=streaming regexp="^. + (youtube.com | googlevideo.com | cdn.dailymoti\
on.com | fbcdn.net | metacafe.com | mccont.com). * \$"
add name=Youtube regexp=\
"^.+(youtube.com|akamaihd.net|googlevideo|fbcdn.net).*\$"
add name=Files regexp="^.*get.+\\\\.(exe|rar|zip|7z|cab|asf|mov|wmv|mpg|mpeg|m\
kv|avi|flv|pdf|wav|rm|mp3|mp4|ram|rmvb|dat|daa|iso|nrg|bin|vcd|mp2|3gp|mpe\
|qt|raw|wma|ogg|doc|deb|tar|bzip|gzip|gzip2|0[0-9][0-9]).*\\\$"
/ip pool
add name=dhcp_pool0 ranges=192.168.5.2-192.168.5.254
/ip dhcp-server
add address-pool=dhcp_pool0 disabled=no interface=bridge1 name=dhcp1
/queue tree
add max-limit=8M name="Total Download LAN" parent=bridge1 queue=default
add max-limit=8M name="Total Upload LAN-WI-FI" parent=ether1 queue=default
add limit-at=2M max-limit=8M name=Browsing-LAN-Download packet-mark=\
Browsing-LAN-Down-Packet parent="Total Download LAN" priority=2 queue=\
pcq-download-default
add limit-at=2M max-limit=8M name=Browsing-LAN-Up packet-mark=\
Browsing-LAN-UP-Packet parent="Total Upload LAN-WI-FI" priority=2 queue=\
pcq-upload-default
add limit-at=2M max-limit=8M name=Streaming-Wifi-Down packet-mark=\
Streaming-Down-Wifi-Packet parent="Total Download LAN" queue=\
pcq-download-default
add limit-at=3M max-limit=8M name=Streaming-Wifi-Upload packet-mark=\
Streaming-Up-Wifi-Packet parent="Total Upload LAN-WI-FI" queue=\
pcq-upload-default
add limit-at=1M max-limit=8M name=File-Limit-Down packet-mark=\
Limit-Down-Packet parent="Total Download LAN" queue=pcq-download-default
add limit-at=1M max-limit=4M name=File-Limit-Upload packet-mark=\
Limit-Up-Packet parent="Total Upload LAN-WI-FI" queue=pcq-upload-default
add limit-at=3M max-limit=8M name=Game-Online-Down packet-mark=GAME-Packets \
parent="Total Download LAN" priority=1 queue=pcq-download-default
add limit-at=3M max-limit=8M name=Game-Online-Up packet-mark=GAME-Packets \
parent="Total Upload LAN-WI-FI" priority=1 queue=pcq-download-default
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=wlan1
/ip address
add address=192.168.5.1/24 comment="LAN IP Subnet" interface=bridge1 network=\
192.168.5.0
/ip dhcp-client
add default-route-distance=0 dhcp-options=hostname,clientid disabled=no \
interface=ether1
/ip dhcp-server network
add address=192.168.5.0/24 gateway=192.168.5.1
/ip dns
set allow-remote-requests=yes servers=8.8.8.8
/ip firewall address-list
add address=192.168.5.0/24 list=OurLocalLAN
/ip firewall filter
add action=accept chain=input comment=\
"Allow access to the router from LAN using address list" \
src-address-list=OurLocalLAN
add action=drop chain=input comment="Drop all other traffic to the router"
add action=accept chain=forward comment="Allow connection from the LAN" \
connection-state=new in-interface=bridge1
add action=accept chain=forward comment="Allow established connections" \
connection-state=established
add action=accept chain=forward comment="Allow related connections" \
connection-state=related
add action=drop chain=forward comment=\
"Drop all other traffic through the router"
add action=drop chain=forward comment="Drop invalid connections" \
connection-state=invalid
add action=accept chain=input comment=\
"Allow established connections to the router" connection-state=\
established
add action=accept chain=input comment=\
"Allow related connection to the router" connection-state=related
/ip firewall mangle
add action=mark-connection chain=prerouting comment="Mangle BROWSING Lan" \
dst-port=80,443 in-interface=bridge1 new-connection-mark=\
Browsing-LAN-conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Mangle Down Lan Packet" \
connection-mark=Browsing-LAN-conn in-interface=ether1 new-packet-mark=\
Browsing-LAN-Down-Packet passthrough=no
add action=mark-packet chain=forward comment="Mangle Up Lan Packet" \
connection-mark=Browsing-LAN-conn in-interface=bridge1 new-packet-mark=\
Browsing-LAN-UP-Packet passthrough=no
add action=mark-connection chain=prerouting comment=Streaming in-interface=\
bridge1 layer7-protocol=Youtube new-connection-mark=\
All-Streaming-Wifi-Conn passthrough=yes src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Streaming Down Wifi Packet" \
connection-mark=All-Streaming-Wifi-Conn in-interface=ether1 \
new-packet-mark=Streaming-Down-Wifi-Packet passthrough=no
add action=mark-packet chain=forward comment="Streaming Up Wifi Packet" \
connection-mark=All-Streaming-Wifi-Conn in-interface=bridge1 \
new-packet-mark=Streaming-Up-Wifi-Packet passthrough=no
add action=mark-connection chain=prerouting comment="File LIMIT Conn" \
dst-port=80,21 in-interface=bridge1 layer7-protocol=*3 \
new-connection-mark=File-Limit-Conn passthrough=yes protocol=tcp \
src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Limit Down Packet" \
connection-mark=File-Limit-Conn in-interface=ether1 new-packet-mark=\
Limit-Down-Packet passthrough=no
add action=mark-packet chain=forward comment="Limit Up Packet" \
connection-mark=File-Limit-Conn in-interface=bridge1 new-packet-mark=\
Limit-Up-Packet passthrough=no
add action=mark-packet chain=forward comment="Mangle GAME" connection-mark=\
All-GAME-Conn new-packet-mark=GAME-Packets passthrough=yes
add action=mark-connection chain=prerouting comment="Dota 2 Steam" dst-port=\
27015-27030,27036-27037 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=PointBlank dst-port=\
39100-49100 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=CrossFire dst-port=\
9110,10008,13006,16666 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="LOL PH" dst-port=\
5222-5223,8393 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 2" \
dst-port=27930-27935,54689,55031,52846 in-interface=bridge1 \
new-connection-mark=All-GAME-Conn passthrough=yes protocol=tcp \
src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 1" \
dst-port=20000-21000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Dota 2 Steam2" dst-port=\
27000-27037,4379-4380,3478 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=PointBlank2 dst-port=\
40000-40010 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="CrossFire 2" dst-port=\
12000-12080,13000-13080,55000-65000 in-interface=bridge1 \
new-connection-mark=All-GAME-Conn passthrough=no protocol=udp \
src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="LOL PH2" dst-port=\
5000-5500 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 22" \
dst-port=54468,30000-31000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 12" \
dst-port=20000-21000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
/ip firewall nat
add action=masquerade chain=srcnat out-interface=ether1
/system clock
set time-zone-name=Asia/Manila
/system identity
set name=MikroTikNiVice
/system ntp client
set enabled=yes primary-ntp=96.44.154.34 secondary-ntp=63.240.161.99
/system routerboard settings
set init-delay=0s
# software id = YEY6-IB61
#
/interface bridge
add name=bridge1
/interface ethernet
set [ find default-name=ether1 ] comment=WAN
set [ find default-name=ether2 ] comment="LAN et2 to et5"
set [ find default-name=ether3 ] master-port=ether2
set [ find default-name=ether4 ] master-port=ether2
set [ find default-name=ether5 ] master-port=ether2
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
add authentication-types=wpa-psk,wpa2-psk eap-methods="" \
management-protection=allowed mode=dynamic-keys name=WPA2 \
supplicant-identity="" wpa-pre-shared-key=superboy21 wpa2-pre-shared-key=\
superboy21
/interface wireless
set [ find default-name=wlan1 ] band=2ghz-b/g/n disabled=no frequency=auto \
mode=ap-bridge security-profile=WPA2
/ip firewall layer7-protocol
add name=streaming regexp="^. + (youtube.com | googlevideo.com | cdn.dailymoti\
on.com | fbcdn.net | metacafe.com | mccont.com). * \$"
add name=Youtube regexp=\
"^.+(youtube.com|akamaihd.net|googlevideo|fbcdn.net).*\$"
add name=Files regexp="^.*get.+\\\\.(exe|rar|zip|7z|cab|asf|mov|wmv|mpg|mpeg|m\
kv|avi|flv|pdf|wav|rm|mp3|mp4|ram|rmvb|dat|daa|iso|nrg|bin|vcd|mp2|3gp|mpe\
|qt|raw|wma|ogg|doc|deb|tar|bzip|gzip|gzip2|0[0-9][0-9]).*\\\$"
/ip pool
add name=dhcp_pool0 ranges=192.168.5.2-192.168.5.254
/ip dhcp-server
add address-pool=dhcp_pool0 disabled=no interface=bridge1 name=dhcp1
/queue tree
add max-limit=8M name="Total Download LAN" parent=bridge1 queue=default
add max-limit=8M name="Total Upload LAN-WI-FI" parent=ether1 queue=default
add limit-at=2M max-limit=8M name=Browsing-LAN-Download packet-mark=\
Browsing-LAN-Down-Packet parent="Total Download LAN" priority=2 queue=\
pcq-download-default
add limit-at=2M max-limit=8M name=Browsing-LAN-Up packet-mark=\
Browsing-LAN-UP-Packet parent="Total Upload LAN-WI-FI" priority=2 queue=\
pcq-upload-default
add limit-at=2M max-limit=8M name=Streaming-Wifi-Down packet-mark=\
Streaming-Down-Wifi-Packet parent="Total Download LAN" queue=\
pcq-download-default
add limit-at=3M max-limit=8M name=Streaming-Wifi-Upload packet-mark=\
Streaming-Up-Wifi-Packet parent="Total Upload LAN-WI-FI" queue=\
pcq-upload-default
add limit-at=1M max-limit=8M name=File-Limit-Down packet-mark=\
Limit-Down-Packet parent="Total Download LAN" queue=pcq-download-default
add limit-at=1M max-limit=4M name=File-Limit-Upload packet-mark=\
Limit-Up-Packet parent="Total Upload LAN-WI-FI" queue=pcq-upload-default
add limit-at=3M max-limit=8M name=Game-Online-Down packet-mark=GAME-Packets \
parent="Total Download LAN" priority=1 queue=pcq-download-default
add limit-at=3M max-limit=8M name=Game-Online-Up packet-mark=GAME-Packets \
parent="Total Upload LAN-WI-FI" priority=1 queue=pcq-download-default
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=wlan1
/ip address
add address=192.168.5.1/24 comment="LAN IP Subnet" interface=bridge1 network=\
192.168.5.0
/ip dhcp-client
add default-route-distance=0 dhcp-options=hostname,clientid disabled=no \
interface=ether1
/ip dhcp-server network
add address=192.168.5.0/24 gateway=192.168.5.1
/ip dns
set allow-remote-requests=yes servers=8.8.8.8
/ip firewall address-list
add address=192.168.5.0/24 list=OurLocalLAN
/ip firewall filter
add action=accept chain=input comment=\
"Allow access to the router from LAN using address list" \
src-address-list=OurLocalLAN
add action=drop chain=input comment="Drop all other traffic to the router"
add action=accept chain=forward comment="Allow connection from the LAN" \
connection-state=new in-interface=bridge1
add action=accept chain=forward comment="Allow established connections" \
connection-state=established
add action=accept chain=forward comment="Allow related connections" \
connection-state=related
add action=drop chain=forward comment=\
"Drop all other traffic through the router"
add action=drop chain=forward comment="Drop invalid connections" \
connection-state=invalid
add action=accept chain=input comment=\
"Allow established connections to the router" connection-state=\
established
add action=accept chain=input comment=\
"Allow related connection to the router" connection-state=related
/ip firewall mangle
add action=mark-connection chain=prerouting comment="Mangle BROWSING Lan" \
dst-port=80,443 in-interface=bridge1 new-connection-mark=\
Browsing-LAN-conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Mangle Down Lan Packet" \
connection-mark=Browsing-LAN-conn in-interface=ether1 new-packet-mark=\
Browsing-LAN-Down-Packet passthrough=no
add action=mark-packet chain=forward comment="Mangle Up Lan Packet" \
connection-mark=Browsing-LAN-conn in-interface=bridge1 new-packet-mark=\
Browsing-LAN-UP-Packet passthrough=no
add action=mark-connection chain=prerouting comment=Streaming in-interface=\
bridge1 layer7-protocol=Youtube new-connection-mark=\
All-Streaming-Wifi-Conn passthrough=yes src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Streaming Down Wifi Packet" \
connection-mark=All-Streaming-Wifi-Conn in-interface=ether1 \
new-packet-mark=Streaming-Down-Wifi-Packet passthrough=no
add action=mark-packet chain=forward comment="Streaming Up Wifi Packet" \
connection-mark=All-Streaming-Wifi-Conn in-interface=bridge1 \
new-packet-mark=Streaming-Up-Wifi-Packet passthrough=no
add action=mark-connection chain=prerouting comment="File LIMIT Conn" \
dst-port=80,21 in-interface=bridge1 layer7-protocol=*3 \
new-connection-mark=File-Limit-Conn passthrough=yes protocol=tcp \
src-address=192.168.5.0/24
add action=mark-packet chain=forward comment="Limit Down Packet" \
connection-mark=File-Limit-Conn in-interface=ether1 new-packet-mark=\
Limit-Down-Packet passthrough=no
add action=mark-packet chain=forward comment="Limit Up Packet" \
connection-mark=File-Limit-Conn in-interface=bridge1 new-packet-mark=\
Limit-Up-Packet passthrough=no
add action=mark-packet chain=forward comment="Mangle GAME" connection-mark=\
All-GAME-Conn new-packet-mark=GAME-Packets passthrough=yes
add action=mark-connection chain=prerouting comment="Dota 2 Steam" dst-port=\
27015-27030,27036-27037 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=PointBlank dst-port=\
39100-49100 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=CrossFire dst-port=\
9110,10008,13006,16666 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="LOL PH" dst-port=\
5222-5223,8393 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 2" \
dst-port=27930-27935,54689,55031,52846 in-interface=bridge1 \
new-connection-mark=All-GAME-Conn passthrough=yes protocol=tcp \
src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 1" \
dst-port=20000-21000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=yes protocol=tcp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Dota 2 Steam2" dst-port=\
27000-27037,4379-4380,3478 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment=PointBlank2 dst-port=\
40000-40010 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="CrossFire 2" dst-port=\
12000-12080,13000-13080,55000-65000 in-interface=bridge1 \
new-connection-mark=All-GAME-Conn passthrough=no protocol=udp \
src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="LOL PH2" dst-port=\
5000-5500 in-interface=bridge1 new-connection-mark=All-GAME-Conn \
passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 22" \
dst-port=54468,30000-31000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
add action=mark-connection chain=prerouting comment="Special Force 12" \
dst-port=20000-21000 in-interface=bridge1 new-connection-mark=\
All-GAME-Conn passthrough=no protocol=udp src-address=192.168.5.0/24
/ip firewall nat
add action=masquerade chain=srcnat out-interface=ether1
/system clock
set time-zone-name=Asia/Manila
/system identity
set name=MikroTikNiVice
/system ntp client
set enabled=yes primary-ntp=96.44.154.34 secondary-ntp=63.240.161.99
/system routerboard settings
set init-delay=0s
Attachments
Last edited: