{"id":"CVE-2025-58356","aliases":["CVE-2025-58356","GHSA-hq76-6gh2-5g4q","GO-2025-4076"],"related":[],"kind":"vulnerability","state":"published","title":"Constellation allows insecure use of LUKS2 persistent storage partitions","summary":"Constellation is the first Confidential Kubernetes. The Constellation CVM image uses LUKS2-encrypted volumes for persistent storage. When opening an encrypted storage device, the CVM uses the libcryptsetup function crypt_activate_by_passhrase. If the VM is successful in opening the partition with the disk encryption key, it treats the volume as confidential. However, due to the unsafe handling of null keyslot algorithms in the cryptsetup 2.8.1, it is possible that the opened volume is not encrypted at all. Cryptsetup prior to version 2.8.1 does not report an error when processing LUKS2-formatted disks that use the cipher_null-ecb algorithm in the keyslot encryption field. This vulnerability is fixed in 2.24.0.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Constellation is the first Confidential Kubernetes. The Constellation CVM image uses LUKS2-encrypted volumes for persistent storage. When opening an encrypted storage device, the CVM uses the libcryptsetup function crypt_activate_by_passhrase. If the VM is successful in opening the partition with the disk encryption key, it treats the volume as confidential. However, due to the unsafe handling of null keyslot algorithms in the cryptsetup 2.8.1, it is possible that the opened volume is not encrypted at all. Cryptsetup prior to version 2.8.1 does not report an error when processing LUKS2-formatted disks that use the cipher_null-ecb algorithm in the keyslot encryption field. This vulnerability is fixed in 2.24.0.","source":"cvelist"},{"lang":"en","text":"### Summary\nA malicious host may provide a crafted LUKS2 volume to a confidential computing guest that is using the [OpenCryptDevice](https://github.com/edgelesssys/constellation/blob/6eff250f16f8ae48221d412550e4a64a4bf0d77b/csi/cryptmapper/cryptmapper.go#L89) feature. The guest will open the volume and write secret data using a volume key known to the attacker. The attacker can also pre-load data on the device, which could potentially compromise guest execution.\n\n\nLUKS2 volume metadata is not authenticated and supports null key-encryption algorithms, allowing an attacker to create a volume such that the volume:\n- Opens (cryptsetup open) without error using any passphrase or token\n- Records all writes in plaintext (or ciphertext with an attacker-known key)\n- Contains arbitrary data chosen by the attacker\n\n\n### Details\nThe Constellation CVM image uses LUKS2-encrypted volumes for persistent storage. When opening an encrypted storage device, the CVM uses the `libcryptsetup`  function [crypt_activate_by_passhrase](https://github.com/martinjungblut/go-cryptsetup/blob/fd0874fd07a6e477f0a4d18f2e80234983afe74f/device.go#L261). If the VM is successful in opening the partition with the disk encryption key, it treats the volume as confidential. However, due to the unsafe handling of null keyslot algorithms in the cryptsetup 2.8.1,  it is possible that the opened volume is not encrypted at all.\n\nCryptsetup prior to version 2.8.1 does not report an error when processing LUKS2-formatted disks that use the `cipher_null-ecb` algorithm in the keyslot `encryption` field.\n\n### Impact\n\nA LUKS2 disk encrypted with a master key, which is in turn encrypted with user passwords stored in some number of keyslots. By creating a malicious disk which sets the keyslot encryption algorithm to `”crypto_null-ecb”`, an attacker can construct a disk such that keyslot decryption does not depend in any way on the enclave-held secret data. When a confidential guest opens such a device using `cryptsetup open`, the mapped disk is created without error, and any further writes to the disk are encrypted using an attacker-controlled key.\n\n### Patches\n\nTo protect against this and similar attacks, Constellation now performs detached reading of LUKS headers. The header is copied into the encrypted memory of the CVM and then verified. The verified header is then used to open the encrypted LUKS device in detached header mode. This was implemented in https://github.com/edgelesssys/constellation/pull/3927 and release as part of [Constellation v2.24.0](https://github.com/edgelesssys/constellation/releases/tag/v2.24.0).","format":"markdown","source":"ghsa"},{"lang":"en","text":"Constellation has insecure LUKS2 persistent storage partitions which may be opened and used in github.com/edgelesssys/constellation","format":"markdown","source":"go"},{"lang":"es","text":"Constellation es el primer Kubernetes Confidencial. La imagen CVM de Constellation utiliza volúmenes cifrados con LUKS2 para almacenamiento persistente. Al abrir un dispositivo de almacenamiento cifrado, la CVM utiliza la función de libcryptsetup crypt_activate_by_passhrase. Si la VM logra abrir la partición con la clave de cifrado de disco, trata el volumen como confidencial. Sin embargo, debido al manejo inseguro de algoritmos de keyslot nulos en cryptsetup 2.8.1, es posible que el volumen abierto no esté cifrado en absoluto. Cryptsetup anterior a la versión 2.8.1 no informa un error al procesar discos formateados con LUKS2 que utilizan el algoritmo cipher_null-ecb en el campo de cifrado de keyslot. Esta vulnerabilidad está corregida en 2.24.0.","source":"nvd"}],"published":"2025-10-27T16:20:25.000Z","modified":"2026-10-08T11:10:00.250Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","score":8.3,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","score":8.3,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","rating":"HIGH"}],"cwes":["CWE-347","CWE-552"],"affected":[{"ranges":[{"version":"< 2.24.0","status":"affected"}],"vendor":"edgelesssys","product":"constellation","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.24.0"}],"ecosystem":"Go","package":"github.com/edgelesssys/constellation/v2","purl":"pkg:golang/github.com/edgelesssys/constellation/v2","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected"}],"ecosystem":"Go","package":"github.com/edgelesssys/constellation","purl":"pkg:golang/github.com/edgelesssys/constellation","source":"go"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.24.0"}],"ecosystem":"Go","package":"github.com/edgelesssys/constellation/v2","purl":"pkg:golang/github.com/edgelesssys/constellation/v2","source":"go"}],"references":[{"url":"https://github.com/edgelesssys/constellation/security/advisories/GHSA-hq76-6gh2-5g4q","tags":["advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/edgelesssys/constellation/pull/3927","tags":["fix","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/edgelesssys/constellation/releases/tag/v2.24.0","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://blog.trailofbits.com/2025/10/30/vulnerabilities-in-luks2-disk-encryption-for-confidential-vms/","tags":[],"sources":["cvelist","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-58356","tags":["advisory"],"sources":["ghsa","go"]},{"url":"https://github.com/edgelesssys/constellation/commit/bb8d2c8a5c0a0a6510d2cc43055be21f4a3ab83c","tags":["fix","web"],"sources":["ghsa","go"]},{"url":"https://blog.trailofbits.com/2025/10/30/vulnerabilities-in-luks2-disk-encryption-for-confidential-vms","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/edgelesssys/constellation","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2025-10-27T19:44:26.781Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-58356","url":"https://www.cve.org/CVERecord?id=CVE-2025-58356","licence":"CVE Terms of Use","modified":"2025-11-28T14:45:46.203Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-hq76-6gh2-5g4q","url":"https://github.com/advisories/GHSA-hq76-6gh2-5g4q","licence":"CC-BY-4.0","modified":"2025-12-01T16:21:13.746Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2025-4076","url":"https://pkg.go.dev/vuln/GO-2025-4076","licence":"CC-BY-4.0","modified":"2026-03-03T04:57:05.424Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-58356","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-58356","licence":"Public domain","modified":"2026-10-08T11:10:00.250Z"}],"updatedAt":"2026-11-25T22:59:06.898Z","epss":{"score":0.00107,"percentile":0.01255,"date":"2026-12-01T12:00:22.000Z"}}