Skip to main content

OpenSC CVE-2026-40510

| EUVD-2026-33315 LOW
Stack-based Buffer Overflow (CWE-121)
2026-05-29 VulnCheck GHSA-7rrw-cv3r-3cgg
1.0
CVSS 4.0 · NVD

Severity by source

NVD PRIMARY
1.0 LOW
CVSS:4.0/AV:P/AC:H/AT:N/PR:N/UI:P/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Primary rating from NVD · only source for this CVE.

CVSS VectorNVD

CVSS:4.0/AV:P/AC:H/AT:N/PR:N/UI:P/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Attack Vector
Physical
Attack Complexity
High
Privileges Required
None
User Interaction
P
Scope
X

Lifecycle Timeline

3
Source Code Evidence Fetched
May 29, 2026 - 14:34 vuln.today
Analysis Generated
May 29, 2026 - 14:34 vuln.today
CVSS changed
May 29, 2026 - 14:22 NVD
3.8 (LOW) 1.0 (LOW)

DescriptionCVE.org

OpenSC before 0.27.0-rc1, fixed in commit 3f24f0b, contains a stack buffer overflow vulnerability in piv_process_history() in src/libopensc/card-piv.c that allows physically present attackers to trigger memory corruption by presenting a crafted PIV smart card or USB device returning a URL field longer than 118 bytes in the Key History Object ASN.1 response.

AnalysisAI

Stack buffer overflow in OpenSC's PIV card handler allows a physically present attacker to corrupt memory by presenting a crafted PIV smart card or USB device that returns a URL field exceeding 118 bytes in the Key History Object ASN.1 response, triggering the overflow in piv_process_history() within src/libopensc/card-piv.c. All OpenSC versions prior to 0.27.0-rc1 are affected; the vulnerability is confirmed by the vendor fix in commit 3f24f0b and PR #3558. …

Unlock full vulnerability intelligence

  • Risk assessment & exploitation conditions
  • Attack chain visualization
  • Remediation with exact patch versions
  • Threat intelligence from 22 sources
  • Personal watchlist & email alerts

Free forever · No credit card required

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata

Access
Gain physical access to target machine
Delivery
Insert crafted PIV smart card or USB emulator
Exploit
System invokes PIV card processing via OpenSC
Execution
piv_process_history() reads Key History Object ASN.1 response
Persist
URL field >118 bytes overflows fixed stack buffer
Impact
Memory corruption with limited Low-level CIA impact on OpenSC process

Vulnerability AssessmentAI

Exploitation Exploitation requires the attacker to be physically present and able to insert a crafted PIV smart card or USB device emulating a smart card into the target machine - remote exploitation is not possible per AV:P. … Additional conditions and limiting factors are described in the full assessment.
Risk Assessment The CVSS 4.0 score of 1.0 is the primary quantitative signal and accurately reflects severe real-world constraints: physical access required (AV:P), high attack complexity (AC:H), passive user interaction required (UI:P), and only Low impact across confidentiality, integrity, and availability with no scope change to subsequent components (SC:N/SI:N/SA:N). … Full risk analysis with EPSS, KEV, and SSVC signal comparison available after sign-in.
Exploit Scenario An adversary with physical access to a workstation - such as a malicious insider or a supply-chain attacker who has tampered with smart cards - inserts a crafted PIV card or a USB device emulating a smart card reader that returns a Key History Object whose URL field exceeds 118 bytes in the ASN.1 response. When OpenSC's `piv_process_history()` function processes the card, the oversized URL overflows the fixed stack buffer before the missing bounds check, triggering memory corruption. …
Remediation The upstream fix is available in commit 3f24f0b and PR #3558 against the OpenSC GitHub repository, targeting release 0.27.0-rc1; however, 0.27.0-rc1 is a release candidate - a final stable tagged release has not been independently confirmed at time of analysis, so organizations should monitor https://github.com/OpenSC/OpenSC/releases for the stable 0.27.0 release. … Detailed patch versions, workarounds, and compensating controls in full report.

Threat intelligence, references, and detailed analysis are available after sign-in.

Share

CVE-2026-40510 vulnerability details – vuln.today

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy