r/GalaxyS9 • • Dec 24 '18

Blocking ads without additional software in Android 9.0 Pie (finally :D)

As I received Pie today (Germany yay), I immediately remembered the feature I was looking forward to:

DNS over TLS, which has been natively integrated in Pie.

This finally allows us to block ads system wide (for apps without built in dns resolver) without installing additional software or plugins or anything. Getting started is really easy:

1.) Open Settings --> Connections --> More connection settings --> Private DNS

2.) Check Private DNS provider hostname

3.) depending on what you want enter either:

dns.adguard.com

dns-family.adguard.com (for nofap :D)

dot-de.blahdns.com (small hobby project with adblock)

These are secure DNS servers that have integrated ad blocking. Adguard is a Russian company, blahdns is a small hobby project with a good history...

4.) Press Save & enjoy ad free browsing.

5.) Extra step for chrome users:

Open Chrome, type in chrome://flags

search for async DNS resolver (#enable-async-dns) and choose disabled in the drop down menu.

(Otherwise chrome could use a built in dns resolver which does not block ads)

Over the years I used root with hostlist, blokada, dns over local vpn with adguard dns servers, firefox, samsung internet with adblock and brave browser.

This is finally a builtin solution that just works and it even enables secure encrypted dns.

So win win :)

Merry Christmas and thank you Samsung for Pie.

433 Upvotes

114 comments sorted by

5

u/Lankgren Dec 24 '18

Do you feel this is an alternative to SABS/Adhell 3 (excluding the app disabler)?

1

u/johnmannn Jan 18 '19

Adhell3's ad blocker was blocking way too much. Made it unusable for me plus it's incredibly slow. I only use it for app and component disabling. I use Adguard for ad blocking.

-5

u/panda_de Dec 24 '18

This is bascially the same thing but you cant add your own hosts/domains and you send your dns queries to adguard/blahdns.

But in theory they work the same way...

-2

u/Industech Dec 24 '18

And yet you didn't show a proof of this blocking ads in Samsung internet.

1

u/Arden144 Dec 25 '18

I guarantee you it is. If you understood at all how this works, it wouldn't even be a question.

Android now has system wide DNS settings, therefore you set your DNS to a well known Adblock DNS. Everything on your phone will then resolve queries through that DNS server and the server will refuse connections to ad providers

-3

u/Industech Dec 25 '18

Proof or GTFO.

Google knew this and added the port workaround in chromium to not lose more money.

If you don't have a proof that it blocks ads in internet browser then just shut the hell up dude.

59

u/moriartyj Dec 24 '18

Not sure giving you dns traffic to a random Russian company is a smart move

20

u/bobsagetfullhouse Dec 24 '18

They're a fairly known trusted company in the adblock community.. Just because theyre Russian doesn't mean they're automatically malicious

16

u/moriartyj Dec 24 '18 edited Dec 24 '18

Agreed, they are. But if Kaspersky, a much bigger trusted and respected Russian company has been found to have placed backdoors for the Russian government, it isn't such a stretch to assume others do too

6

u/bobsagetfullhouse Dec 24 '18

Good point. But still, I don't know where you're from but it's not a stretch to think that the NSA has its roots in similar US companies. You just have to assume no matter what you can possibly be being watched.

4

u/moriartyj Dec 24 '18

Agreed, which is why we each need to be mindful and find reliable (possibly personal/VPNed) DNS servers, not give our data away to random companies

1

u/sonofaclow Mar 10 '22

I doubt they have a choice in the matter

16

u/Imma_Explain_Jokes Dec 24 '18

Adguard has proven to be reliable.

19

u/moriartyj Dec 24 '18

I have no doubt. I'm just not sure what they do with the DNS data that you give them

2

u/Rediwed Dec 25 '18

They block ads with them. I've been using AdGuard (non-dns version) for quite a while now. They have great and fast support!

5

u/MoNeenja31 Galaxy S9+ Dec 24 '18

My 1st thought

1

u/[deleted] Mar 13 '19

Better than giving it to any American (or other Western for that matter) company.

-1

u/kekela91 Exynos S9+ Dec 24 '18

Their DNS is open source.

1

u/moriartyj Dec 24 '18

Is it? Mind posting it for me?

2

u/panda_de Dec 24 '18

Well, they see all your dns queries, thats a technical reality without doubt.

They say that they are not logging (https://kb.adguard.com/en/dns/overview), but you never know.
Although your provider will probably log as well.

A non profit no logging dns provider would still be preferable I guess, although blahdns comes close.

4

u/kekela91 Exynos S9+ Dec 24 '18

1

u/moriartyj Dec 24 '18

Interesting. Thanks!

0

u/[deleted] Dec 24 '18

[deleted]

-8

u/kekela91 Exynos S9+ Dec 24 '18

Do you know what "open source" means? That means the whole dns server implementation is open to review their code. You can see in their code if it's storing the data.

6

u/unstoppable-force Dec 24 '18

It's trivial to make some repo online of their purportedly safe source while running different code.

0

u/Nickx000x Dec 24 '18

They can only see your DNS queries correct? Unless you're an important person, I see no reason why this would be of any harm to people

2

u/moriartyj Dec 24 '18 edited Dec 24 '18

You can still compile a pretty comprehensive profile from a user's DNS queries. Combined with the kind of spying/manipulation the Russian government was involved in, this can be a powerful tool

1

u/Nickx000x Dec 24 '18

Ok, but I'm not an important person, and neither is anyone else in this thread. How does this affect me?

Russian government> "lolol you visited pornhub"

1

u/moriartyj Dec 24 '18

Russian government> You seem to be visiting WaPo/NYT/random list of sites? You probably belong to this profile. Here's how we can manipulate your opinion by ad-targeting you.

Not so far fetched considering that it's well-documented they've done so successfully before

1

u/Nickx000x Dec 24 '18

Ok but how are they going to ad-target me? And if this is well-documented, provide sources, please.

2

u/moriartyj Dec 24 '18

1

u/Nickx000x Dec 24 '18

Ok? But how would they target me specifically from pretty much just an IP and dns queries?

1

u/moriartyj Dec 24 '18

IPs in the majority of the US are static (or static over very long durations). And this isn't necessarily about targeting you specifically, but supplying the infrastructure to target large amount of people. Afterall, does it matter if they didn't target you but successfully targeted 10,000 of your neighbors?

1

u/unstoppable-force Dec 25 '18

Phone IPs are not static, and this is talking mainly about mobile adblocking. You can go through multiple IPs in a single browsing session with cell towers.

→ More replies (0)

1

u/pyro226 Dec 25 '18

I like how you saythey will ad target when the whole purpose of setting adguard dns was to block ads.

1

u/moriartyj Dec 25 '18 edited Dec 25 '18

Ad blocking is not 100%. On Facebook, for instance (and social media in general), ads and sponsored content can come from friends and bots that you have no way of blocking

0

u/[deleted] Dec 24 '18

[deleted]

6

u/Lets69Chipmunks Dec 24 '18

What's up with cloudfare?

16

u/seizedengine Dec 24 '18

Nothing, some people apparently trust a Russian company more than a major security company that has stated it doesn't keep records and will be audited as such....

3

u/aye_am_groot Dec 30 '18

Hi,

Thank you for the wonderful post , really helpful.

Maybe i am just getting a little greedy here , but when this method is used to block ads in chrome , it leaves unloaded blocks of ads in the page , that just looks plain ugly. Unlike in my laptop , when i use ad block i dont see any unloaded blocks , i have no idea if an ad was there on the page.

If there is a way around this in chrome android , i would be grateful to anyone who can tell me how its done. If not , grateful anyway

1

u/panda_de Dec 31 '18

You would need to use Samsung Internet or any other browser where adblock exists (brave browser for example is a chrome port with adblock built in).

If you insist on isomg chrome you could use adguard on android (there is a program, you need to sideload it and its paid software, it also intercepts the https requests to block ads on encrypted pages)

2

u/Industech Dec 24 '18

That works on Samsung internet? It shouldn't work because of the port chromium uses.

5

u/panda_de Dec 24 '18

Yes it works on Samsung internet.

This is an Android feature, not a chrome(-ium) feature.

As long as an app does not use something like proxy/vpn/their own dns, all apps should work.

1

u/Industech Dec 24 '18

Samsung internet and chrome have a port that has to be blocked in adhell to block ads.

1

u/[deleted] Dec 24 '18

Could you explain how to do this for samsung internet in adhell? I was wondering why I couldn't get it to work.

0

u/[deleted] Dec 24 '18

[deleted]

1

u/[deleted] Dec 24 '18

Does this work for samsung internet too or chrome only?

1

u/Diggity_McG Dec 24 '18

That is specifically for Chrome. Change out the chrome app identifier for the Samsung Internet one and it will work.

com.sec.android.app.sbrowser|*|53

2

u/tiradium Galaxy S9+ Dec 24 '18

This is awesome, I already have PiHole installed on my home network but this can be useful when I am connected to other networks. Just need to find another DNS provider that is privacy focused

3

u/panda_de Dec 24 '18

Both adguard (https://kb.adguard.com/en/dns/overview) and blahdns say that they dont log. So this would be privacy friendly (or at least as privacy friendly as your provider unless you use a no log dns server)

2

u/dabar_zg Dec 31 '18

Be aware: Possible causing reboots!

Many thanks for sharing! I've been using it for a week now and it's working just fine, in my opinion as good as AdGuard agent itself or Blokada.

HOWEVER, I've found that it is a cause of spontaneous reboots of my non-rooted international OP6t. I've been fighting this problem for a week, and finally 2 days ago read somewhere about Private DNS causing these problems. I've turned it off and not a single reboot occurred any more

1

u/panda_de Dec 31 '18

Using this without any reboots on S9 exynos version...

2

u/Hailfall Jan 14 '19

I am actually having the same issue on my S9 exynos, which was really weird.

1

u/rft183 Jan 03 '19

Yes, this has caused my Snapdragon S9 to reboot a lot. They are soft reboots, but it was really annoying.

16

u/GhostDogThing Dec 24 '18

Take my upvote man

5

u/jvrcb17 Dec 24 '18

That's a hella nice Christmas present. thanks OP

2

u/[deleted] Dec 24 '18

Will instagram ads be blocked too ?

2

u/panda_de Dec 24 '18

This should work the same way as hostlist based ad blockers.

So this blocks loading data from ad domains. It should work for apps.

This does not have cosmetic filters like ublock for firefox or Adguard for Samsung internet.

I dont have instagram, but it would be extremely easy for instagram to circumvent this, so I dont think it will work...

3

u/[deleted] Dec 24 '18

Obviously... Instagram is based on ads...

-1

u/kongeo Dec 24 '18

dont be sure...instagram seems to dont care about samsung phones..instagram for samsung is optimized to like 60% ...stories cut out,video quality low,notification problems...so they may not even see it hahah

1

u/Arden144 Dec 25 '18

I've never had those issues. What are you on, a Grand Prime?

3

u/Franseven Exynos S9+ Dec 25 '18

no because instagram adds are post just sponsored to pop into your home posts

1

u/invulnerable888 Exynos S9+ Dec 24 '18

very nice! does it affect the connection speed ?

3

u/panda_de Dec 24 '18

This only encrypts your DNS queries and sends them to either adguard or blahdns servers. This is NOT a VPN. The normal network traffic is unaffected as is the connection speed.

This could (slightly) increase or decrease your dns lookup times, depending on the speed of your dns servers (the dns servers are most often hosted by your provider).

All in all, you shold not see much of a difference.

1

u/invulnerable888 Exynos S9+ Dec 24 '18

I got it now, so also it doesn't open banned website right? like political ones

1

u/GO-ON-A-STEAM-TRAIN Dec 24 '18 edited Dec 24 '18

Hi! Thank you for sharing! :)

I was just wondering if you or anyone reading would happen to know if this works with the default Samsung browser out the box, or if I still need an adblock like Crystal installed?

I just tried the dns.adguard.com setting on Ultimate-guitar.com (my quick test as it's so infested with adverts) and adguard being set seemed to be letting them all through. :)

Thank you again for sharing and Merry Christmas! 😁

Edit: I neglected to mention I can now play air hockey and other games without adverts interrupting! Thank you so much! 😍

3

u/panda_de Dec 24 '18

It works with the Samsung browser.

I have no ads on ultimate-guitar.com.

Try restarting the phone and clearing cache of Samsung browser, maybe it has the dns data of the ad servers cached.

Although if you use the samsung browser , the ad blocking extensions will work better as they have more possibilities to block ads.

2

u/GO-ON-A-STEAM-TRAIN Dec 24 '18

Ah thank you, I hadn't thought of restarting the phone or clearing the cache for some reason! :)

I'll likely do a mixture of them, as crystal was working great for me to begin with, and I love ad-free apps. Thank you again for sharing this! :)

2

u/[deleted] Dec 24 '18

You don't see google ads on ultimate-guitar ? I cleared cache and rebooted a bunch of times but I'm still seeing google ads on Samsung Internet.

2

u/GO-ON-A-STEAM-TRAIN Dec 25 '18

Darnit! I rebooted and cleared the cache, and it worked fine until I refreshed 😂 time for adblocker in the browser too :)

No adverts in other apps is great though! 😁

Happy Christmas!

2

u/[deleted] Dec 25 '18

It's weird. Relay's internal browser works fine. Samsung Internet must have a dns override or something. Happy Christmas to you too. :)

2

u/GO-ON-A-STEAM-TRAIN Dec 25 '18

I have a feeling youre right and it's a DNS thing similar to the Chrome fix the OP listed :)

1

u/gamehoernchen Dec 24 '18

does this work on the Youtube App? I tried the dot-de.blahdns.com and still get ads? Maybe im doing something wrong here?

3

u/panda_de Dec 24 '18

I just checked, this does not work with the youtube app.

1

u/sabeshs Feb 09 '19

Thanks for this post! Ad blocking works well. Is there a point to having the Adguard app installed now? Thx.

8

u/jbot84 Dec 24 '18

Look into YouTube vanced. Life changing!

1

u/Citizen_V Galaxy S8 Dec 25 '18

You can't easily block YouTube video ads with DNS filtering. On Android devices, the best option to use a modded app like YouTube Vanced or NewPipe.

1

u/stylz168 Dec 24 '18

Interesting, so if I run my own DNS through my Synology router/NAS, I can route my traffic that way?

1

u/panda_de Dec 24 '18

I guess you would need a certificate of some kind? But theoretically you should be able to set something up...

1

u/Imma_Explain_Jokes Dec 24 '18

Nice. Anything about the built-in VPN thing in Android that Samsung replaced with it's paid version? Secure Wi-Fi or something? Is it available now?

1

u/panda_de Dec 24 '18

I dont know anything about that, sorry. I guess this doesnt work with vpn as vpn can set their own dns servers.

1

u/Svartdraken Dec 31 '18

I have set up dns.adguard.com a couple of days ago, and something strange happened. While I was sleeping, my phone has activated a paid fraudulent offer, without me having any open web pages. Even if I did, this DNS is supposed to block ads, right? All apps allowed to appear on top are mostly trusted. Do you think that adguard could have interfered somehow?

2

u/panda_de Dec 31 '18

It can't block all domains, you can just register a new domain and adguard wouldnt know. You have a better chance of blocking something with adguard enabled. A dns gives no access to your system, and https enabled pages would show an error (https enabled pages are often used for processing payments), so its almost impossible adguard has anything to do with this.

1

u/Svartdraken Dec 31 '18

Thanks for the reply. Still, it's very hard for me to find an explanation about this issue I have encountered, since I've been using the same apps since I got the S9+. I need to figure out what happened at 6 AM to trigger this thing.

0

u/danielsuarez369 Galaxy S9+ Dec 24 '18

I'll stick to an open source alternative like Blokada.. unlike this, Blokada doesn't send anything to a random company.

Just my two cents

4

u/panda_de Dec 24 '18

I am no programmer, so I dont know if the blokada apk matches the blokada source code. I also dont know which data is sent to blokada when you run the program or when blokada updates its hostlist or when you check for blokada updates.

I think blokada is trustworthy, but I cant prove it as I dont know any programming language.

Blahdns and Adguard say that they dont log, which I also cant prove.

I would like to mention that if you use blokada with your providers dns servers, the adguard/blahdns solutions are probably just as good from a privacy point of view. If you use a trustworthy no logging dns service with blokada, this could be preferable...

1

u/[deleted] Dec 24 '18

I wish i could use a pihole there, but indeed that are great news for all.

1

u/crossdeath Dec 24 '18

Thank you so much man!

1

u/Rbntr Exynos S9+ Dec 24 '18

Thanks a lot! Really useful!

1

u/mottavader Snapdragon S9 Dec 24 '18 edited Dec 24 '18

Cool. Gonna give this a go. I already have an ad blocker in Samsung internet but I occasionally use other browsers Update : works like a charm. Thanks for the info!!

1

u/RenegadeUK Dec 24 '18

Merry Christmas to one and all :)

1

u/[deleted] Dec 24 '18

Thank you for your post!

Echt klasse von dir! :D

1

u/mrpickem1 Dec 24 '18

That is f'n awesome...thx dude

1

u/Pigrolac Dec 25 '18

Thank you for this. Just flashed the Germany pie build on my Filipino S9, couldnt be happier

1

u/Franseven Exynos S9+ Dec 25 '18

working even on apps :), for example on zedge, the ad video does not start and the wallpaper unlocks... perfect

1

u/[deleted] Dec 25 '18

I didn't know adguard supported dns over tls :0 Thank you! :)))

1

u/[deleted] Dec 25 '18

This will be helpful for users who don't want to install/cant install adhell. I have to use adhell because there are apps I need to whitelist so they can work properly.

1

u/render_use Dec 30 '18

So this is not working with VPN?

1

u/jvrcb17 Jan 04 '19

So it was kind of killing me for a while.... But I finally realized this change broke my MMS weeks ago. :(

Have to deal with ads for now.

1

u/johnmannn Jan 18 '19

What's wrong with the Adguard app? You get custom ad blocking and the ability to quickly disable ad blocking, both very important features.

1

u/mankal24 Feb 19 '19

Does this work with the Youtube app as well?

1

u/[deleted] Mar 13 '19

Just use Yandex browser, it can actually download extensions from the Chrome App Store so you can download uBlock Origin, Popup Blocker (Strict) and Privacy Badger... no need for doing something as complicated as this, besides, AdGuard is not the most efficient blocker, uBlock Origin is.

I always thought that when Google made Chrome for Android not being able to install extensions that it was something that they removed from the code for the mobile version, but Yandex just proved that wrong. I only found out about this last night and I'm so psyched I don't have to use the slow and bloated Firefox for Android anymore, because it was the only browser (until now) that could install extensions from its store.

1

u/MegaSharkReddit Mar 31 '19

What are the main disadvantages vs. Blokada?

1

u/starterz May 21 '19

Phenomenal! Thank you! Working great on S8+ with Pie.

1

u/Spirit_mert Oct 05 '26

Adguard dns doesnt work for me in Europe, I was in a 3rd world before, I think my internet providers block adguard now, any tips how to get over the block?

1

u/[deleted] Dec 24 '18

Nice Thanks! Does this work for apps too?

2

u/GhostDogThing Dec 24 '18

Seems to work, haven't got ads in games now

0

u/[deleted] Dec 24 '18

[deleted]

1

u/RemindMeBot Dec 24 '18

I will be messaging you on 2019-02-09 03:33:14 UTC to remind you of this link.

CLICK THIS LINK to send a PM to also be reminded and to reduce spam.

Parent commenter can delete this message to hide from others.


FAQsCustomYour RemindersFeedbackCodeBrowser Extensions

0

u/[deleted] Dec 24 '18

[deleted]

1

u/surprisebuttseks Dec 25 '18

!remindme 1.5 month

1

u/toseawaybinghamton Galaxy S9+ Dec 24 '18

!remindme 1.5 month

1

u/Danthekilla Dec 25 '18

!remind me 1 month

1

u/coberh Dec 25 '18

!remindme 1.5 month

1

u/Redztar Dec 25 '18

!remindme 1.5 month