CVE-2015-3144
The fix_hostname function in cURL and libcurl 7.37.0 through 7.41.0 does not properly calculate an index, which allows remote attackers to cause a denial of service (out-of-bounds read or write and crash) or possibly have other unspecified impact via a zero-length host name, as demonstrated by "http://:80" and ":80."
02 / AFFECTED SOFTWARE
Affected packages
12 explicit affected versions
03 / CONNECTIONS
Connected vulnerabilities
04 / EVIDENCE
Source records
There is a private function in libcurl called `fix_hostname()` that removes a trailing dot from the hostname if there is one. The function is called after the hostname has been extracted from the URL libcurl has been told to act on. If a URL is given with a zero-length hostname, like in "http://:80" or ":80", `fix_hostname()` indexes the hostname pointer with a -1 offset (as it blindly assumes a non-zero length) and both read and assign that address. At best, this gets unnoticed but can also lead to a crash or worse. We have not researched further what kind of malicious actions that potentially this could be used for.
The fix_hostname function in cURL and libcurl 7.37.0 through 7.41.0 does not properly calculate an index, which allows remote attackers to cause a denial of service (out-of-bounds read or write and crash) or possibly have other unspecified impact via a zero-length host name, as demonstrated by "http://:80" and ":80."
05 / REFERENCES
Further evidence
- http://curl.haxx.se/docs/adv_20150422D.html
- http://kb.juniper.net/InfoCenter/index?page=content&id=JSA10743
- http://lists.apple.com/archives/security-announce/2015/Aug/msg00001.html
- http://lists.fedoraproject.org/pipermail/package-announce/2015-April/155957.html
- http://lists.fedoraproject.org/pipermail/package-announce/2015-May/156945.html
- http://lists.fedoraproject.org/pipermail/package-announce/2015-May/157017.html
- http://lists.fedoraproject.org/pipermail/package-announce/2015-May/157188.html
- http://lists.opensuse.org/opensuse-updates/2015-04/msg00057.html
- http://www.debian.org/security/2015/dsa-3232
- http://www.oracle.com/technetwork/security-advisory/cpuoct2018-4428296.html
- http://www.oracle.com/technetwork/topics/security/bulletinjan2016-2867206.html
- http://www.oracle.com/technetwork/topics/security/cpuoct2015-2367953.html
- http://www.securityfocus.com/bid/74300
- http://www.securitytracker.com/id/1032232
- http://www.ubuntu.com/usn/USN-2591-1
- https://security.gentoo.org/glsa/201509-02
- https://support.apple.com/kb/HT205031