Set started_by_sshuttle False after disabling pf

We set it to true when we enable pf, but do not set it back to False
after disabling. When using IPv4 and IPv6 we end up trying to disable
twice which procudes an error while undoing changes in FreeBSD 11.
This commit is contained in:
vieira 2016-11-01 21:01:56 +00:00 committed by Brian May
parent 0e52cce9d1
commit e39c4afce0

View File

@ -64,6 +64,7 @@ class Generic(object):
pfctl('-a %s -F all' % anchor)
if _pf_context['started_by_sshuttle']:
pfctl('-d')
_pf_context['started_by_sshuttle'] = False
def query_nat(self, family, proto, src_ip, src_port, dst_ip, dst_port):
[proto, family, src_port, dst_port] = [