gfwlist2dnsmasq 介绍
gfwlist2dnsmasq 只是另一个脚本使用gfwlist自动生成的 dnsmasq ipset 规则
通知 : 使用 python2,不要使用 python3
使用:
Modify gfwlist2dnsmasq.py:
改变你的DNS服务器的IP&端口:
mydnsip = '127.0.0.1' mydnsport = '5353'
改变ipset名称:
ipsetname = 'gfwlist'
保存规则文件的路径:
outfile = './dnsmasq_list.conf'
在这里添加您自己的额外域。 在一条线一个域。 例如:
EX_DOMAIN=[ \
'.google.com’, \
'.google.com.hk’, \
'.google.com.tw’, \
'.google.com.sg’, \
‘.google.co.jp’, \
'.blogspot.com’, \
‘.blogspot.sg’, \
‘.blogspot.hk’, \
‘.blogspot.jp’, \
'.gvt1.com’, \
'.gvt2.com’, \
'.gvt3.com’, \
'.1e100.net’, \
‘.blogspot.tw’ \
]
然后运行 gfwlist2dnsmasq.py:
python gfwlist2dnsmasq.py
如果你不想来生成自己的规则,你可以下载规则文件:
https://github.com/cokebar/gfwlist2dnsmasq/releases
gfwlist2dnsmasq 官网
https://github.com/cokebar/gfwlist2dnsmasq
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。