CVE-2023-28320
Medium · 5.9CVSS
5.9
EPSS
2.7%
Published
May 26, 2023
CISA due date
—
Cloudanix analysis
A flaw in how some versions of curl handle slow website address lookups in programs that run multiple tasks at once can make those programs crash or act strangely.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Moderate
- Impact
- Denial Of Service
- Component
- Library
- Class
- Race Condition
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Race condition in libcurl synchronous resolver backend using unprotected global buffer with alarm() and siglongjmp() for timeout handling, allowing multi-threaded applications to crash or misbehave during slow name resolution.
Why it matters to the business
Applications relying on curl for network requests in multi-threaded setups can experience unexpected crashes or erratic behavior, leading to service outages, degraded performance, and operational disruptions across dependent software ecosystems.
How an attack unfolds
An attacker initiates network requests that trigger slow DNS resolution in a vulnerable multi-threaded application built with the synchronous resolver; concurrent threads then race on the shared global buffer during signal-based timeout handling via alarm() and siglongjmp(), resulting in process instability.
How to fix it
Upgrade curl to a build incorporating commit a9f8fe28481fef7c28d85b4a12a3a35521408eaf or later; rebuild affected applications against the patched library; consider switching to an asynchronous resolver backend at build time if multi-threaded usage is required.
How to confirm the fix worked
Verify the installed curl version includes the referenced commit; inspect build configuration for resolver backend selection; test multi-threaded name resolution scenarios for absence of crashes under timeout conditions.
Typical attack path
- Identify target applications or services using curl built with the synchronous resolver backend
- Send crafted requests designed to induce slow or delayed hostname resolution
- Exploit concurrent threading to trigger the unprotected global buffer access during signal timeout handling
- Cause application crash or misbehavior to achieve denial of service
How to detect it
Review application logs and crash dumps for unexpected terminations during hostname resolution in multi-threaded curl usage; correlate with DNS timeout events; examine process traces for signal handler activity around name resolution.
What your security team should do
- Prioritize updating all curl installations and dependent packages to the fixed commit version
- Audit build configurations to prefer asynchronous resolvers in multi-threaded environments
- Monitor for application instability correlated with DNS operations
- Apply updates within standard maintenance windows given stable EPSS and lack of KEV listing
The record
A denial of service vulnerability exists in curl <v8.1.0 in the way libcurl provides several different backends for resolving host names, selected at build time. If it is built to use the synchronous resolver, it allows name resolves to time-out slow operations using `alarm()` and `siglongjmp()`. When doing this, libcurl used a global buffer that was not mutex protected and a multi-threaded application might therefore crash or otherwise misbehave.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Alpine:v3.15 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.16 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.17 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.18 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.19 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.20 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.21 | curl | 0 | 8.1.0-r0 |
| Alpine:v3.22 | curl | 0 | 8.1.0-r0 |
| Debian:10 | curl | 0 | No fix |
| Debian:11 | curl | 0 | No fix |
| Debian:12 | curl | 0 | 7.88.1-10 |
| Debian:13 | curl | 0 | 7.88.1-10 |
| Mageia:8 | curl | 0 | 7.74.0-1.13.mga8 |
| Mageia:9 | curl | 0 | 7.88.1-3.1.mga9 |
| SUSE:Enterprise Storage 6 | curl | 0 | 7.60.0-150000.51.1 |
| SUSE:Enterprise Storage 7 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Enterprise Storage 7.1 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | curl | 0 | 7.60.0-150000.51.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP2-LTSS | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP3-ESPOS | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP3-LTSS | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Micro 5.1 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Micro 5.2 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Micro 5.3 | curl | 0 | 8.0.1-150400.5.23.1 |
| SUSE:Linux Enterprise Micro 5.4 | curl | 0 | 8.0.1-150400.5.23.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP4 | curl | 0 | 8.0.1-150400.5.23.1 |
| SUSE:Linux Enterprise Real Time 15 SP3 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Server 12 SP2-BCL | curl | 0 | 7.37.0-37.98.1 |
| SUSE:Linux Enterprise Server 12 SP4-ESPOS | curl | 0 | 7.60.0-4.56.1 |
| SUSE:Linux Enterprise Server 12 SP4-LTSS | curl | 0 | 7.60.0-4.56.1 |
| SUSE:Linux Enterprise Server 12 SP5 | curl | 0 | 8.0.1-11.65.2 |
| SUSE:Linux Enterprise Server 15 SP1-LTSS | curl | 0 | 7.60.0-150000.51.1 |
| SUSE:Linux Enterprise Server 15 SP2-LTSS | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Server 15 SP3-LTSS | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP4 | curl | 0 | 7.60.0-4.56.1 |
| SUSE:Linux Enterprise Server for SAP Applications 12 SP5 | curl | 0 | 8.0.1-11.65.2 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP1 | curl | 0 | 7.60.0-150000.51.1 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP2 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP3 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Linux Enterprise Software Development Kit 12 SP5 | curl | 0 | 8.0.1-11.65.2 |
| SUSE:Manager Proxy 4.2 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:Manager Server 4.2 | curl | 0 | 7.66.0-150200.4.57.1 |
| SUSE:OpenStack Cloud 9 | curl | 0 | 7.60.0-4.56.1 |
| SUSE:OpenStack Cloud Crowbar 9 | curl | 0 | 7.60.0-4.56.1 |
| openSUSE:Leap 15.4 | curl | 0 | 8.0.1-150400.5.23.1 |
| openSUSE:Leap 15.5 | curl | 0 | 8.0.1-150400.5.23.1 |
| openSUSE:Leap Micro 5.3 | curl | 0 | 8.0.1-150400.5.23.1 |
| openSUSE:Tumbleweed | curl | 0 | 8.1.0-1.1 |
Related vulnerabilities
- CVE-2023-46219 When saving HSTS data to an excessively long file name, curl could end up removing all… Also affects curl
- CVE-2023-46218 This flaw allows a malicious HTTP server to set "super cookies" in curl that are then… Also affects curl
- CVE-2023-38545 This flaw makes curl overflow a heap based buffer in the SOCKS5 proxy handshake. Also affects curl
- CVE-2023-38546 This flaw allows an attacker to insert cookies at will into a running program using… Also affects curl
- CVE-2023-28322 An information disclosure vulnerability exists in curl <v8.1.0 when doing HTTP(S)… Also affects curl
- CVE-2023-28321 An improper certificate validation vulnerability exists in curl <v8.1.0 in the way it… Also affects curl
- CVE-2023-28319 A use after free vulnerability exists in curl <v8.1.0 in the way libcurl offers a feature… Also affects curl
- CVE-2023-27534 A path traversal vulnerability exists in curl <8.0.0 SFTP implementation causes the tilde… Also affects curl