Every CVE Search/ Get API key

CVE-2021-42779

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

5.3 MediumFix available

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
None
Availability
Low

Exploit likelihood

2.08%Up 1.2 points since Apr 19, 2022
90%50%10%1%

What each source reports

NVD Score used 5.3

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
CVE-2021-42779
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
CVSS 2.0
5.0 MediumAV:N/AC:L/Au:N/C:N/I:N/A:P
Weakness
CWE-416
Updated
2026-11-02
CVE List No score

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
CVE-2021-42779
Weakness
CWE-416
Updated
2026-11-02
EUVDEUVD-2021-29735 No score

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
EUVD-2021-29735
Updated
2026-11-02
GitHub AdvisoriesGHSA-rcjw-9639-853h 5.3

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
GHSA-rcjw-9639-853h
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Weakness
CWE-416
Updated
2026-11-02
OSVAZL-9482 5.3

CVE-2021-42779 affecting package opensc for versions less than 0.22.0-1

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
AZL-9482
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Updated
2026-11-02
OSV 5.3

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
CVE-2021-42779
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Updated
2026-11-02
Show 7 moreShow less
OSVDEBIAN-CVE-2021-42779 5.3

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
DEBIAN-CVE-2021-42779
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Updated
2026-11-02
OSVUBUNTU-CVE-2021-42779 5.3

A heap use after free issue was found in Opensc before version 0.22.0 in sc_file_valid.

Record
UBUNTU-CVE-2021-42779
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Updated
2026-11-02
OSVMGASA-2021-0512 No score

Updated opensc packages fix security vulnerability

CVE-2021-42780: Fixed use after return in insert_pin() (bsc#1192005). CVE-2021-42779: Fixed use after free in sc_file_valid() (bsc#1191992). CVE-2021-42781: Fixed multiple heap buffer overflows in pkcs15-oberthur.c (bsc#1192000). CVE-2021-42782: Stack buffer overflow issues in various places (bsc#1191957).

Record
MGASA-2021-0512
Updated
2026-11-02
OSVopenSUSE-SU-2024:11613-1 No score

opensc-0.22.0-2.1 on GA media

These are all security issues fixed in the opensc-0.22.0-2.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:11613-1
Updated
2026-11-02
OSVSUSE-SU-2021:3582-1 No score

Security update for opensc

This update for opensc fixes the following issues:

  • CVE-2021-42780: Fixed use after return in insert_pin() (bsc#1192005).
  • CVE-2021-42779: Fixed use after free in sc_file_valid() (bsc#1191992).
  • CVE-2021-42781: Fixed multiple heap buffer overflows in pkcs15-oberthur.c (bsc#1192000).
  • CVE-2021-42782: Stack buffer overflow issues in various places (bsc#1191957).
Record
SUSE-SU-2021:3582-1
Updated
2026-11-02
OSVSUSE-SU-2022:1041-1 No score

Security update for opensc

This update for opensc fixes the following issues:

Security issues fixed:

  • CVE-2021-42780: Fixed use after return in insert_pin() (bsc#1192005).
  • CVE-2021-42779: Fixed use after free in sc_file_valid() (bsc#1191992).
  • CVE-2021-42781: Fixed multiple heap buffer overflows in pkcs15-oberthur.c (bsc#1192000).
  • CVE-2021-42782: Stack buffer overflow issues in various places (bsc#1191957).
  • CVE-2019-6502: Fixed a memory leak in sc_context_create() (bsc#1122756).
  • CVE-2020-26570: Fixed a heap based buffer overflow in sc_oberthur_read_file (bsc#1177364).
  • CVE-2020-26572: Prevent out of bounds write (bsc#1177378)
  • CVE-2020-26571: gemsafe GPK smart card software driver stack-based buffer overflow (bsc#1177380)
  • CVE-2019-15946: out-of-bounds access of an ASN.1 Octet string in asn1_decode_entry (bsc#1149747)
  • CVE-2019-19479: incorrect read operation during parsing of a SETCOS file attribute (bsc#1158256)
  • CVE-2019-15945: Fixed an out-of-bounds access of an ASN.1 Bitstring in decode_bit_string (bsc#1149746).
  • CVE-2019-19481: Fixed an improper handling of buffer limits for CAC certificates (bsc#1158305).
  • CVE-2019-20792: Fixed a double free in coolkey_free_private_data (bsc#1170809).

Non-security issues fixed:

  • Fixes segmentation fault in 'pkcs11-tool.c'. (bsc#1114649)
Record
SUSE-SU-2022:1041-1
Updated
2026-11-02
OSVSUSE-SU-2022:1156-1 No score

Security update for opensc

This update for opensc fixes the following issues:

Security issues fixed:

  • CVE-2021-42782: Stack buffer overflow issues in various places (bsc#1191957).
  • CVE-2021-42781: Fixed multiple heap buffer overflows in pkcs15-oberthur.c (bsc#1192000).
  • CVE-2021-42780: Fixed use after return in insert_pin() (bsc#1192005).
  • CVE-2021-42779: Fixed use after free in sc_file_valid() (bsc#1191992).

Non-security issues fixed:

  • Fixes segmentation fault in 'pkcs11-tool.c'. (bsc#1114649)
Record
SUSE-SU-2022:1156-1
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
opensc
Azure Linux:2
before 0.22.0-1
0.22.0-1
opensc
Debian:12
before 0.22.0-1
0.22.0-1
opensc
Debian:13
before 0.22.0-1
0.22.0-1
opensc
Debian:14
before 0.22.0-1
0.22.0-1
opensc
Debian:10
From an advisory covering 6 CVEs
before 0.19.0-1+deb10u2, plus listed versions
0.19.0-10.19.0-1+deb10u1
0.19.0-1+deb10u2
opensc
Debian:11
From an advisory covering 18 CVEs
before 0.21.0-1+deb11u1, plus listed versions
0.21.0-1
0.21.0-1+deb11u1
opensc
Mageia:8
From an advisory covering 4 CVEs
before 0.22.0-1.mga8
0.22.0-1.mga8
opensc
SUSE:HPE Helion OpenStack 8
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:OpenStack Cloud 8
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:OpenStack Cloud 9
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
Show 28 moreShow less
Affected packages
PackageAffectedFixed
opensc
SUSE:OpenStack Cloud Crowbar 8
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:OpenStack Cloud Crowbar 9
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server for SAP Applications 12 SP3
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server for SAP Applications 12 SP4
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server 12 SP2-BCL
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server 12 SP3-LTSS
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server 12 SP3-BCL
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server 12 SP4-LTSS
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server 12 SP5
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise Server for SAP Applications 12 SP5
From an advisory covering 4 CVEs
before 0.13.0-3.19.1
0.13.0-3.19.1
opensc
SUSE:Linux Enterprise High Performance Computing 15-ESPOS
From an advisory covering 13 CVEs
before 0.18.0-150000.3.23.1
0.18.0-150000.3.23.1
opensc
SUSE:Linux Enterprise High Performance Computing 15-LTSS
From an advisory covering 13 CVEs
before 0.18.0-150000.3.23.1
0.18.0-150000.3.23.1
opensc
SUSE:Linux Enterprise Server 15-LTSS
From an advisory covering 13 CVEs
before 0.18.0-150000.3.23.1
0.18.0-150000.3.23.1
opensc
SUSE:Linux Enterprise Server for SAP Applications 15
From an advisory covering 13 CVEs
before 0.18.0-150000.3.23.1
0.18.0-150000.3.23.1
opensc
SUSE:Linux Enterprise Module for Basesystem 15 SP3
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise Real Time 15 SP2
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise Server 15 SP1-BCL
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise Server 15 SP1-LTSS
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise Server for SAP Applications 15 SP1
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Linux Enterprise Micro 5.1
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
SUSE:Enterprise Storage 6
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
openSUSE:Leap 15.3
From an advisory covering 4 CVEs
before 0.19.0-150100.3.16.1
0.19.0-150100.3.16.1
opensc
Ubuntu:Pro:16.04:LTS
All versions, plus listed versions
0.15.0-1ubuntu10.15.0-1ubuntu1+esm10.15.0-1ubuntu1+esm20.15.0-1ubuntu1+esm3
None known
opensc
Ubuntu:Pro:18.04:LTS
All versions, plus listed versions
0.17.0-10.17.0-20.17.0-2build10.17.0-30.17.0-3ubuntu0.1~esm10.17.0-3ubuntu0.1~esm20.17.0-3ubuntu0.1~esm3
None known
opensc
Ubuntu:Pro:20.04:LTS
All versions, plus listed versions
0.19.0-20.20.0-10.20.0-20.20.0-30.20.0-3ubuntu0.1~esm10.20.0-3ubuntu0.1~esm20.20.0-3ubuntu0.1~esm30.20.0-3ubuntu0.1~esm4
None known
opensc
openSUSE:Tumbleweed
From an advisory covering 4 CVEs
before 0.22.0-1.1
0.22.0-1.1

History

History
RecordedChangedSources
affected, facts
first indexedCVE List, EUVD, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2021-42779 is a medium vulnerability (CVSS 5.3) in Opensc, published October 29, 2021. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 2.08%, the 81st percentile. Fixed in opensc 0.22.0-1.

References

Show 39 moreShow less
MoveEnter Open