-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix: Proxy type kCFProxyTypeHTTPS expects to be HTTP proxy on macOS #48
Conversation
442a850
to
535ba65
Compare
Codecov Report
@@ Coverage Diff @@
## master #48 +/- ##
==========================================
+ Coverage 56.55% 56.61% +0.06%
==========================================
Files 53 53
Lines 4601 4608 +7
Branches 1060 1063 +3
==========================================
+ Hits 2602 2609 +7
+ Misses 1313 1310 -3
- Partials 686 689 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 2 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
518022e
to
f63d0d7
Compare
else if (CFEqual(proxy_type, kCFProxyTypeHTTP)) | ||
scheme = "http://"; | ||
else if (CFEqual(proxy_type, kCFProxyTypeHTTPS)) | ||
// "HTTPS Proxy" on macOS means "use CONNENCT verb for a https:// URL", the proxy still should be an HTTP proxy. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this seems to suggest that macOS does not support HTTPS
directive from PAC file. However, an HTTPS proxy can still probably be manually configured in settings dialog?
https://support.apple.com/guide/mac-help/change-proxy-settings-on-mac-mchlp2591/mac
Is that your take as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IDK, it is first time mentioned in macOS Montgomery, but we are targeting macOS 10.13. It may change the behavior if we change the target. If it still returns CFProxyTypeHTTPS
for the PROXY
directive, it is useless for us.
Just looks like some lint test failing now, otherwise gtg. |
I will make a new proxyres release/tag after this is merged so you can update to it in the client. |
f63d0d7
to
91fe30d
Compare
Also fixes possible unsigned integer overflow
max_len - list_len
resulting in a huge buffer length passed to string functions,