mirror of
https://github.com/haad/proxychains.git
synced 2026-09-14 11:05:48 +05:00
Allow user to override default DNS server
Implements support for an environmnet variable (PROXY_DNS_SERVER) whereby the user can specify a DNS server. If not set defaults to the hardcoded OpenDNS default.
This commit is contained in:
parent
14e15aa2c1
commit
98e9326534
10
README.adoc
10
README.adoc
@ -160,3 +160,13 @@ $ PROXYCHAINS_SOCKS5=4321 proxychains zsh
|
||||
|
||||
in this example, it will run a shell with all traffic proxied through
|
||||
OpenSSH's "dynamic proxy" (SOCKS5 proxy) on localhost port 4321.
|
||||
|
||||
=== Usage Example:
|
||||
|
||||
----
|
||||
$ export PROXY_DNS_SERVER=8.8.8.8
|
||||
$ proxychains telnet targethost.com
|
||||
----
|
||||
|
||||
in this example, it will telnet to targethost.com using the 8.8.8.8
|
||||
nameserver supplied by the user through the PROXY_DNS_SERVER
|
||||
|
||||
@ -2,7 +2,12 @@
|
||||
# This script is called by proxychains to resolve DNS names
|
||||
|
||||
# DNS server used to resolve names
|
||||
DNS_SERVER=208.67.222.222
|
||||
|
||||
if [[ -z "$PROXY_DNS_SERVER" ]] ; then
|
||||
DNS_SERVER=208.67.222.222 # OpenDNS
|
||||
else
|
||||
DNS_SERVER=$PROXY_DNS_SERVER
|
||||
fi
|
||||
|
||||
|
||||
if [ $# = 0 ] ; then
|
||||
|
||||
Loading…
Reference in New Issue
Block a user