Stack-buffer-overflow in iasecc_crt_parse in opensc

opensc Updated 02 Oct 2025

Summary

28/08/2023
MEDIUM
Yes i
Medium
Not published

OSV-2023-753: Stack-buffer-overflow in iasecc_crt_parse. Affects opensc versions >= ac8d87751607fcc8669bd63891ecaad1a466f718, < 2a4921ab23fd0853f327517636c50de947548161. Fixed in 2a4921ab23fd0853f327517636c50de947548161. 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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

OpenSC is an open-source smart card library that provides a set of cryptographic functions and smart card drivers. It is commonly used for interacting with smart cards and secure tokens. The vulnerability in question affects the iasecc_crt_parse function within OpenSC, which is responsible for parsing certificate data. This function is susceptible to a stack-buffer-overflow vulnerability, which can be triggered by a specially crafted input. This vulnerability can potentially lead to remote code execution or denial of service attacks.

Vulnerability Detail

The stack-buffer-overflow vulnerability in iasecc_crt_parse arises due to improper handling of input data. An attacker can exploit this vulnerability by providing a malicious input that exceeds the bounds of the stack buffer, leading to a buffer overflow. This can result in the overwriting of adjacent memory, potentially allowing the attacker to execute arbitrary code or crash the application. The vulnerability was discovered through OSS-Fuzz, and more details can be found in the provided link. The severity of this vulnerability is rated as MEDIUM.

How To Fix

Minimum fixed version

2a4921ab23fd0853f327517636c50de947548161

This is the first release that contains the fix.

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

Workaround

As a temporary workaround, it is advisable to avoid processing untrusted certificate data until the package has been updated with the fix. This can help mitigate the risk of exploitation.

Conclusion

In conclusion, the iasecc_crt_parse function in OpenSC is vulnerable to a stack-buffer-overflow. This vulnerability can be exploited to execute arbitrary code or cause a denial of service. It is crucial to update the OpenSC package to a version that includes the fix to mitigate the risk. For further assistance or support in addressing this vulnerability, please contact DevNack.com.

See every vulnerability recorded for opensc →

Share this vulnerability

FAQ

OpenSC is an open-source smart card library that provides cryptographic functions and smart card drivers.

This vulnerability can potentially lead to remote code execution or denial of service attacks.

This vulnerability was discovered through OSS-Fuzz, a continuous fuzzing service for open-source software.

The severity of this vulnerability is rated as MEDIUM.

To fix this vulnerability, update the OpenSC package to a version that includes the fix.

Related vulnerabilities

Recent vulnerabilities recorded for opensc.

How To Fix

Minimum fixed version

2a4921ab23fd0853f327517636c50de947548161

This is the first release that contains the fix.

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