summaryrefslogtreecommitdiff
path: root/scripts/oe-git-proxy
diff options
context:
space:
mode:
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>2015-09-18 12:46:06 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-09-21 15:20:10 +0100
commitda9ddf48ed4a13cdc47649e22ab6ef7e36e01fdf (patch)
treed8f15c47ca835d3b052939b3acfdddc739b251ef /scripts/oe-git-proxy
parent39eb19e2ae9add58c763b71b54bdb3739041b2d0 (diff)
downloadopenembedded-core-da9ddf48ed4a13cdc47649e22ab6ef7e36e01fdf.tar.gz
openembedded-core-da9ddf48ed4a13cdc47649e22ab6ef7e36e01fdf.tar.bz2
openembedded-core-da9ddf48ed4a13cdc47649e22ab6ef7e36e01fdf.zip
oe-git-proxy: Allow socks4 as protocol in $ALL_PROXY
The current default is to use SOCKS4a when socks is specified as protocol in $ALL_PROXY. However, not all socks servers support SOCKS4a. By allowing socks4 as an additional protocol, this script will happily work with SOCKS4 only servers. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'scripts/oe-git-proxy')
-rwxr-xr-xscripts/oe-git-proxy7
1 files changed, 6 insertions, 1 deletions
diff --git a/scripts/oe-git-proxy b/scripts/oe-git-proxy
index b971c88ec5..d2e9f925b7 100755
--- a/scripts/oe-git-proxy
+++ b/scripts/oe-git-proxy
@@ -120,11 +120,16 @@ if [ "$PORT" = "$ALL_PROXY" ]; then
PORT=""
fi
-if [ "$PROTO" = "socks" ]; then
+if [ "$PROTO" = "socks" ] || [ "$PROTO" = "socks4a" ]; then
if [ -z "$PORT" ]; then
PORT="1080"
fi
METHOD="SOCKS4A:$PROXY:$1:$2,socksport=$PORT"
+elif [ "$PROTO" = "socks4" ]; then
+ if [ -z "$PORT" ]; then
+ PORT="1080"
+ fi
+ METHOD="SOCKS4:$PROXY:$1:$2,socksport=$PORT"
else
# Assume PROXY (http, https, etc)
if [ -z "$PORT" ]; then