carsonyl / pypac

Find and use proxy auto-config (PAC) files with Python and Requests.
https://pypac.readthedocs.io
Apache License 2.0
71 stars 19 forks source link

Support keywords: HTTP, HTTPS, SOCKS4, SOCKS5 #41

Closed carsonyl closed 3 years ago

carsonyl commented 5 years ago

Currently, the following keywords are recognized from the PAC: DIRECT PROXY, SOCKS.

Mozilla's PAC file doc says Firefox supports more keywords: HTTP, HTTPS, SOCKS4, SOCKS5.

Proposed interpretation:

The SOCKS keyword is already assumed by default to be socks5://.

ibarrond commented 5 years ago

+1! HTTPS is a keyword I'm looking forward to have. Any ETA?

SeyfSV commented 5 years ago

Hi @ibarrond, I added HTTPS in #44, but there is issue with urllib3 library (you can try to fix it with this patch ). Also I had issue with PAC file provider, that does not return HTTPS for default User-Agent. It can be fixed by assigning Firefox User-Agent for example (look)