summaryrefslogtreecommitdiff
path: root/sysproxy.py
diff options
context:
space:
mode:
Diffstat (limited to 'sysproxy.py')
-rw-r--r--sysproxy.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/sysproxy.py b/sysproxy.py
new file mode 100644
index 0000000..81867ad
--- /dev/null
+++ b/sysproxy.py
@@ -0,0 +1,7 @@
1import urllib.request
2
3
4def configure_system_proxy():
5 proxy = urllib.request.ProxyHandler(urllib.request.getproxies())
6 opener = urllib.request.build_opener(proxy)
7 urllib.request.install_opener(opener)