[Bug 225434] [patch] Treat set but empty environment variables as unset in /usr/libexec/phttpget

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Jan 25 23:10:31 UTC 2018


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=225434

--- Comment #3 from Conrad Meyer <cem at freebsd.org> ---
(In reply to Vasil Dimov from comment #2)
> Conrad, you got it wrong, just "http_proxy" needs to be set to an empty
> string to trigger the bug (with HTTP_PROXY being irrelevant).

Did I?  The forum link seems to suggest the opposite:

> The problem will occur if you set http_proxy variable instead of setting
> both HTTP_PROXY and HTTP_PROXY_AUTH.

And the code check HTTP_PROXY first.

> Because it may contain http_proxy=${http_proxy:-""} which is a common idiom.

Citation needed?  That line seems wrong for most/all uses.  It explicitly
replaces unset variable with an empty string version, which causes this whole
mess.

By the way, I don't think the user agent portion of the proposed change makes
sense.  An empty string user agent may be desirable, even if non-conformant.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list