CVE-2022-42916
In curl before 7.86.0, the HSTS check could be bypassed to trick it into staying with HTTP. Using its HSTS support, curl can be instructed to use HTTPS directly (instead of using an insecure cleartext HTTP step) even when HTTP is provided in the URL. This mechanism could be bypassed if the host name in the given URL uses IDN characters that get replaced with ASCII counterparts as part of the IDN conversion, e.g., using the character UTF-8 U+3002 (IDEOGRAPHIC FULL STOP) instead of the common ASCII full stop of U+002E (.). The earliest affected version is 7.77.0 2021-05-26.
What to do
Fixed builds are available from Alpine, Debian, Ubuntu: see the table below for the fixed version per release.
Ubuntu has not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 22.04 | curl | Fixed | 7.81.0-1ubuntu1.6 | UBUNTU-CVE-2022-42916 |
| Ubuntu 16.04 | curl | Fix pending | ||
| Debian 14 | curl | Fixed | 7.86.0-1 | DEBIAN-CVE-2022-42916 |
| Debian 13 | curl | Fixed | 7.86.0-1 | DEBIAN-CVE-2022-42916 |
| Debian 12 | curl | Fixed | 7.86.0-1 | DEBIAN-CVE-2022-42916 |
| Red Hat Enterprise Linux 9 | curl | Not affected | ||
| Red Hat Enterprise Linux 9 | curl-minimal | Not affected | ||
| Red Hat Enterprise Linux 9 | libcurl | Not affected | ||
| Red Hat Enterprise Linux 9 | libcurl-devel | Not affected | ||
| Red Hat Enterprise Linux 9 | libcurl-minimal | Not affected | ||
| Red Hat Enterprise Linux 8 | curl | Not affected | ||
| Red Hat Enterprise Linux 8 | libcurl | Not affected | ||
| Red Hat Enterprise Linux 8 | libcurl-devel | Not affected | ||
| Red Hat Enterprise Linux 8 | libcurl-minimal | Not affected | ||
| Red Hat Enterprise Linux 7 | curl | Not affected | ||
| Red Hat Enterprise Linux 7 | libcurl | Not affected | ||
| Red Hat Enterprise Linux 7 | libcurl-devel | Not affected | ||
| Red Hat Enterprise Linux 6 | curl | Not affected | ||
| Red Hat Enterprise Linux 6 | libcurl | Not affected | ||
| Red Hat Enterprise Linux 6 | libcurl-devel | Not affected | ||
| Alpine Linux 3.24 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.23 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.22 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.21 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.20 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.19 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.18 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.17 | curl | Fixed | 7.86.0-r0 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.16 | curl | Fixed | 7.83.1-r4 | ALPINE-CVE-2022-42916 |
| Alpine Linux 3.15 | curl | Fixed | 7.80.0-r4 | ALPINE-CVE-2022-42916 |
What the vendor says
As published in the CVE record by mitre, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
Vendor advisories:
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/… (vendor-advisory)
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/… (vendor-advisory)
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/… (vendor-advisory)
- https://security.gentoo.org/glsa/202212-01 (vendor-advisory)
References
- https://curl.se/docs/CVE-2022-42916.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/HVU3IMZCKR4VE6KJ4GCWRL2ILLC6OV76/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Q27V5YYMXUVI6PRZQVECON32XPVWTKDK/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/37YEVVC6NAF6H7UHH6YAUY5QEVY6LIH2/
- https://security.netapp.com/advisory/ntap-20221209-0010/
- https://security.gentoo.org/glsa/202212-01
- http://www.openwall.com/lists/oss-security/2022/12/21/1
- https://support.apple.com/kb/HT213604
- https://support.apple.com/kb/HT213605
- http://seclists.org/fulldisclosure/2023/Jan/20
- http://seclists.org/fulldisclosure/2023/Jan/19
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.