Page MenuHomeFreeBSD

fetch(3); Add support of HTTPS_PROXY/https_proxy environment variables
Needs ReviewPublic

Authored by yasu on Jan 31 2021, 5:15 PM.
Tags
None
Referenced Files
Unknown Object (File)
Nov 8 2023, 3:33 PM
Unknown Object (File)
Oct 25 2023, 4:20 PM
Unknown Object (File)
Oct 7 2023, 2:23 PM
Unknown Object (File)
Oct 6 2023, 8:34 AM
Unknown Object (File)
Aug 6 2023, 8:12 AM
Unknown Object (File)
Jun 22 2023, 6:19 PM
Unknown Object (File)
Mar 4 2023, 9:20 PM
Unknown Object (File)
Feb 15 2023, 6:16 AM
Subscribers

Details

Reviewers
des
Group Reviewers
manpages
Summary

Add support of HTTPS_PROXY/https_proxy environment variables. They
works similar to FTP_PROXY/ftp_proxy environment variables for FTP
scheme. That is, if scheme of request URL is "https" fetch(3) checks
if following environment variables are set in this order.

  1. HTTPS_PROXY
  2. https_proxy
  3. HTTP_PROXY
  4. http_proxy

And the value of first one set is used as setting of proxy for https.

Test Plan

It isn't possbile test it with unit test because web server and proxy
are required to test. I've been using this patch with -CURRENT and
it seems to work fine at least for me.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 36639
Build 33528: arc lint + arc unit

Event Timeline

yasu requested review of this revision.Jan 31 2021, 5:15 PM
crees added a subscriber: crees.

Couple of minor nits-- if they're fixed (or if HTTP is correct above) then fine for manpages.

.Dd bump on commit :)

lib/libfetch/fetch.3
659

HTTP or HTTPS?

868

We use the serial comma.