Merge pull request #537 from skuhl/add-version

Include sshuttle version in verbose output.
This commit is contained in:
Brian May 2020-10-10 11:18:13 +11:00 committed by GitHub
commit c1cc3911df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,6 +17,7 @@ from sshuttle.ssnet import SockWrapper, Handler, Proxy, Mux, MuxWrapper
from sshuttle.helpers import log, debug1, debug2, debug3, Fatal, islocal, \ from sshuttle.helpers import log, debug1, debug2, debug3, Fatal, islocal, \
resolvconf_nameservers resolvconf_nameservers
from sshuttle.methods import get_method, Features from sshuttle.methods import get_method, Features
from sshuttle import __version__
try: try:
from pwd import getpwnam from pwd import getpwnam
except ImportError: except ImportError:
@ -581,7 +582,7 @@ def main(listenip_v6, listenip_v4,
except Fatal as e: except Fatal as e:
log("%s\n" % e) log("%s\n" % e)
return 5 return 5
debug1('Starting sshuttle proxy.\n') debug1('Starting sshuttle proxy (version %s).\n' % __version__)
fw = FirewallClient(method_name, sudo_pythonpath) fw = FirewallClient(method_name, sudo_pythonpath)