Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed proxy spec parsing buglets to allow SSL client cert specs to work

commit f957ce9defedcc4c51ffe976051e671eebb6bd7f 1 parent e2d118b
@BjarniRunar BjarniRunar authored
Showing with 6 additions and 3 deletions.
  1. +1 −1  setup.py
  2. +5 −2 sockschain/__init__.py
View
2  setup.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python
from setuptools import setup
-VERSION = "2.0.11"
+VERSION = "2.0.12"
setup(
name = "SocksipyChain",
View
7 sockschain/__init__.py
@@ -369,9 +369,12 @@ def parseproxy(arg):
# into a proxy specification array. It lets people omit stuff.
if '!' in arg:
# Prefer ! to :, because it works with IPv6 addresses.
- args = arg.replace('/', '').split('!')
+ args = arg.split('!')
else:
- args = arg.replace('/', '').split(':')
+ # This is a bit messier to accept common URL syntax
+ if arg.endswith('/'):
+ arg = arg[:-1]
+ args = arg.replace('://', ':').replace('/:', ':').split(':')
args[0] = PROXY_TYPES[args[0] or 'http']
if (len(args) in (3, 4, 5)) and ('@' in args[2]):
Please sign in to comment.
Something went wrong with that request. Please try again.