SHOW:
|
|
- or go back to the newest paste.
| 1 | /ip firewall address-list | |
| 2 | add address=10.0.0.0/8 list=private-lokal | |
| 3 | add address=172.16.0.0/12 list=private-lokal | |
| 4 | add address=192.168.0.0/16 list=private-lokal | |
| 5 | ||
| 6 | /ip firewall layer7-protocol | |
| 7 | add name=youtube regexp="(youtube.com|r[0-9]+---[a-z]+-+[a-z0-9-]+\\.googlevideo\\.com)" | |
| 8 | ||
| 9 | #misal ether1 = biznet = 192.168.1.1 = default route = jalur-1 dan exit-1 | |
| 10 | #misal ether2 = adsl = 192.168.2.1 = jalur-2 dan exit-2 | |
| 11 | ||
| 12 | /ip route | |
| 13 | add check-gateway=ping comment=exit-1 distance=1 gateway=192.168.1.1 routing-mark=exit-1 | |
| 14 | add check-gateway=ping comment=exit-2 distance=1 gateway=192.168.2.1 routing-mark=exit-2 | |
| 15 | add check-gateway=ping comment=jalur-1 distance=1 gateway=192.168.1.1 | |
| 16 | add check-gateway=ping comment=jalur-2 distance=2 gateway=192.168.2.1 | |
| 17 | add check-gateway=ping comment=jalur-1 distance=1 gateway=192.168.1.1 routing-mark=jalur-1 | |
| 18 | add check-gateway=ping comment=jalur-2 distance=1 gateway=192.168.2.1 routing-mark=jalur-2 | |
| 19 | ||
| 20 | /ip firewall mangle | |
| 21 | add action=accept chain=input dst-address-list=lokal src-address-list=private-lokal | |
| 22 | add action=accept chain=prerouting dst-address-list=lokal src-address-list=private-lokal | |
| 23 | add action=accept chain=forward dst-address-list=lokal src-address-list=private-lokal | |
| 24 | add action=accept chain=postrouting dst-address-list=lokal src-address-list=private-lokal | |
| 25 | add action=accept chain=output dst-address-list=lokal src-address-list=private-lokal | |
| 26 | add action=mark-connection chain=input comment=exit-1 in-interface=ether1 new-connection-mark=exit-1 passthrough=yes | |
| 27 | add action=mark-connection chain=input comment=exit-2 in-interface=ether2 new-connection-mark=exit-2 passthrough=yes | |
| 28 | add action=mark-routing chain=output comment=exit-1 connection-mark=exit-1 new-routing-mark=exit-1 passthrough=no | |
| 29 | add action=mark-routing chain=output comment=exit-2 connection-mark=exit-2 new-routing-mark=exit-2 passthrough=no | |
| 30 | #akses youtube via biznet sebagai default route | |
| 31 | add action=accept chain=prerouting dst-address-list=!private-lokal src-address-list=private-lokal layer7-protocol=youtube | |
| 32 | #selain youtube, via adsl sebagai jalur-2 | |
| 33 | add action=mark-routing chain=prerouting comment=jalur-2 src-address-list=private-lokal dst-address-list=!private-lokal new-routing-mark=jalur-2 passthrough=no |