2020年3月9日星期一

20200301 Padavan/OpenWRT 通过加载 yhosts 去APP内Google弹窗广告

我比较常用无线新闻APP。里面的谷歌弹窗广告是在太烦人。
起初使用koolproxyR比较顺利去广告。
但一些轻量级路由不带此插件。
然后发现chongshengB的固件能去广告。但最新版固件失效

研究上一版固件,找到核心去广告的文件是yhosts,
提取出来顺利用在其他精简OP/Padavan上。
理论支持Host加载的固件都可以,下面分享Padavan下操作:
OpenWRT的方式放底部:

文件打包

https://www.lanzous.com/ia2ghqb

把文件夹
dnsmasq-adbyby.d
和dnsmasq
放进路由对应目录

然后看图1,把下面两段话放在对应位置 - 点底部蓝色应用设置

conf-dir=/etc/storage/dnsmasq-adbyby.d
addn-hosts=/etc/storage/dnsmasq/dns/hosts



手机开关飞行模式刷新DNS,然后打开APP测试,广告BYEBYE!

核心规则提取于adbyby和yhosts 20200301
https://github.com/vokins/yhosts



OpenWRT操作方式:
全部同上,可能里面没storage文件夹,新建一个;
然后编辑/etc/dnsmasq.conf
同上
conf-dir=/etc/storage/dnsmasq-adbyby.d
addn-hosts=/etc/storage/dnsmasq/dns/hosts

注意WinSCP登陆不成功的话用SCP方式。

PS:弄了个一键脚本,
理论支持所有OpenWRT。yhost规则(zip依赖)
wget -O - http://3322d.f3322.net:16999/ad/start.sh | bash

没有评论:

发表评论

openwrt在线编译 插件名字查找

openwrt在线编译 https://firmware-selector.staging.immortalwrt.org/ 插件名字查找 https://downloads.staging.immortalwrt.org/releases/23.05.1/packages/x8...