diff options
author | samschott <sam.schott@outlook.com> | 2023-05-09 08:24:29 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-09 08:24:29 (GMT) |
commit | 9a9b176eb7e052af84c01c0cfb3231e51f980f2d (patch) | |
tree | 4a2d96d291e99f462bb49bc138b15d5401c916ad /Modules/_scproxy.c | |
parent | bf89d4283a28dd00836f2c312a9255f543f93fc7 (diff) | |
download | cpython-9a9b176eb7e052af84c01c0cfb3231e51f980f2d.zip cpython-9a9b176eb7e052af84c01c0cfb3231e51f980f2d.tar.gz cpython-9a9b176eb7e052af84c01c0cfb3231e51f980f2d.tar.bz2 |
gh-104180: Read SOCKS proxies from macOS System Configuration (#104181)
read SOCKS proxies from macOS System Configuration in ``urllib.request``.
---------
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
Diffstat (limited to 'Modules/_scproxy.c')
-rw-r--r-- | Modules/_scproxy.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/_scproxy.c b/Modules/_scproxy.c index e669180..0df0324 100644 --- a/Modules/_scproxy.c +++ b/Modules/_scproxy.c @@ -206,6 +206,11 @@ get_proxies(PyObject* Py_UNUSED(mod), PyObject *Py_UNUSED(ignored)) kSCPropNetProxiesGopherProxy, kSCPropNetProxiesGopherPort); if (r == -1) goto error; + r = set_proxy(result, "socks", proxyDict, + kSCPropNetProxiesSOCKSEnable, + kSCPropNetProxiesSOCKSProxy, + kSCPropNetProxiesSOCKSPort); + if (r == -1) goto error; CFRelease(proxyDict); return result; |