Security Vulnerability Report
中文
CVE-2026-21444 CVSS 5.5 MEDIUM

CVE-2026-21444

Published: 2026-01-02 19:15:49
Last Modified: 2026-02-25 15:18:34

Description

libtpms, a library that provides software emulation of a Trusted Platform Module, has a flaw in versions 0.10.0 and 0.10.1. The commonly used integration of libtpms with OpenSSL 3.x contained a vulnerability related to the returned IV (initialization vector) when certain symmetric ciphers were used. Instead of returning the last IV it returned the initial IV to the caller, thus weakening the subsequent encryption and decryption steps. The highest threat from this vulnerability is to data confidentiality. Version 0.10.2 fixes the issue. No known workarounds are available.

CVSS Details

CVSS Score
5.5
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N

Configurations (Affected Products)

cpe:2.3:a:libtpms_project:libtpms:*:*:*:*:*:*:*:* - VULNERABLE
libtpms 0.10.0
libtpms 0.10.1

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// CVE-2026-21444 Proof of Concept // This PoC demonstrates the IV handling issue in libtpms // Compile: gcc -o poc poc.c -ltpms -lssl -lcrypto #include <stdio.h> #include <stdlib.h> #include <string.h> #include <tpms/tpm_library.h> #include <openssl/evp.h> #define TEST_DATA_SIZE 64 void demonstrate_iv_mismatch() { printf("[*] CVE-2026-21444 PoC - libtpms IV Handling Issue\n"); printf("[*] Affected versions: libtpms 0.10.0, 0.10.1\n\n"); // Simulate the vulnerable behavior unsigned char initial_iv[16] = {0}; unsigned char incorrect_iv[16] = {0}; unsigned char correct_iv[16] = {0}; unsigned char plaintext[TEST_DATA_SIZE] = "Sensitive data requiring encryption"; unsigned char ciphertext[TEST_DATA_SIZE]; // Initialize OpenSSL context EVP_CIPHER_CTX *ctx = EVP_CIPHER_CTX_new(); if (!ctx) { printf("[-] Failed to create cipher context\n"); return; } // Set initial IV memcpy(initial_iv, (unsigned char[]){0x12, 0x34, 0x56, 0x78, 0x9A, 0xBC, 0xDE, 0xF0}, 8); // Initialize encryption with initial IV EVP_EncryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, (unsigned char*)"0123456789ABCDEF", initial_iv); int len = 0; int ciphertext_len = 0; // Encrypt data EVP_EncryptUpdate(ctx, ciphertext, &len, plaintext, TEST_DATA_SIZE); ciphertext_len = len; EVP_EncryptFinal_ex(ctx, ciphertext + len, &len); ciphertext_len += len; // Get IV after encryption EVP_CIPHER_CTX_get_iv(ctx, correct_iv, 16); // Simulate vulnerable behavior - libtpms returns initial IV instead memcpy(incorrect_iv, initial_iv, 16); printf("[+] Initial IV: "); for(int i = 0; i < 16; i++) printf("%02X ", initial_iv[i]); printf("\n"); printf("[+] Correct IV (post): "); for(int i = 0; i < 16; i++) printf("%02X ", correct_iv[i]); printf("\n"); printf("[!] Vulnerable returns: "); for(int i = 0; i < 16; i++) printf("%02X ", incorrect_iv[i]); printf("\n\n"); printf("[-] VULNERABLE: libtpms returns initial IV instead of final IV\n"); printf("[-] Impact: Subsequent encryption/decryption uses incorrect IV\n"); printf("[-] This weakens CBC mode encryption chain and data confidentiality\n"); EVP_CIPHER_CTX_free(ctx); printf("\n[*] Recommendation: Upgrade to libtpms >= 0.10.2\n"); } int main(int argc, char *argv[]) { demonstrate_iv_mismatch(); return 0; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-21444", "sourceIdentifier": "[email protected]", "published": "2026-01-02T19:15:48.763", "lastModified": "2026-02-25T15:18:34.413", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "libtpms, a library that provides software emulation of a Trusted Platform Module, has a flaw in versions 0.10.0 and 0.10.1. The commonly used integration of libtpms with OpenSSL 3.x contained a vulnerability related to the returned IV (initialization vector) when certain symmetric ciphers were used. Instead of returning the last IV it returned the initial IV to the caller, thus weakening the subsequent encryption and decryption steps. The highest threat from this vulnerability is to data confidentiality. Version 0.10.2 fixes the issue. No known workarounds are available."}, {"lang": "es", "value": "libtpms, una biblioteca que proporciona emulación de software de un Módulo de Plataforma Confiable, tiene un fallo en las versiones 0.10.0 y 0.10.1. La integración comúnmente utilizada de libtpms con OpenSSL 3.x contenía una vulnerabilidad relacionada con el IV (vector de inicialización) devuelto cuando se utilizaban ciertos cifrados simétricos. En lugar de devolver el último IV, devolvía el IV inicial al llamador, debilitando así los pasos subsiguientes de cifrado y descifrado. La mayor amenaza de esta vulnerabilidad es para la confidencialidad de los datos. La versión 0.10.2 corrige el problema. No se conocen soluciones alternativas disponibles."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N", "baseScore": 5.5, "baseSeverity": "MEDIUM", "attackVector": "LOCAL", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "NONE", "availabilityImpact": "NONE"}, "exploitabilityScore": 1.8, "impactScore": 3.6}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-327"}, {"lang": "en", "value": "CWE-330"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:libtpms_project:libtpms:*:*:*:*:*:*:*:*", "versionStartIncluding": "0.10.0", "versionEndExcluding": "0.10.2", "matchCriteriaId": "E714F6E7-EE9D-46ED-B5CF-52EDC67277A8"}]}]}], "references": [{"url": "https://github.com/stefanberger/libtpms/commit/33c9ff074cb16c1841ce7d7f33643c17c426743a", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/stefanberger/libtpms/issues/541", "source": "[email protected]", "tags": ["Exploit", "Issue Tracking"]}, {"url": "https://github.com/stefanberger/libtpms/security/advisories/GHSA-7jxr-4j3g-p34f", "source": "[email protected]", "tags": ["Patch", "Vendor Advisory"]}]}}