Community discussions

MikroTik App
 
irfanbhatti82
just joined
Topic Author
Posts: 10
Joined: Sun Jan 05, 2014 3:41 pm

How i block google or other ads

Tue Jan 07, 2014 7:46 am

hello to all
sir i want to block all ads to my clients pc using mikrotik hotspot server.
kindly solve my problem.
thank you all.
 
tronity2k
just joined
Posts: 17
Joined: Thu Jul 12, 2007 8:22 pm

Re: How i block google or other ads

Tue Jan 07, 2014 1:12 pm

If you have server or vps on Internet install squid on rare port (not 8080 or default 3128) and use on hotspot options and enable transparent proxy on user profile

Biladele is extension for Squid proxy that block ads (include adblock plus filters), and other content type (pornographic, etc.).

http://www.quintolabs.com/
 
reinerotto
Long time Member
Long time Member
Posts: 520
Joined: Thu Dec 04, 2008 2:35 am

Re: How i block google or other ads

Tue Jan 07, 2014 3:11 pm

In case, MTs DNS is flexible enough, and you are happy with "brutal" blockage of ads, you can create
something like this:
......
zone "pagead2.googleadservices.com" { type master; notify no; file "/etc/null_zone"; };
zone "www.google-analytics.com" { type master; notify no; file "/etc/null_zone"; };
.....

null_zone:
; NULL Zone File for Ad Servers
;
$TTL 36000
@ in soa localhost. postmaster.localhost. (
2002110101 ;serial
3600 ;refresh
1800 ;retry
604800 ;expiration
3600 ) ;minimum

;
; Zone NS records
;

@ NS localhost.

A 127.0.0.1
* IN A 127.0.0.1




Or use squid-proxy (transparent) on a small PC running linux, which also might be part of your network. Caching is additional benefit.
 
irfanbhatti82
just joined
Topic Author
Posts: 10
Joined: Sun Jan 05, 2014 3:41 pm

Re: How i block google or other ads

Wed Jan 08, 2014 7:16 am

sir can you give me all ads block scripts which i paste in new terminal
 
francisuk24
newbie
Posts: 28
Joined: Tue Mar 18, 2014 12:10 am
Location: United Kingdom
Contact:

Re: How i block google or other ads

Tue Mar 18, 2014 6:07 pm

Here's a few I have with RouterOS 6.10

/ip firewall filter
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=doubleclick comment="doubleclick"
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=adverts comment="adverts"
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=adserver comment="adserver"
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=ads.ak.facebook.com comment="Facebook Ads"
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=counter comment="Counter ads"
add chain=forward action=reject reject-with=tcp-reset protocol=tcp content=banners comment="banners Ads"

Using DROP hangs but forward seems to end quicker.
 
hitechpro
just joined
Posts: 1
Joined: Mon Jun 01, 2015 10:09 am

How do i block ads

Mon Jun 01, 2015 10:21 am

Hello i am doing isp in guyana and using alot of mikrotik device using dhcp server but my problem is on my clients devices loading alot of ads while browsing using more bandwidth. Can anyone help me out please i am using a mikrotik rb750
 
kusakhan
just joined
Posts: 7
Joined: Wed Jan 30, 2013 9:24 pm

Re: How i block google or other ads

Fri Jul 22, 2016 6:55 pm

Working f9 for me thanks
 
umeshlk
just joined
Posts: 1
Joined: Mon Oct 24, 2016 8:47 am

Re: How i block google or other ads

Mon Oct 24, 2016 8:56 am

also found putting a static DNS entry to loopback for ad specific domain to be very effective.
e.g.
/ip dns static
add address=127.0.0.1 regexp=googlesyndication*
 
ivicask
Member
Member
Posts: 425
Joined: Tue Jul 07, 2015 2:40 pm
Location: Croatia, Zagreb

Re: How i block google or other ads

Mon Oct 24, 2016 9:41 am

http://stopad.generate.club/

Works wonders for me
 

Who is online

Users browsing this forum: Ahrefs [Bot] and 75 guests