CVE-2024-7264: Vulnerability in curl package - ASN.1 Parser Code

curl Updated 02 Oct 2025

Summary

31/07/2024
Yes i
Medium
6.5

CVE-2024-7264: libcurl's ASN1 parser code has the GTime2str() function, used for parsing an ASN.1 Generalized Time field. Affects curl across 2 version ranges.

< 8.9.1-r0 < 27959ecce75cdb2809c0bdb3286e60e08fadb519

Fixed in 8.9.1-r0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The curl package is a widely used open-source library and command-line tool for transferring data with URLs. It supports various protocols, including HTTP, HTTPS, FTP, and more. The package provides a range of features and options for performing network requests and handling data transfers. However, the curl package is vulnerable to a specific issue in its ASN.1 parser code.

Vulnerability Detail

The vulnerability (CVE-2024-7264) in the curl package's ASN.1 parser code arises from the GTime2str() function, responsible for parsing an ASN.1 Generalized Time field. If the parser encounters a syntactically incorrect field, it may incorrectly use -1 as the length of the time fraction. This can lead to a strlen() operation being performed on a pointer to a heap buffer area that is not null terminated. The consequence of this flaw is likely a crash, but it can also result in the application receiving heap contents when using the CURLINFO_CERTINFO option.

How To Fix

Minimum fixed version

8.9.1-r0

This is the first release that contains the fix.

sudo apk add --upgrade curl

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

No specific workaround has been provided for this vulnerability. It is recommended to follow the fix instructions and update the curl package to a patched version.

Conclusion

The curl package is vulnerable to a flaw in its ASN.1 parser code, which can lead to crashes and potential exposure of heap contents. To address this vulnerability, it is crucial to update the curl package to a version that includes the necessary patch. Regularly updating software packages is essential for maintaining a secure environment.

See every vulnerability recorded for curl →

Share this vulnerability

FAQ

The curl package is an open-source library and command-line tool used for transferring data with URLs. It supports various protocols and provides extensive features for network requests.

The vulnerability in the curl package's ASN.1 parser code can lead to crashes and potentially expose heap contents when certain options are used. It is important to update the package to mitigate these risks.

To fix this vulnerability, update the curl package to a version that includes the necessary patch. Regularly updating software packages is crucial for maintaining security.

No specific workarounds have been provided for this vulnerability. It is recommended to update the curl package to a patched version.

Related vulnerabilities

Recent vulnerabilities recorded for curl.

How To Fix

Minimum fixed version

8.9.1-r0

This is the first release that contains the fix.

sudo apk add --upgrade curl

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback