The Oberthur smart card software driver in OpenSC before 0.21.0-rc1 has a heap-based buffer overflow in sc_oberthur_read_file. References: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=24316 https://github.com/OpenSC/OpenSC/commit/6903aebfddc466d966c7b865fae34572bf3ed23e
Created opensc tracking bugs for this issue: Affects: epel-6 [bug 1885949] Affects: fedora-all [bug 1885948]
Flaw summary: sc_oberthur_read_file() in src/libopensc/pkcs15-oberthur.c attempts to read an invalid record from the card reader APDU interface by reading a record greater than file->record_count, causing an out-of-bounds write.
Mitigation: This flaw can be mitigated in cases where you can use opensc without the Oberthur driver enabled. In such cases, the vulnerable driver can be disabled by specifying them in /etc/opensc.conf card_drivers field in allowlist fashion. One such example: ``` app default { card_drivers = cac, cac1, PIV-II; } ``` This would only enable the cac, cac1, and PIV-II smart card drivers, and all others would be disabled, including the Oberthur driver. With the Oberthur driver disabled, this flaw is mitigated. It is important to list all drivers that you need in the card_drivers field so that they are not disabled too.
This issue has been addressed in the following products: Red Hat Enterprise Linux 8 Via RHSA-2021:1600 https://access.redhat.com/errata/RHSA-2021:1600
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s): https://access.redhat.com/security/cve/cve-2020-26570