Skip to main content

Opensc EUVDEUVD-2025-209124

| CVE-2025-49010 LOW
Stack-based Buffer Overflow (CWE-121)
2026-03-30 GitHub_M
3.8
CVSS 3.1 · GitHub Advisory
View

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Stack buffer bounds checking
MITRE ATT&CK

1 technique across 1 tactic: Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Impact

This vulnerability presents low-to-moderate real-world risk despite a CVSS score of 3.8 (low). The CVSS vector AV:P (physical attack vector) and AC:H (high complexity) indicate significant barriers to exploitation-an attacker must have hands-on access to the victim's computer AND craft a malicious token, AND the victim must actively use the token at that exact moment. The UI:R (user interaction required) further restricts the threat window. However, the severity is elevated by the fact that targets are likely high-value (users with smart cards or hardware tokens), and the impact extends across confidentiality, integrity, and availability (C:L, I:L, A:L). EPSS data is not provided, but the combination of physical access requirement and high complexity suggests exploitation probability remains low. SSVC analysis would likely classify this as defer-acceptable for enterprise environments where token usage is controlled and monitored, though it warrants patching as part of routine security updates. The patch availability (version 0.27.0) and the absence of public exploit code reduce urgency, but critical infrastructure or high-security environments relying on smart card authentication should prioritize remediation.

Exploit ScenarioDerived

An attacker with physical access to a user's workstation crafts a malicious USB smart card reader or token that, when the legitimate user inserts and uses it, sends specially crafted APDU responses to OpenSC. The stack buffer overflow is triggered during the GET RESPONSE processing, potentially allowing the attacker to corrupt the stack frame and overwrite return addresses or sensitive data. Success depends on the attacker being present at the exact moment the authorized user accesses the token, making it suitable for targeted attacks against high-value targets or supply-chain compromises where the malicious device is pre-planted. No public proof-of-concept has been identified.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Mar 30, 2026

Stack buffer overflow in OpenSC's GET RESPONSE handler prior to version 0.27.0 allows local attackers with physical access to trigger memory corruption via specially crafted smart card or USB device responses to APDUs. The vulnerability requires user interaction and physical proximity, limiting its practical exploitability; however, it could enable local privilege escalation or information disclosure when an authorized user or administrator actively uses a token. No public exploit code or active exploitation has been confirmed.

RemediationAI

Vendor-released patch: OpenSC version 0.27.0 and later. Update from official distribution channels or rebuild from source. For users unable to upgrade immediately, limit physical access to computers during token operations and monitor for suspicious device behavior. Environment controls such as restricting USB device insertion policies and using only trusted, pre-vetted smart cards or tokens can mitigate risk. Refer to the official security advisory at https://github.com/OpenSC/OpenSC/security/advisories/GHSA-q5cf-5wmx-9wh4 for detailed remediation guidance.

Affected VersionsENISA

opensc < 0.27.0

Affected Packages

euvd opensc fix: 0.27.0

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

OpenSC is middleware for smart card and token management on desktop systems. The vulnerability exists in the GET RESPONSE APDU handler, which processes responses from smart cards or USB tokens. When a crafted token returns specially formed APDU responses, a stack buffer overflow (CWE-121) occurs, allowing an attacker to write beyond allocated stack memory boundaries. The attack surface is limited to the APDUs exchanged during token interaction; the attacker must control the physical device or perform a man-in-the-middle attack on the USB/smart card interface. Affected versions are all releases prior to 0.27.0, as identified by the CPE range cpe:2.3:a:opensc:opensc:*:*:*:*:*:*:*:* without upper-bound version.

Know when Opensc 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

GitHub Advisory PRIMARY 3.8 LOW
AV:P/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:L
Red Hat 3.8 LOW

Primary rating from GitHub Advisory.

CVSS VectorGitHub Advisory

Attack Vector
Physical
Attack Complexity
High
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
Low
Integrity
Low
Availability
Low

Lifecycle Timeline

2
Patch available
Apr 16, 2026 - 05:29 EUVD
0.27.0
CVE Published
Mar 30, 2026 - 16:59 nvd
LOW 3.8

DescriptionGitHub Advisory

OpenSC is an open source smart card tools and middleware. Prior to version 0.27.0, an attacker with physical access to the computer at the time user or administrator uses a token can cause a stack-buffer-overflow write in GET RESPONSE. The attack requires crafted USB device or smart card that would present the system with specially crafted responses to the APDUs. This issue has been patched in version 0.27.0.

Threat Intelligence Overview

EPSS Score
0.0%
Top 95% exploitable
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment Vendor GitHub VulDB

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.

SignalValue
Severity LOW
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation
None
System Exposure· derived
Small
Automatable
No
Human Impact· derived
Low
Technical Impact
Partial

Priority Score

19
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +19
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

A stack-based buffer overflow occurs when a program writes more data to a buffer located on the stack than it was allocated to hold.

More in Opensc

View all
CVE-2019-6502 HIGH POC
7.5 Jan 22

sc_context_create in ctx.c in libopensc in OpenSC 0.19.0 has a memory leak, as demonstrated by a call from eidenv. Rated

CVE-2018-16393 MEDIUM POC
6.8 Sep 03

Several buffer overflows when handling responses from a Gemsafe V1 Smartcard in gemsafe_get_cert_len in libopensc/pkcs15

CVE-2018-16392 MEDIUM POC
6.8 Sep 03

Several buffer overflows when handling responses from a TCOS Card in tcos_select_file in libopensc/card-tcos.c in OpenSC

CVE-2018-16391 MEDIUM POC
6.8 Sep 03

Several buffer overflows when handling responses from a Muscle Card in muscle_list_files in libopensc/card-muscle.c in O

CVE-2018-16425 MEDIUM POC
6.6 Sep 04

A double free when handling responses from an HSM Card in sc_pkcs15emu_sc_hsm_init in libopensc/pkcs15-sc-hsm.c in OpenS

CVE-2018-16424 MEDIUM POC
6.6 Sep 04

A double free when handling responses in read_file in tools/egk-tool.c (aka the eGK card tool) in OpenSC before 0.19.0-r

CVE-2018-16423 MEDIUM POC
6.6 Sep 04

A double free when handling responses from a smartcard in sc_file_set_sec_attr in libopensc/sc.c in OpenSC before 0.19.0

CVE-2018-16422 MEDIUM POC
6.6 Sep 04

A single byte buffer overflow when handling responses from an esteid Card in sc_pkcs15emu_esteid_init in libopensc/pkcs1

CVE-2018-16421 MEDIUM POC
6.6 Sep 04

Several buffer overflows when handling responses from a CAC Card in cac_get_serial_nr_from_CUID in libopensc/card-cac.c

CVE-2018-16420 MEDIUM POC
6.6 Sep 04

Several buffer overflows when handling responses from an ePass 2003 Card in decrypt_response in libopensc/card-epass2003

CVE-2018-16419 MEDIUM POC
6.6 Sep 04

Several buffer overflows when handling responses from a Cryptoflex card in read_public_key in tools/cryptoflex-tool.c in

CVE-2018-16418 MEDIUM POC
6.6 Sep 04

A buffer overflow when handling string concatenation in util_acl_to_str in tools/util.c in OpenSC before 0.19.0-rc1 coul

Vendor StatusVendor

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