Custom "pre"/"down" scripts run for hop tunnels (h != 1 compares string to int) #81
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
In
ovpn(), both remaining guards read"bypass" not in self.server_dict and h != 1— buthis a string ("0"/"1"/"2"from the server dict), soh != 1is always true and the provider's custom "pre" and "down" scripts also fire for hop connects: "pre" before the hop even dials, "down" again when the hop tears down.The same bug in
tunnel_upran the "up" script on hop connects; #79 fixed that one in passing (the guard is nowrole == "main"). The twoovpn()sites were deliberately left untouched there to keep scope.Fix: same shape — guard on
role == "main"instead of theh/dict combination.