Modify hosts file without root? - OnePlus 8T Questions & Answers

OP 8T phone I use for company work, can't root. Is there a way to replace the hosts file with a larger, modified one to block all the spam advertising when browsing? or an Android FireFox add-in that blocks them?
Phone is original unlocked 8T (no TMo bloatware), with TMo 5G SIM.
TIA

No way to replace hostfile without root as far as I know.

Wisiwyg said:
OP 8T phone I use for company work, can't root. Is there a way to replace the hosts file with a larger, modified one to block all the spam advertising when browsing? or an Android FireFox add-in that blocks them?
Phone is original unlocked 8T (no TMo bloatware), with TMo 5G SIM.
TIA
Click to expand...
Click to collapse
Use DNS66 - see https://forum.xda-developers.com/t/app-5-0-dns66-open-source-host-ad-blocker-without-root.3487497/

Thank you for the suggestion of DNS66. I'll pass.
Couple of reasons... It isn't found in PlayStore, you have to side load outside of 'protected' apps. Also, it functions as a private DNS, routing all lookups through a DNS service that resides.... somewhere.
I've found another possible way by using ADB and Android Tools, pull/push files. But don't know if I need to unlock to do this.

Change to any dns with adblocking like dns.adguard.com by setting private dns in android settings.

Wisiwyg said:
Thank you for the suggestion of DNS66. I'll pass.
Couple of reasons... It isn't found in PlayStore, you have to side load outside of 'protected' apps. Also, it functions as a private DNS, routing all lookups through a DNS service that resides.... somewhere.
I've found another possible way by using ADB and Android Tools, pull/push files. But don't know if I need to unlock to do this.
Click to expand...
Click to collapse
Hello
Did you find a way to edit the host file without root on OnePlus 8t ?
Thank you in advanced

you could use surfboard or clash for android to modify hosts ,but it need use VPN

You can use AdAway in VPN mode or
install Ublock Origin Firefox plugin or
use private DNS as suggested by @Rootk1t

Related

Blocking ads Securely

I would like to block ads on my phone using something like ad block plus or the hosts file but I'm having a hard time getting anything to work smoothly without rooting. I want to be able to use my phone for banking too so I'm hesitant to root. Is it possible to block ads without diminishing the security of my phone?
I played with using an ad blocker and firewall and connection monitor together but don't know enough about Android to feel confident I'm not vulnerable. It seems like the best security might be stock firmware.
Where's the android version of that mac program "little snitch"?
Please post your opinions and advice. Thanks!
There are a module for the xposed framework that are able to hide root to selected apps. And I'm sure there are apps to do the same thing if you don't want to use the xposed framework.
Sent from my Desire HD
fsd28 said:
I would like to block ads on my phone using something like ad block plus or the hosts file but I'm having a hard time getting anything to work smoothly without rooting. I want to be able to use my phone for banking too so I'm hesitant to root. Is it possible to block ads without diminishing the security of my phone?
I played with using an ad blocker and firewall and connection monitor together but don't know enough about Android to feel confident I'm not vulnerable. It seems like the best security might be stock firmware.
Where's the android version of that mac program "little snitch"?
Please post your opinions and advice. Thanks!
Click to expand...
Click to collapse
Think the easiest way to do it is to use a modded hosts file (it's located in /system/etc/hosts or /data/data/etc/hosts, if I'm not mistaken). In fact, if you replace that file with another - modified - one (that you can find in a lot of threads, here, on XDA), it will automatically block every Ad based on any domain marked in your new hosts file.
Made a quick research:
Mother of all HOSTS file - 'hosts' file for your SGS2 Baby - Updated on 15 Feb 2012
(MoaAB) Mother of All AD-BLOCKING (20 MAY 2014) BLOCKS Malware Spyware Bloatware
[MOD][GUIDE][Apr14] AdAway on Write Protected /system Partitions [RECOVERY]
Obviously, you can find much more!

Removing ads without root?

Hi guys
simple question, is there any way to remove ads without root and adaway? Especially on browsers like chrome and samsung browser.. I don't want to root my S7 because I need that warranty.
thanks
Silvers91 said:
Hi guys
simple question, is there any way to remove ads without root and adaway? Especially on browsers like chrome and samsung browser.. I don't want to root my S7 because I need that warranty.
thanks
Click to expand...
Click to collapse
read about Block this
Silvers91 said:
Hi guys
simple question, is there any way to remove ads without root and adaway? Especially on browsers like chrome and samsung browser.. I don't want to root my S7 because I need that warranty.
thanks
Click to expand...
Click to collapse
Adguard works wonders. I can't post a link because I don't have enough posts. But it's just adguard dot com.
I read about block-this but I don't understand how it works or if it secure. Has anyone done a deep dive into this app? I'm very concerned with security and data leakage.
Is Adguard the next best alternative?
blockthis works fine with unrooted MM, better then adguard, no probs in security
Any non-root adblocker uses a VPN to re-route traffic through via a custom hosts file that filters out the ads, Adguard uses a local VPN for http traffic, but for https I think they use a remote server (https blocking is disabled by default)
Samsung browser has extensions especially for ad block ?
exaflare said:
Samsung browser has extensions especially for ad block ?
Click to expand...
Click to collapse
Doesn't block ads in apps, only web
*Detection* said:
Doesn't block ads in apps, only web
Click to expand...
Click to collapse
Yes I know but I believed that is what the OP wants when he said "especially on browsers" and those extensions doesn't required root ?
exaflare said:
Yes I know but I believed that is what the OP wants when he said "especially on browsers" and those extensions doesn't required root
Click to expand...
Click to collapse
Thank you both for the suggestions! blocking within apps would be great too! I was just worried about data leakage to third party servers etc... I don't quite understand how everything works in detail but the developer of Block-This has a thread going on XDA (https://forum.xda-developers.com/s7-edge/themes/block-ad-blocker-root-t3338098) and seems like a honest dev, but you can't be sure unless you understand how the system works. I'll try to get Steve Gibson from Security Now Podcast to get into it in detail, he understands it down to the base and explains it well for the slow among us such as I.
What about dns66
*Detection* said:
Any non-root adblocker uses a VPN to re-route traffic through via a custom hosts file that filters out the ads, Adguard uses a local VPN for http traffic, but for https I think they use a remote server (https blocking is disabled by default)
Click to expand...
Click to collapse
That's true. But obviously one can leave the https filtering option disabled if concerned about proxying through the remote server. And I would think that opting to use it should be relatively safe considering that all https traffic is encrypted. The destination site is the only party who should be able to decrypt it.

Can't make adway work.

Hello xda users.. today im facing a big problem..
I have op6 with rooted (magisk installed). oos 9.02
Ive installed latest adway 4.0.11. Everything works fine (adway gets permisions.. etc). But he does not stop the ads.
In magisk i have ticked systemless hosts same for adway in prefs. What i am doing wrong?
I am missing something?
zubyro said:
What i am doing wrong?
I am missing something?
Click to expand...
Click to collapse
I haven't routed a phone for a few years now but I seem to remember Adaway wrote its hosts file to the system partition. And isn't it the way of Magisk to not write anything to system?
I use Adguard directly from Adguard.com. It just works, (apart from the odd time Oneplus closes it ,) and I ALWAYS have Google Pay working too - so no hassle at checkouts.
Ended up using dns66.. cant make adway to work..
zubyro said:
Ended up using dns66.. cant make adway to work..
Click to expand...
Click to collapse
I have Adaway running on my rooted OP 6, but I'm not using that systemless switch you mentioned...
zubyro said:
Ended up using dns66.. cant make adway to work..
Click to expand...
Click to collapse
Use AdAway v3.3. I have it working perfectly fine.
croques said:
I haven't routed a phone for a few years now but I seem to remember Adaway wrote its hosts file to the system partition. And isn't it the way of Magisk to not write anything to system?
I use Adguard directly from Adguard.com. It just works, (apart from the odd time Oneplus closes it ,) and I ALWAYS have Google Pay working too - so no hassle at checkouts.
Click to expand...
Click to collapse
I agree with you. Adaway just doesn't do anything for me. Adguard just works, and it works very well.
On unrooted phones, the VPN adapter is used to reroute traffic. As I use a normal VPN permanently to prohibit carrier deep packet inspection, any adblocker relying on the VPN approach is a nogo for me as Android only supports one VPN connection at a time.
akxak said:
On unrooted phones, the VPN adapter is used to reroute traffic. As I use a normal VPN permanently to prohibit carrier deep packet inspection, any adblocker relying on the VPN approach is a nogo for me as Android only supports one VPN connection at a time.
Click to expand...
Click to collapse
I agree with you totally. I would much prefer your way of a permanent VPN and to block ads some other way.. However,
I need Google Pay to work all the time and not be in an arms race with Google;
I need to block ads;
I need a VPN that always has good connection speeds for downloads and not just a high burst speed for a few seconds..
That little list just won't work together. And that last point seems impossible to achieve - certainly with the many VPN services I've tried. I'm currently using Mullvad when I need security but cannot recommend it for speed
I use an OP6 with Android 9, OOS 9.0.1 routed with Madison 17.2
I have Google Pay, Adaway and my permanent VPN with OpenVPN.
I use NordVPN for which I pay but it's reliable and fast, allows multiple connections from my home router and my mobile.
Reliable and without any problems.
akxak said:
On unrooted phones, the VPN adapter is used to reroute traffic. As I use a normal VPN permanently to prohibit carrier deep packet inspection, any adblocker relying on the VPN approach is a nogo for me as Android only supports one VPN connection at a time.
Click to expand...
Click to collapse
Adguard works both in vpn or in proxy mode. But for proxy mode, root is required. Using Adguard for an year ans its always my fav adblocker.
If you're using Magisk, both Magisk and Adaway need to be set to systemless via the settings in each application.
For some reason Adaway 4.x just ignore the restart warning and then just press check for updates again and it'll start properly downloading the host files.
My Adaway has the systemless setting grayed out and not ticked. I'm using Adaway 3.3 from F-Droid which is the latest version, there's no version 4. It's not available on Google Play.
akxak said:
I use NordVPN for which I pay but it's reliable and fast, allows multiple connections from my home router and my mobile.
Reliable and without any problems.
Click to expand...
Click to collapse
Well and good for you. TrustPilot (UK) gives them only 5.8/10. There are some good and bad comments - as to be expected -but this is recent post. It chimes with my own experiences of paid VPN - more promises than delivery.
Extremely slow server
Extremely slow servers. Absolutely horrible app. They make it next to impossible to select a specific server you've used in the past and instead give you an unsorted list of thousands of servers to manually scroll through and try to find the one you want. You can search for a server but if you do it this way you can't add it to favourites.
They advertise as fast for p2p, yet my speeds are the slowest I've ever experienced with a VPN, including those lousy free vpn.
Click to expand...
Click to collapse
I'm aware this is off-topic for Adaway; apologies to OP for possible thread hi-jacking; but if you are in to ad-blocking the next step is VPN
I use the app OpenVPN which gives me more control, speed of servers vary but I am satisfied.

Nord VPN not blocking ads

Guys,
Loving my Nord, only had for a few days and not rooted yet, so using Nord VPN to try and block Chrome ads.
However, despite it working flawlessly on other devices, Nord just won't block ads on any site on my OPN.
I'm using the latest apk from Nords website, and got Cybersec enabled. Any ideas??
Nope but in case you want to try something else, I am using dns66 and that works perfectly. I usually root and use adaway. But I wanted to try a non root solution at least untill I decide to root.
Blokada works as well without root
Thanks both.
I usually root and use Adaway too. But I'm a paid Nord VPN subscriber and really would have expected it to work as advertised, but seems to block absolutely nothing just now.
nstirton said:
Thanks both.
I usually root and use Adaway too. But I'm a paid Nord VPN subscriber and really would have expected it to work as advertised, but seems to block absolutely nothing just now.
Click to expand...
Click to collapse
Have you enabled "private dns" on the phone? It might override the adblocking features of Nord VPN. Usually a lot of adblocking blocks by mapping for instance ads.facebook.com to 127.0.0.1 via DNS. But if you enable private DNS on the phone it's not using Nord VPNs DNS but the private DNS supplier via https.
Thanks for the tip, but no not using a custom DNS.
I guess on other phones I've not relied on the VPNs ad blocking abilities as I've always been rooted using Adaway.
Maybe it's just really bad at blocking ads - ie none at all?!
So, for what it's worth, finally have this fixed....
Whilst I hadn't set up a private / custom DNS, it seems that since I copied over settings from my previous phone (PH-1 R.I.P.) there WAS a redirect in place. I'd only checked DNS within the VPN, not on the phone.
So, VPN active and ads gone!

Best Adblocking solutions for rooted phone, no VPN?

I know the title is rather generic and not strictly related to OP7, but I didn't know where else to post, and as this applies to my OP7, I thought to post here.
OP7
OOS 10.0.7
Rooted, Magisk+TWRP
So far I have been using Blokada to stop ads and it's been a bliss, but the limitation of Android to only run one VPN at a time makes using another VPN a compromise.
Recently I decided to use NordVPN, but as the situation stays now, I must choose between really no ads (Blokada), or NordVPN, but rely on Nord's as filtering which isn't really doing much.
Can you recommend me some reliable Adblocking solutions for rooted phone that can work in parallel with NordVPN and do equally good job as Blokada is doing? I need to block apps across the whole system (apps, websites).
P.S. using YouTube Vanced, so that one is sorted.
Energized magisk module, energized.pro for info on which version best suits you
Adguard dns without any app
Isn't DNS ad-blocking problematic? I've been reading that apps and websites can detect ad- locking DNS and act strangely.
Also, some ISP may not like some DNS... What has been your experience with DNS Adblocking so far?
Hi
I'm using OP7T OOS Beta 7 at the moment. I've been using Blokada for a short time and liked it a lot. But a minor was indeed not being able to combine it with a VPN from another provider. So I tried Blokada VPN. I had the feeling that it was working smoother than the VPN I'm always using. And I like the way they handle accounts. So you could use Blokada and VPN together if you pay for the VPN from Blokada.
So what stopped me using it? Having a long time subscription at NordVPN. I'm not using a vpn much lately. My setup is as follows:
- setup private dns under settings-networks-private dns: dns.adguard.com
- setup Adaway from FDroid (you need root)
- setup NordVPN. Beware to use the apk from the website and not from the Play Store. Only the apk from the website has working cybersec functionality. It can be used together with Adaway.
I've no problems using a dns server that blocks ads and malware. Neither do I have problems using hosts file based blocking like Adaway. Besides that I'm using browsers like Privacy Browser, Firefox nightly, Bromite and ungoogled chromium. And I try not to use apps with ads.
SvenC said:
- setup private dns under settings-networks-private dns: dns.adguard.com
- setup Adaway from FDroid (you need root)
- setup NordVPN. Beware to use the apk from the website and not from the Play Store. Only the apk from the website has working cybersec functionality. It can be used together with Adaway.
Click to expand...
Click to collapse
Thanks, I made the same setup... Seems less strict compared to Blokada, but this I am sure is just a matter of hosts list in adaway.
Do you recommend any hosts in particular besides the ones already in Adaway?
Also, what kind of apps do you split tunnel in NordVPN? Or no need? Everything working as it should?
derei said:
Thanks, I made the same setup... Seems less strict compared to Blokada, but this I am sure is just a matter of hosts list in adaway.
Do you recommend any hosts in particular besides the ones already in Adaway?
Also, what kind of apps do you split tunnel in NordVPN? Or no need? Everything working as it should?
Click to expand...
Click to collapse
Be sure to update hosts file in Adaway regularly. I haven't changed any sources in Adaway. Just the standard setup. It blocks system wide and I don't want it to be too strict. Maybe I want to reach a domain sometimes on some site without hassle. You can start up "dns log"in Adaway and then just use your phone like you always do. It then monitors every request. After a while you can go back to Adaway to view which requests occurred. From there you can block domains that were allowed. Or allow domains that were blocked.
I'm not using vpn a lot lately as I'm in my home country. I use it especially when I'm abroad in less privacy conscious countries. That's why I haven't split anything. But I would just it more, I would split apps like Signal private messenger which are end to end encrypted, and apps that don't seem to work well going through the vpn tunnel.
If you are really concerned about your privacy/ISP, then you should setup VPN always on, or force apps to use vpn tunnel by using a firewall. Although opinions differ on this. To me that's overkill anyway. Do you have apps still showing ads? Or do you mean ads while browsing websites?
SvenC said:
Do you have apps still showing ads? Or do you mean ads while browsing websites?
Click to expand...
Click to collapse
Yes, some apps are still showing placeholders. Didn't check all apps...but with Blokada I didn't even have the placeholders. Isn't a big nuisance, but if I can find a solution for it, for the better.
As for vpn usage... i just made some network speed tests... what do you see... it was better over the vpn. For some reason my isp was throttling my mobile (weird). So, I decided to allow NordVPN to always connect to the fastest server.
About tunneling, I was interested if any app misbehaves when on vpn (for example Netflix, or banking apps, if you personally encountered some issue).
derei said:
Yes, some apps are still showing placeholders. Didn't check all apps...but with Blokada I didn't even have the placeholders. Isn't a big nuisance, but if I can find a solution for it, for the better.
As for vpn usage... i just made some network speed tests... what do you see... it was better over the vpn. For some reason my isp was throttling my mobile (weird). So, I decided to allow NordVPN to always connect to the fastest server.
About tunneling, I was interested if any app misbehaves when on vpn (for example Netflix, or banking apps, if you personally encountered some issue).
Click to expand...
Click to collapse
I keep apps with ads at a minimum, so probably that's why I haven't any problems like that. I remember having problems setting up Payconiq and Transferwise while on vpn. After finishing the setup, only Transferwise still gives problems while on vpn. I don't have streaming or social apps besides Telegram and Keybase.
That said, if I didn't have a subscription from NordVPN, I would use Blokada and pay for its vpn. Everything in one app. But in case speed is important, probably Nord is a better option.
derei said:
Isn't DNS ad-blocking problematic? I've been reading that apps and websites can detect ad- locking DNS and act strangely.
Also, some ISP may not like some DNS... What has been your experience with DNS Adblocking so far?
Click to expand...
Click to collapse
You may have the same problems you have with VPN apps, I have not had any problems for the moment and I have been using dns adguard for some time ... once there was a problem in the server and they crashed but just set '' automatic dns' 'until the problem is solved. In any case, if you don't have root the only way is vpn or dns
I tried the Magisk module Energized but couldn't make it work. I got an error that it was not compatible although I had systemless hosts installed. Otherwise it seemed promising.
I'm testing another app now: Nebulo. At first sight I like it very much. But don't download it from Google Play cause that's a very limited version. Downloading it from Aurora Droid seems the easiest way. It's like Blokada, but I like it more. You can add packages to block ads. And the choice is large. You have a lot of dns servers to choose from. You can test the speed of the servers. Not just a ping test, but a revolution test. You can use cache to avoid sending the same dns requests over and over to the server; to speed up browsing. And a lot of other settings. Worth taking a look at.
Tried Magisk module energized.pro module on another ROM with success now. Using private DNS settings in android combined with that module. My favorite setup at the moment.

Categories

Resources