Vulnerability · Published Feb 18, 2022 · Assigned by GitHub_M
CVE-2022-23645Out-of-bounds read in swtpm
Medium 6.2
In plain English
A medium-severity out-of-bounds read in swtpm from stefanberger. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 35% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
swtpm is a libtpms-based TPM emulator with socket, character device, and Linux CUSE interface. Versions prior to 0.5.3, 0.6.2, and 0.7.1 are vulnerable to out-of-bounds read. A specially crafted header of swtpm's state, where the blobheader's hdrsize indicator has an invalid value, may cause an out-of-bounds access when the byte array representing the state of the TPM is accessed. This will likely crash swtpm or prevent it from starting since the state cannot be understood. Users should upgrade to swtpm v0.5.3, v0.6.2, or v0.7.1 to receive a patch. There are currently no known workarounds.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| AlmaLinux:9 | swtpm | 0.7.0-3.20211109gitb79fd91.el9 | ALSA-2022:8100 |
| AlmaLinux:9 | swtpm-libs | 0.7.0-3.20211109gitb79fd91.el9 | ALSA-2022:8100 |
| AlmaLinux:9 | swtpm-tools | 0.7.0-3.20211109gitb79fd91.el9 | ALSA-2022:8100 |
| Debian:12 | swtpm | 0.7.1-1 | DEBIAN-CVE-2022-23645 |
| Debian:13 | swtpm | 0.7.1-1 | DEBIAN-CVE-2022-23645 |
| Debian:14 | swtpm | 0.7.1-1 | DEBIAN-CVE-2022-23645 |
| Rocky Linux:8 | hivex | 0:1.3.18-23.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | hivex | 0:1.3.18-23.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libguestfs | 1:1.44.0-9.module+el8.7.0+1084+97b81f61.rocky | RLSA-2022:7472 |
| Rocky Linux:8 | libguestfs-winsupport | 0:8.6-1.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libguestfs-winsupport | 0:8.6-1.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | libiscsi | 0:1.18.0-8.module+el8.4.0+534+4680a14e | RLSA-2022:7472 |
| Rocky Linux:8 | libiscsi | 0:1.18.0-8.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | libiscsi | 0:1.18.0-8.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libnbd | 0:1.6.0-5.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libnbd | 0:1.6.0-5.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | libtpms | 0:0.9.1-1.20211126git1ff6fe1f43.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libvirt | 0:8.0.0-10.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libvirt-dbus | 0:1.3.0-2.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | libvirt-dbus | 0:1.3.0-2.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | libvirt-dbus | 0:1.3.0-2.module+el8.4.0+534+4680a14e | RLSA-2022:7472 |
| Rocky Linux:8 | libvirt-python | 0:8.0.0-2.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | nbdkit | 0:1.24.0-4.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | netcf | 0:0.2.8-12.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | netcf | 0:0.2.8-12.module+el8.4.0+534+4680a14e | RLSA-2022:7472 |
| Rocky Linux:8 | netcf | 0:0.2.8-12.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | perl-Sys-Virt | 0:8.0.0-1.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | perl-Sys-Virt | 0:8.0.0-1.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | qemu-kvm | 5:6.2.0-20.module+el8.7.0+1084+97b81f61.2 | RLSA-2022:7472 |
| Rocky Linux:8 | seabios | 0:1.16.0-3.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | sgabios | 1:0.20170427git-3.module+el8.6.0+847+b490afdd | RLSA-2022:7472 |
| Rocky Linux:8 | sgabios | 1:0.20170427git-3.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | sgabios | 1:0.20170427git-3.module+el8.4.0+534+4680a14e | RLSA-2022:7472 |
| Rocky Linux:8 | supermin | 0:5.2.1-2.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | swtpm | 0:0.7.0-4.20211109gitb79fd91.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Rocky Linux:8 | virt-v2v | 1:1.42.0-21.module+el8.7.0+1084+97b81f61 | RLSA-2022:7472 |
| Ubuntu:22.04:LTS | swtpm | 0.6.3-0ubuntu3 | UBUNTU-CVE-2022-23645 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| stefanberger | swtpm | < 0.5.3>= 0.6.0, < 0.6.2= 0.7.0 |
Weakness: CWE-125 · Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
References
- https://github.com/stefanberger/swtpm/security/advisories/GHSA-2qgm-8xf4-3hqw x_refsource_CONFIRM
- https://github.com/stefanberger/swtpm/commit/9f740868fc36761de27df3935513bdebf8852d19 x_refsource_MISC
- https://github.com/stefanberger/swtpm/releases/tag/v0.5.3 x_refsource_MISC
- https://github.com/stefanberger/swtpm/releases/tag/v0.6.2 x_refsource_MISC
- https://github.com/stefanberger/swtpm/releases/tag/v0.7.1 x_refsource_MISC
- FEDORA-2022-12443a525c vendor-advisory, x_refsource_FEDORA