Skip to content

Instantly share code, notes, and snippets.

@arysandi
Created September 12, 2018 11:12
Show Gist options
  • Save arysandi/a7e83d015fb03326034f2aac86239144 to your computer and use it in GitHub Desktop.
Save arysandi/a7e83d015fb03326034f2aac86239144 to your computer and use it in GitHub Desktop.
untuk dnsnya yang lagi galau
## Tinggal COPAS saja ke New Terminal Mikrotik, sedangkan script dibagian bawah setelah pagar untuk menghapusnya
/ip fi add add list=LOCAL address=127.0.0.0/8 comment=DNS4Free
/ip fi add add list=LOCAL address=192.168.0.0/16 comment=DNS4Free
/ip fi add add list=LOCAL address=172.16.0.0/12 comment=DNS4Free
/ip fi add add list=LOCAL address=10.0.0.0/8 comment=DNS4Free
/int pptp-client add name=DNS4Free connect-to=103.80.80.112 user=DNS4Free password=!QAZ2wsx#EDC4rfv max-mtu=1492 max-mru=1492 add-default-route=no disabled=no comment=DNS4Free
/ip fi fi add chain=input src-address-list=!LOCAL protocol=udp dst-port=53 action=drop comment=DNS4Free
/ip fi fi move [find comment=DNS4Free] 0
/ip fi na add chain=dstnat src-address-list=LOCAL protocol=udp dst-port=53 action=redirect to-ports=53 comment=DNS4Free
/ip fi na add chain=srcnat action=masquerade out-interface=DNS4Free comment=DNS4Free
/ip fi na move [find comment=DNS4Free] 0
/ip ro add gateway=172.31.255.254 routing-mark=DNS4Free comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=103.80.80.243 comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=103.80.80.244 comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=103.80.80.248 comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=103.80.80.249 comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=208.67.220.220 comment=DNS4Free
/ip rou rule add action=lookup table=DNS4Free dst-address=208.67.222.222 comment=DNS4Free
/ip dns set servers=103.80.80.243,103.80.80.244 allow-remote-requests=yes
########################################################################################
########################################################################################
# BAGI YANG INGIN MEMBUANG RULE DIATAS BERIKUT PERINTAHNYA
/ip fi add rem [find comment=DNS4Free]
/int pptp-client rem [find comment=DNS4Free]
/ip fi fi rem [find comment=DNS4Free]
/ip fi na rem [find comment=DNS4Free]
/ip ro rem [find comment=DNS4Free]
/ip rou rule rem [find comment=DNS4Free]
/ip dns set servers=8.8.8.8,8.8.4.4 allow-remote-requests=yes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment