Update toriptables2.py
This commit is contained in:
parent
a714f75db1
commit
fda5a9873e
1 changed files with 1 additions and 1 deletions
|
@ -44,6 +44,7 @@ DNSPort 53
|
||||||
def restart_tor():
|
def restart_tor():
|
||||||
fnull = open(devnull, 'w')
|
fnull = open(devnull, 'w')
|
||||||
call(["service", "tor", "restart"], stdout=fnull, stderr=fnull)
|
call(["service", "tor", "restart"], stdout=fnull, stderr=fnull)
|
||||||
|
print(" {0}".format("[\033[92m+\033[0m] Anonymizer \033[92mON\033[0m"))
|
||||||
|
|
||||||
call(["iptables", "-t", "nat", "-A", "OUTPUT", "-m", "owner", "--uid-owner",
|
call(["iptables", "-t", "nat", "-A", "OUTPUT", "-m", "owner", "--uid-owner",
|
||||||
"%s" % self.tor_uid, "-j", "RETURN"])
|
"%s" % self.tor_uid, "-j", "RETURN"])
|
||||||
|
@ -88,7 +89,6 @@ if __name__ == '__main__':
|
||||||
|
|
||||||
if args.load:
|
if args.load:
|
||||||
load_tables.load_iptables_rules()
|
load_tables.load_iptables_rules()
|
||||||
print(" {0}".format("[\033[92m+\033[0m] Anonymizer \033[92mON\033[0m"))
|
|
||||||
elif args.flush:
|
elif args.flush:
|
||||||
load_tables.flush_iptables_rules()
|
load_tables.flush_iptables_rules()
|
||||||
print(" {0}".format("[\033[93m!\033[0m] Anonymizer \033[91mOFF\033[0m"))
|
print(" {0}".format("[\033[93m!\033[0m] Anonymizer \033[91mOFF\033[0m"))
|
||||||
|
|
Loading…
Reference in a new issue