mirror of
https://github.com/gSpotx2f/ruantiblock_openwrt.git
synced 2026-05-13 14:10:59 +00:00
ruantiblock: Minor fixes.
autoinstall.sh: Dnsmasq rebind protection for .onion.
This commit is contained in:
@@ -222,6 +222,9 @@ InstallTorConfig() {
|
||||
_if_lan="eth0"
|
||||
fi
|
||||
$UCI_CMD set ruantiblock.config.if_lan="$_if_lan"
|
||||
# dnsmasq rebind protection
|
||||
$UCI_CMD set dhcp.@dnsmasq[0].rebind_localhost='1'
|
||||
$UCI_CMD set dhcp.@dnsmasq[0].rebind_domain='.onion'
|
||||
$UCI_CMD commit
|
||||
}
|
||||
|
||||
|
||||
BIN
Binary file not shown.
@@ -446,7 +446,7 @@ GetDataFiles() {
|
||||
printf "\n" >> "$DNSMASQ_DATA_FILE"
|
||||
else
|
||||
### Запись для .onion в $DNSMASQ_DATA_FILE
|
||||
printf "server=/onion/%s\nipset=/onion/%s\n" "${ONION_DNS_ADDR}" "${IPSET_ONION}" >> "$DNSMASQ_DATA_FILE"
|
||||
printf "server=/.onion/%s\nipset=/.onion/%s\n" "${ONION_DNS_ADDR}" "${IPSET_ONION}" >> "$DNSMASQ_DATA_FILE"
|
||||
fi
|
||||
rm -f "$UPDATE_PID_FILE"
|
||||
return $_return_code
|
||||
|
||||
+2
-4
@@ -1,12 +1,10 @@
|
||||
User admin
|
||||
PidFile /var/run/tor.pid
|
||||
User tor
|
||||
DataDirectory /var/lib/tor
|
||||
VirtualAddrNetwork 10.254.0.0/16
|
||||
AutomapHostsOnResolve 1
|
||||
TransPort 192.168.1.1:9040
|
||||
TransPort 127.0.0.1:9040
|
||||
DNSPort 9053
|
||||
DNSListenAddress 127.0.0.1
|
||||
DNSPort 127.0.0.1:9053
|
||||
#SOCKSPort 192.168.1.1:9050 # Tor socks-proxy
|
||||
GeoIPFile /usr/share/tor/geoip
|
||||
GeoIPv6File /usr/share/tor/geoip6
|
||||
|
||||
Reference in New Issue
Block a user