Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft PFX with ~2^31 iteration count
-
DeliverySubmit file to app that loads keystores
-
ExploitPkcs12Store.Load reads unbounded count
-
ExecutionKey derivation runs before MAC check
-
ImpactCPU exhaustion denial of service
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A06:2025 - Insecure Design
ASVS 5.0
V2 - Validation and Business Logic Resource allocation limits
MITRE ATT&CK
1 technique across 1 tactic: Impact The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | The target application must invoke Pkcs12Store.Load or Pkcs12Utilities.ConvertToDefiniteLength (bc-csharp before 2.7.0) on a PKCS#12/PFX file whose content is attacker-controlled, with a crafted iteration count near 2^31 placed in MacData or in the PBE parameters of an encrypted SafeContents or shrouded key bag. No valid password or MAC is required because key derivation executes before the MAC or password is checked (PR:N). The key LIMITING factor is UI:P: an attacker cannot trigger this remotely on their own - a victim application or user must actually accept and load the malicious keystore, so deployments that only process trusted local PFX files are not realistically exposed. |
| Impact | This is a genuine but moderate-priority denial-of-service issue, not a high-impact RCE despite the 7.1 score. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H) shows the real shape: impact is availability-only (VA:H) with no confidentiality or integrity effect, and exploitation requires passive user interaction (UI:P) - specifically, a victim application must load an attacker-supplied PKCS#12/PFX file. The source-code evidence (fix adds a DefaultMaxIterations=5,000,000 bound via Pkcs12Utilities.ValidateIterations) confirms the root cause: the iteration count is read from the file with no upper bound and key derivation runs BEFORE the MAC or password is checked, so no authentication to the keystore is needed. Exploitation status is 'no public exploit identified at time of analysis' - the input provides neither KEV nor POC signals, and no EPSS score is supplied, so exploitation probability cannot be quantified. Real-world risk hinges entirely on whether a given deployment feeds untrusted PFX files into bc-csharp; for services that accept user-uploaded keystores this is a realistic availability threat, while for applications that only load trusted local keystores the practical risk is low. |
| Exploit ScenarioDerived | An attacker uploads or submits a crafted PKCS#12 (PFX) file to an application that uses bc-csharp (before 2.7.0) to load keystores - for example a certificate-import endpoint. When the application calls Pkcs12Store.Load (or Pkcs12Utilities.ConvertToDefiniteLength), the embedded MacData or PBE iteration count near 2^31 drives key derivation before any MAC/password check, pinning a CPU core and causing denial of service. No public exploit code is identified at time of analysis, but the condition is trivial to craft given the published fix. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 02, 2026
CPU exhaustion denial of service in Legion of the Bouncy Castle Inc. bc-csharp before 2.7.0 lets unauthenticated remote attackers tie up a process by supplying a crafted PKCS#12 (PFX) keystore. Pkcs12Store.Load and Pkcs12Utilities.ConvertToDefiniteLength take the key-derivation iteration count straight from the file - in MacData or in the PBE parameters of an encrypted SafeContents or shrouded key bag - without an upper bound, so a count approaching 2^31 forces enormous key-derivation work before the MAC or password is ever validated (PR:N per the assessed CVSS:3.1 vector). Exploitation is not autonomous: the assessed UI:R/UI:P condition means some victim application or user must actually accept and load the malicious keystore, so no public exploit code has been identified at time of analysis and there is no CISA KEV listing; this is a genuine but moderate-priority availability issue rather than remote code execution despite the 7.1 CVSS 4.0 score.
RemediationAI
Vendor-released patch: upgrade bc-csharp to 2.7.0 or later, which introduces Pkcs12Utilities.ValidateIterations and enforces a default ceiling of 5,000,000 iterations on values read from MacData and PBE parameter blocks (see https://github.com/bcgit/bc-csharp/wiki/CVE-2026-63572 and the referenced fix commits). Where an immediate upgrade is not possible, the most effective compensating control is to parse the untrusted PFX ASN.1 yourself before handing it to Pkcs12Store.Load or Pkcs12Utilities.ConvertToDefiniteLength: read MacData.Iterations and the PBE iteration fields of every encrypted SafeContents and shrouded key bag, and reject any file whose count is negative or exceeds a sane business threshold (the upstream default of 5,000,000 is a reasonable starting point) - the trade-off is that rejecting high counts will also refuse legitimately hardened keystores generated with very large iteration counts, so pair it with a clear error message and a documented threshold. Additionally, wrap keystore loading in a hard timeout and process it out-of-band from latency-sensitive request threads (a worker queue or short-lived task with a watchdog) so a single malicious file cannot stall the whole service; this does not prevent the CPU burn but bounds its blast radius. If raising the Org.BouncyCastle.Pkcs12.MaxIterations environment variable above the default for compatibility with existing keystores, do so only on trusted, non-internet-facing import paths, since a higher limit proportionally restores the attack surface. Finally, restrict which endpoints and identities may submit PFX files, and treat untrusted keystore import as a privileged operation; deployments that only load trusted local PFX files are not realistically exposed and need not rush an emergency change once the patched library is available.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
PKCS#12 (PFX) is an ASN.1 container format for private keys and certificates that wraps content in an authenticated SafeContents structure; integrity is protected by an HMAC computed over MacData, and encrypted bags and shrouded key bags are protected by password-based encryption (PBE) parameters that carry a salt and an iteration count. In bc-csharp, PbeUtilities.GenerateAlgorithmParameters builds the Pkcs12PbeParams from the caller-supplied iteration count, and Pkcs12Store.CalculatePbeMac applies that count when deriving the MAC key. The vulnerability is CWE-770 (Allocation of Resources Without Limits or Throttling): the iteration count read from MacData.Iterations or from a PBE parameter block is passed directly into the key-derivation loop with no ceiling, and because derivation executes before the MAC is checked or the password verified, an invalid password gives the attacker no protection - the CPU cost is paid regardless. The upstream fix adds Pkcs12Utilities.ValidateIterations, rejects values that do not fit in a signed 32-bit int, rejects negative values, enforces a default maximum of 5,000,000 iterations (overridable via the Org.BouncyCastle.Pkcs12.MaxIterations environment variable), and routes both the MAC path and the PBE parameter generation through that validation. The related zero-or-negative-count case is tracked separately as CVE-2026-63575, confirming this family of input-validation gaps in the same loader.
Know when Bc Csharp gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
A crafted PFX can arrive over the network (AV:N) and needs no authentication to the keystore (PR:N), but a victim must load it (UI:R); impact is availability-only (A:H, C/I:N).
Primary rating from Vendor (bcorg).
CVSS VectorVendor: bcorg
DescriptionCVE.org
Allocation of resources without limits in PKCS#12 keystore loading (Pkcs12Store.Load) in Legion of the Bouncy Castle Inc. bc-csharp before 2.7.0 allows an attacker who can supply a PKCS#12 (PFX) file to cause a denial of service through CPU exhaustion via an iteration count close to 2^31 in the file's MacData or in the PBE parameters of an encrypted SafeContents or shrouded key bag, because the counts are taken from the file without an upper bound and the key derivation runs before the MAC or the password can be checked. A zero or negative count is covered by CVE-2026-63575. Pkcs12Utilities.ConvertToDefiniteLength is also affected.
Executive ViewAI
Organizations using Bouncy Castle bc-csharp versions before 2.7.0 in applications that load PKCS#12 keystores face a CPU exhaustion denial-of-service risk that can degrade or halt service availability. The issue is unauthenticated but requires a victim application or user to accept and load a malicious keystore; no public exploit identified at time of analysis, and a vendor patch is available in 2.7.0. Leadership should prioritize patching externally facing or business-critical services that process untrusted keystores to prevent avoidable availability disruptions.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.
Crafted small-order or out-of-range Diffie-Hellman values passed to DHAgreement.CalculateAgreement in Bouncy Castle C# (
Memory exhaustion in Bouncy Castle C# (bc-csharp) before 2.7.0 allows a remote, unauthenticated attacker to cause a deni
Memory-exhaustion denial of service in the C# DTLS implementation of Bouncy Castle (bc-csharp) before 2.7.0 lets a remot
Denial of service in Legion of the Bouncy Castle's C# cryptography library (bc-csharp) before 2.7.0 lets an unauthentica
Uncontrolled recursion in Bouncy Castle C# (bc-csharp) before 2.7.0 allows unauthenticated remote attackers to crash or
Denial of service in Legion of the Bouncy Castle Inc. bc-csharp before 2.7.0 allows unauthenticated remote attackers to
Denial of service in the Legion of the Bouncy Castle C# library (bc-csharp) affects all versions before 2.7.0, where qua
Authentication-tag forgery in Legion of the Bouncy Castle Inc. bc-csharp (Bouncy Castle C#) before 2.7.0 lets a remote,
Forged X.509 attribute certificates are accepted as valid by Legion of the Bouncy Castle Inc. bc-csharp versions before
Observable padding discrepancy in the IES/ECIES decryption path of Bouncy Castle C# (bc-csharp) before 2.7.0 lets an una
RSA PKCS#1 v1.5 key transport in the Bouncy Castle C# (bc-csharp) CMS implementation before 2.7.0 is vulnerable to a Ble
Information disclosure in Bouncy Castle C# (bc-csharp) versions before 2.7.0 allows unauthenticated remote attackers to
EUVD-2026-91223
GHSA-v54c-wxx6-mjh6
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB