You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
IP addresses mismatch in --noproxy and related env variable (in 7.86.0) #9813
cd /tmp
touch testfile
php -S 127.0.0.1:8000 &
# anything where there is no proxy will do
export http_proxy=http://127.0.0.5:3128
curl -vv -o /dev/null http://127.0.0.1:8000/testfile --noproxy "127.0.0.1"
curl -vv -o /dev/null http://127.0.0.1:8000/testfile --noproxy "127.0.0.1,localhost"
I expected the following
both curls downloading the file and not reaching out to the proxy, but if "127.0.0.1" is not the last part of the string ... it will not work
This came with 7.86.0 and showed up in a CI pipline testing multiple "modern distros". It came with "alpine:edge" and "archlinux:latest" at the same time. Both switched to that new curl yesterday.
operating system
docker containers of "alpine:edge" and "archlinux:latest" ... or Linux with the latest curl
Same issue, other applications using curl libs also affected. Is there a temporary workaround? Need to no-proxy on .ts.net, what should I be using instead?
changed the title [-]latest release is problems in handling `--noproxy` and related env variables[/-][+]7.86.0 problems in handling `--noproxy` and related env variable[/+]on Oct 27, 2022
I would say that is a regression which might even call for a new release rather soon. Nice to see there is a workaround. But if you ever had the honors to having to work with proxies and related env variables, you will know how horrible all of that is.
The variables are used by many tools and they all have their own implementation on dealing with them. While curl is an important player in that game it is not the only one. Just think multiple versions of curl all hoping to use the same NO_PROXY.
In my example i pointed it out via cmdline --noproxy but the env variables are the real deal, that is where users have to find values that work for all their tools and have the same effect in all of them. That is in fact impossible ... but any tool should try its best.
Thanks for that quick fix but there is more to it. I tried to make that workaround get a whole complex pipeline green where proxies are needed for several things. The IP just being one of several essential parts of no_proxy.
changed the title [-]7.86.0 problems in handling `--noproxy` and related env variable[/-][+]IP addresses mismatch in `--noproxy` and related env variable (in 7.86.0)[/+]on Oct 28, 2022
Sorry for the direct maintainer SPAM, but i think this one is important and easy to miss. So i did dig out some names of distros and people to notify all at once, not following individual workflows. Please do not ask me to open a bug, i might do that for debian but not the rest.
Nice catch, i did not know about that third one yet. Will try to get that into gentoo as well. But it seems a little less severe so maybe people can wait for the next release.
Activity
bagder commentedon Oct 27, 2022
Introduced in #9775 no doubt
noproxy: also match with adjacent comma
DhruvaSambrani commentedon Oct 27, 2022
Same issue, other applications using curl libs also affected. Is there a temporary workaround? Need to no-proxy on
.ts.net, what should I be using instead?bagder commentedon Oct 27, 2022
Work-around: if you append
/32on the right side of the127.0.0.1in the noproxy string it should work. Like:DhruvaSambrani commentedon Oct 27, 2022
Work-around works. I assume this would need to be done on all ip addresses?
bagder commentedon Oct 27, 2022
Yes, and you can now use proper CIDR notation so you can match a larger network in a single string, like
127.0.0.1/8.[-]latest release is problems in handling `--noproxy` and related env variables[/-][+]7.86.0 problems in handling `--noproxy` and related env variable[/+]henning-schild commentedon Oct 27, 2022
I would say that is a regression which might even call for a new release rather soon. Nice to see there is a workaround. But if you ever had the honors to having to work with proxies and related env variables, you will know how horrible all of that is.
The variables are used by many tools and they all have their own implementation on dealing with them. While curl is an important player in that game it is not the only one. Just think multiple versions of curl all hoping to use the same
NO_PROXY.In my example i pointed it out via cmdline
--noproxybut the env variables are the real deal, that is where users have to find values that work for all their tools and have the same effect in all of them. That is in fact impossible ... but any tool should try its best.bagder commentedon Oct 27, 2022
We will certainly take this into consideration.
henning-schild commentedon Oct 28, 2022
Thanks for that quick fix but there is more to it. I tried to make that workaround get a whole complex pipeline green where proxies are needed for several things. The IP just being one of several essential parts of
no_proxy.And again it tries to go via that proxy where it should not.
bagder commentedon Oct 28, 2022
Not the same problem as first reported though.
bagder commentedon Oct 28, 2022
filed #9821 for the new one
[-]7.86.0 problems in handling `--noproxy` and related env variable[/-][+]IP addresses mismatch in `--noproxy` and related env variable (in 7.86.0)[/+]henning-schild commentedon Oct 28, 2022
Maybe yes, one could argue but it does not matter. Thanks for taking this into a separate issue.
henning-schild commentedon Nov 14, 2022
arch was not notfied so let my try with a ping @eworm-de
alpine is also affected @ncopa
opensuse tumbleweed is now also affected by both issues, also trying a ping @pmgdeb
debian bookworm is affected ... ping @samueloph
fedora and gentoo have backported the patches for this one and #9821
https://github.com/gentoo/gentoo/blob/master/net-misc/curl/curl-7.86.0-r1.ebuild#L98
https://src.fedoraproject.org/rpms/curl/c/394bdcb95657341453d63fe508d549572fee9083
Sorry for the direct maintainer SPAM, but i think this one is important and easy to miss. So i did dig out some names of distros and people to notify all at once, not following individual workflows. Please do not ask me to open a bug, i might do that for debian but not the rest.
eworm-de commentedon Nov 14, 2022
Should be fixed in
curl 7.86.0-4... I hope I found all relevant commits.samueloph commentedon Nov 15, 2022
Pushed the fixes to the Debian package at
7.86.0-2.The following commits were picked:
b830f9b
efc286b
b1953c1
Thank you for the heads up @henning-schild :)
henning-schild commentedon Nov 16, 2022
#9842
Nice catch, i did not know about that third one yet. Will try to get that into gentoo as well. But it seems a little less severe so maybe people can wait for the next release.
fbezdeka commentedon Nov 29, 2022
@kdudka : Seems Fedora rawhide is missing b830f9b and b1953c1 to fully solve this issue.
I also opened https://bugzilla.redhat.com/show_bug.cgi?id=2149224 to track this issue.
cfilters:Curl_conn_get_select_socks: use the first non-connected filter
d/patches: Backport two upstream patches to fix noproxy option