hellowIf customers are assigned static IPs then it is so easy for you to add dropping rules through MT firewall, first of all your schema is a bit unclear but what I understood is that you need to block facebook for some clients knowing that these clients are assigned Static IPs, therefore collect the IPs you want to block and them to MT Firewall under Address List + add a filter Rule dropping facebook for instance to these specific clients, hope I was clear and if any further help needed please post back.
If customers are assigned static IPs then it is so easy for you to add dropping rules through MT firewall, first of all your schema is a bit unclear but what I understood is that you need to block facebook for some clients knowing that these clients are assigned Static IPs, therefore collect the IPs you want to block and them to MT Firewall under Address List + add a filter Rule dropping facebook for instance to these specific clients, hope I was clear and if any further help needed please post back.
thanks for your fast replyIf customers are assigned static IPs then it is so easy for you to add dropping rules through MT firewall, first of all your schema is a bit unclear but what I understood is that you need to block facebook for some clients knowing that these clients are assigned Static IPs, therefore collect the IPs you want to block and them to MT Firewall under Address List + add a filter Rule dropping facebook for instance to these specific clients, hope I was clear and if any further help needed please post back.
/ip firewall filter add action=drop chain=forward content=facebook disabled=no src-address=10.210.2.14
thanks for fast replyTry something like this.
Code: Select all/ip firewall filter add action=drop chain=forward content=facebook disabled=no src-address=10.210.2.14
/ip dns
set servers=<public DNS server1>,<public DNS server2> allow-remote-requests=yes
/ip dns static
add address=127.0.0.1 disabled=no name=facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=www.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=glib1.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=glib2facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=mail.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=dns.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns0.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns1.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns2.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns3.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns4.facebook.com ttl=5m
add address=127.0.0.1 disabled=no name=ns5.facebook.com ttl=5m
/ip firewall nat
add action=redirect chain=dstnat comment="Capture DNS" disabled=no dst-port=53 protocol=udp src-address-list=DNSBlacklist to-ports=53
add action=redirect chain=dstnat comment="Capture DNS" disabled=no dst-port=53 protocol=tcp src-address-list=DNSBlacklist to-ports=53
/ip firewall address-list
add address=<Client Static IP to be blocked> list=DNSBlacklist comment="Added to DNS block list on request of <Customer name>"
Check the order of your rules. Put the rule I gave you at the top and see if that works. You could have another rule accepting the traffic before it is suppose to get dropped.
Yep and you could also setup web-proxy. There are many different ways to achieve this.Ever consider a different approach such as blocking any outgoing DNS request that contains facebook?
you can transparently inspect DNS requests. you can NOT transparently inspect https traffic - it's encryptedyou could also setup web-proxy
My implementation:can you explain what can i do with the link?
/ip firewall address-list
add address=31.13.24.0/21 comment=\
"Facebook IP Subnets from: http://bgp.he.net/AS32934#_prefixes" disabled=\
no list=Facebook
add address=31.13.64.0/24 disabled=no list=Facebook
add address=31.13.64.0/19 disabled=no list=Facebook
add address=31.13.65.0/24 disabled=no list=Facebook
add address=31.13.66.0/24 disabled=no list=Facebook
add address=31.13.69.0/24 disabled=no list=Facebook
add address=31.13.70.0/24 disabled=no list=Facebook
add address=31.13.71.0/24 disabled=no list=Facebook
add address=31.13.72.0/24 disabled=no list=Facebook
add address=31.13.73.0/24 disabled=no list=Facebook
add address=31.13.74.0/24 disabled=no list=Facebook
add address=31.13.77.0/24 disabled=no list=Facebook
add address=31.13.75.0/24 disabled=no list=Facebook
add address=31.13.76.0/24 disabled=no list=Facebook
add address=31.13.78.0/24 disabled=no list=Facebook
add address=31.13.79.0/24 disabled=no list=Facebook
add address=31.13.80.0/24 disabled=no list=Facebook
add address=31.13.81.0/24 disabled=no list=Facebook
add address=31.13.82.0/24 disabled=no list=Facebook
add address=31.13.96.0/19 disabled=no list=Facebook
add address=66.220.144.0/21 disabled=no list=Facebook
add address=69.63.176.0/21 disabled=no list=Facebook
add address=69.63.176.0/24 disabled=no list=Facebook
add address=69.63.184.0/21 disabled=no list=Facebook
add address=69.171.224.0/20 disabled=no list=Facebook
add address=69.171.239.0/24 disabled=no list=Facebook
add address=69.171.240.0/20 disabled=no list=Facebook
add address=69.171.255.0/24 disabled=no list=Facebook
add address=74.119.76.0/22 disabled=no list=Facebook
add address=103.4.96.0/22 disabled=no list=Facebook
add address=103.4.96.0/22 disabled=no list=Facebook
add address=173.252.64.0/19 disabled=no list=Facebook
add address=173.252.70.0/24 disabled=no list=Facebook
add address=173.252.96.0/19 disabled=no list=Facebook
add address=204.15.20.0/22 disabled=no list=Facebook
/ip firewall filter
add chain=forward action=log dst-address-list=Facebook log-prefix="Faceboke Traffic" disabled=no
add chain=forward action=drop dst-address-list=Facebook disabled=no
add chain=forward action=drop src-address-list=Facebook disabled=no
> ip firewall filter add action = drop chain = forward comment = "Block Facebook" dst-address = 66
.220.144.0/20
> Ip firewall filter add action = drop chain = forward comment = "Block Facebook" dst-address = 69
.63.176.0/20
> Ip firewall filter add action = drop chain = forward comment = "Block Facebook" dst-address = 20
4.15.20.0/22
> ip firewall filter add action = drop chain = forward comment = "Block Facebook" dst-address = 69.171.224.0/19
> add action = accept chain = forward src-address = 192.168.1.62 dst-address = 66.220.1.0/20
> add action = accept chain = forward src-address = 192.168.1.62 dst-address = 69
.63.176.0/20
> add action = accept chain = forward src-address = 192.168.1.62 dst-address = 20
4.15.20.0/22
> add action = accept chain = forward src-address = 192.168.1.62 dst-address = 69.171.224.0/19
Thanks, works perfectlyMake sure your accept rules are before your drop rules.
it won't work: as far as I can see, twitter uses encrypted connections. but blocking by IP ranges sould work, recheck your configI tried to block twitter by content and isn't working either.
Its kind of working to me. But how can I extend to multiple-ip (such as group in profile) so that the specific profile can not access facebook? (I did try, to set inside the hotspot user profile, address list like block_facebook), and then assign it in the ip firewall filter, advanced, source list), and it didn't workTry something like this.
Code: Select all/ip firewall filter add action=drop chain=forward content=facebook disabled=no src-address=10.210.2.14