Out-of-bounds ReadWeakness · CWE-125

CVE-2024-29857

HIGH · 7.5 CVSS v3.1 Published 2024-05-14
Mitigation only
No fix yet — a mitigation exists. There is no fixed release. A documented workaround reduces exposure in the meantime.
See remediation →
84/100
Remediation priority · High
Remotely reachable No privileges Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
An issue was discovered in ECCurve.java and ECCurve.cs in Bouncy Castle Java (BC Java) before 1.78, BC Java LTS before 2.73.6, BC-FJA before 1.0.2.5, and BC C# .Net before 2.3.1. Importing an EC certificate with crafted F2m parameters can lead to excessive CPU consumption during the evaluation of the curve parameters.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

This is a denial-of-service vulnerability in the Bouncy Castle cryptographic libraries (Java, C#, and FJA). When importing an EC (Elliptic Curve) certificate containing crafted F2m (finite field GF(2^m)) parameters, the curve parameter evaluation enters an inefficient computational path, causing excessive CPU consumption. An attacker could exploit this by presenting malicious EC certificates to trigger resource exhaustion.

MitigationUpgrade Bouncy Castle libraries to version 1.78 or later (Java), 2.73.6 or later (LTS), 1.0.2.5 or later (FJA), or 2.3.1 or later (C# .Net). If upgrading is not immediately feasible, implement certificate validation checks and rate-limiting on certificate import operations.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify Bouncy Castle library usage
    Search your project dependencies (Maven pom.xml, Gradle build.gradle, NuGet packages.config, or JAR files) for 'bouncycastle' or 'bc' libraries. Check both direct and transitive dependencies.
    Affected if Bouncy Castle library is present in the environment
  2. Determine installed Bouncy Castle version
    Locate the specific version number from your dependency management file or the JAR/assembly metadata. For Java, check the bcprov jar filename or manifest. For C#, check the assembly version attribute.
    Affected if The version is earlier than 1.78 (Java), 2.73.6 (LTS), 1.0.2.5 (FJA), or 2.3.1 (C#)
  3. Verify EC certificate import is in use
    Search codebases for certificate import or parsing calls, particularly: 'X509Certificate', 'CertificateFactory', or 'X509Certificate2' classes being used with Bouncy Castle providers. Check for code that loads or processes EC (elliptic curve) certificates.
    Affected if EC certificate import or parsing functionality using Bouncy Castle is implemented
  4. Check for F2m curve parameter handling
    Review certificate processing code to determine if it handles EC certificates from external/untrusted sources. F2m refers to binary/finite field elliptic curves (such as sect163k1, sect233r1, etc.).
    Affected if The application imports EC certificates from external or untrusted sources without additional validation

You are affected if Bouncy Castle is in use, the version is below the fixed releases, and your application processes EC certificates containing F2m curve parameters from external sources.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Mitigation available No clean upgrade yet — mitigate in the meantime
Mitigation

Upgrade Bouncy Castle libraries to version 1.78 or later (Java), 2.73.6 or later (LTS), 1.0.2.5 or later (FJA), or 2.3.1 or later (C# .Net). If upgrading is not immediately feasible, implement certificate validation checks and rate-limiting on certificate import operations.

Recommended fix High confidence

BC Java: 1.78+ or LTS 2.73.6+, BC-FJA: 1.0.2.5+, BC C# .Net: 2.3.1+

  1. Identify which Bouncy Castle library variant is in use (BC Java, BC-FJA, or BC C# .Net)
  2. Check current Bouncy Castle library version in use
  3. For BC Java: upgrade to version 1.78 or later
  4. For BC Java LTS: upgrade to version 2.73.6 or later
  5. For BC-FJA: upgrade to version 1.0.2.5 or later
  6. For BC C# .Net: upgrade to version 2.3.1 or later
  7. Rebuild and redeploy the application with the updated library
  8. Test that EC certificate import functionality still works correctly

Generated from the published advisory — verify against the referenced sources before acting.

Have this fixed Scoped from the published advisory
  • Consultation3.0 h
  • Implementation4.0 h
  • Testing6.0 h
  • Review / QA2.0 h
15.0 hours of engineering $2,580
Get help mitigating

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $4,128.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2024-29857 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2024-29857 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data