hezhijie0327 / GFWList2AGH

Generate diversion list for AdGuard Home and other softwares
228 stars 70 forks source link

有什么办法去走,你写的脚本,你清楚。我怕写错脚本 #18

Closed Potterli20 closed 3 years ago

Potterli20 commented 3 years ago

图片

hezhijie0327 commented 3 years ago

意思是添加新域名,让其走 doh.pubdns.alidns.com 是吗?

Potterli20 commented 3 years ago

意思是添加新域名,让其走 doh.pubdns.alidns.com 是吗?

是的,就是把doh.pub和的dns.alidns.com去走,只留的dns.google,黑名单分流

hezhijie0327 commented 3 years ago
  1. 国内域名添加入:data_cnacc.txt -> 走 doh.pub dns.alidns.com
  2. 国外域名添加入:data_gfwlist.txt -> 走 doh.opendns.com dns.google
  3. 语法见文件内描述
Potterli20 commented 3 years ago

意思是添加新域名,让其走 doh.pubdns.alidns.com 是吗?

我在我的服务器把黑名单分流和白名单分流合并了,然后出现一写问题

hezhijie0327 commented 3 years ago

我在我的服务器把黑名单分流和白名单分流合并了,然后出现一写问题

如果是 AGH 的话,默认构建时就存在黑白名单合并的列表:非 split.txt 结尾文件,如 blacklist_full.txt

Potterli20 commented 3 years ago

我在我的服务器把黑名单分流和白名单分流合并了,然后出现一写问题

如果是 AGH 的话,默认构建时就存在黑白名单合并的列表:非 split.txt 结尾文件,如 blacklist_full.txt

http://dns.trli.club/dns/dns-txt/gfwlist2adguardhome/domain_full.txt ,这个就是我合并分流文件

hezhijie0327 commented 3 years ago
  1. 如果只是需要修改上游的话,只需修改 release.shdomestic_dnsforeign_dns 键值
  2. 上游过多会导致规则文件变大,构建时间变长
  3. AGH 中 # 为保留键值,即意为使用默认上游服务器
hezhijie0327 commented 3 years ago

我根据你配置文件中的配置,生成了此文件 blacklist_full.txt

Potterli20 commented 3 years ago

图片 我就是这样合并的

hezhijie0327 commented 3 years ago
  1. 不需要合并规则,非split文件已经合并好了,split是为了特定人群需求才出的单独列表
  2. split 文件(以黑名单为例)结构为:默认上游 DNS 服务器(国内DNS) + 黑名单规则(国外DNS)
  3. split 文件(以黑名单为例)结构为:默认上游 DNS 服务器(国内) + 白名单规则(#)+ 黑名单规则(国外DNS)
  4. # 意为使用默认上游 DNS 服务器
Potterli20 commented 3 years ago
1. 不需要合并规则,非`split`文件已经合并好了,`split`是为了特定人群需求才出的单独列表

2. `split` 文件([以黑名单为例](https://source.zhijie.online/GFWList2AGH/main/gfwlist2adguardhome/blacklist_full_split.txt))结构为:默认上游 DNS 服务器(国内DNS) +  黑名单规则(国外DNS)

3. 非 `split` 文件([以黑名单为例](https://source.zhijie.online/GFWList2AGH/main/gfwlist2adguardhome/blacklist_full.txt))结构为:默认上游 DNS 服务器(国内) + 白名单规则(#)+ 黑名单规则(国外DNS)

4. `#` 意为使用默认上游 DNS 服务器

那有什么办法不使用默认上游 DNS 服务器,就是只有 黑名单规则(国外DNS)+ 白名单规则(国内dns)

hezhijie0327 commented 3 years ago

理论上屏蔽掉 GenerateDefaultUpstream 即可

Potterli20 commented 3 years ago

到时候看看,你的test的脚本