Created
July 1, 2020 09:21
-
-
Save ZaWertun/67e86106d503380d45ddb2ac80962c49 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -r -U3 sshuttle-1.0.1.orig/sshuttle/server.py sshuttle-1.0.1/sshuttle/server.py | |
--- sshuttle-1.0.1.orig/sshuttle/server.py 2020-06-05 00:43:00.000000000 +0300 | |
+++ sshuttle-1.0.1/sshuttle/server.py 2020-07-01 12:18:01.086964478 +0300 | |
@@ -6,7 +6,7 @@ | |
import sys | |
import os | |
import platform | |
-from shutil import which | |
+import shutil | |
import sshuttle.ssnet as ssnet | |
import sshuttle.helpers as helpers | |
@@ -107,9 +107,9 @@ | |
def list_routes(): | |
- if which('ip'): | |
+ if shutil.which('ip'): | |
routes = _list_routes(['ip', 'route'], _route_iproute) | |
- elif which('netstat'): | |
+ elif shutil.which('netstat'): | |
routes = _list_routes(['netstat', '-rn'], _route_netstat) | |
else: | |
log('WARNING: Neither ip nor netstat were found on the server.\n') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment