{"id":"CVE-2026-22998","aliases":["CVE-2026-22998"],"related":[],"kind":"vulnerability","state":"published","title":"nvme-tcp: fix NULL pointer dereferences in nvmet_tcp_build_pdu_iovec","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nnvme-tcp: fix NULL pointer dereferences in nvmet_tcp_build_pdu_iovec\n\nCommit efa56305908b (\"nvmet-tcp: Fix a kernel panic when host sends an invalid H2C PDU length\")\nadded ttag bounds checking and data_offset\nvalidation in nvmet_tcp_handle_h2c_data_pdu(), but it did not validate\nwhether the command's data structures (cmd->req.sg and cmd->iov) have\nbeen properly initialized before processing H2C_DATA PDUs.\n\nThe nvmet_tcp_build_pdu_iovec() function dereferences these pointers\nwithout NULL checks. This can be triggered by sending H2C_DATA PDU\nimmediately after the ICREQ/ICRESP handshake, before\nsending a CONNECT command or NVMe write command.\n\nAttack vectors that trigger NULL pointer dereferences:\n1. H2C_DATA PDU sent before CONNECT → both pointers NULL\n2. H2C_DATA PDU for READ command → cmd->req.sg allocated, cmd->iov NULL\n3. H2C_DATA PDU for uninitialized command slot → both pointers NULL\n\nThe fix validates both cmd->req.sg and cmd->iov before calling\nnvmet_tcp_build_pdu_iovec(). Both checks are required because:\n- Uninitialized commands: both NULL\n- READ commands: cmd->req.sg allocated, cmd->iov NULL\n- WRITE commands: both allocated","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nnvme-tcp: fix NULL pointer dereferences in nvmet_tcp_build_pdu_iovec\n\nCommit efa56305908b (\"nvmet-tcp: Fix a kernel panic when host sends an invalid H2C PDU length\")\nadded ttag bounds checking and data_offset\nvalidation in nvmet_tcp_handle_h2c_data_pdu(), but it did not validate\nwhether the command's data structures (cmd->req.sg and cmd->iov) have\nbeen properly initialized before processing H2C_DATA PDUs.\n\nThe nvmet_tcp_build_pdu_iovec() function dereferences these pointers\nwithout NULL checks. This can be triggered by sending H2C_DATA PDU\nimmediately after the ICREQ/ICRESP handshake, before\nsending a CONNECT command or NVMe write command.\n\nAttack vectors that trigger NULL pointer dereferences:\n1. H2C_DATA PDU sent before CONNECT → both pointers NULL\n2. H2C_DATA PDU for READ command → cmd->req.sg allocated, cmd->iov NULL\n3. H2C_DATA PDU for uninitialized command slot → both pointers NULL\n\nThe fix validates both cmd->req.sg and cmd->iov before calling\nnvmet_tcp_build_pdu_iovec(). Both checks are required because:\n- Uninitialized commands: both NULL\n- READ commands: cmd->req.sg allocated, cmd->iov NULL\n- WRITE commands: both allocated","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nnvme-tcp: soluciona desreferencias de puntero NULL en nvmet_tcp_build_pdu_iovec\n\nEl commit efa56305908b ('nvmet-tcp: Soluciona un pánico del kernel cuando el host envía una longitud de PDU H2C inválida') añadió la comprobación de límites de ttag y la validación de data_offset en nvmet_tcp_handle_h2c_data_pdu(), pero no validó si las estructuras de datos del comando (cmd-&gt;req.sg y cmd-&gt;iov) han sido inicializadas correctamente antes de procesar las PDUs H2C_DATA.\n\nLa función nvmet_tcp_build_pdu_iovec() desreferencia estos punteros sin comprobaciones de NULL. Esto puede ser provocado enviando una PDU H2C_DATA inmediatamente después del handshake ICREQ/ICRESP, antes de enviar un comando CONNECT o un comando de escritura NVMe.\n\nVectores de ataque que provocan desreferencias de puntero NULL:\n1. PDU H2C_DATA enviada antes de CONNECT ? ambos punteros NULL\n2. PDU H2C_DATA para comando READ ? cmd-&gt;req.sg asignado, cmd-&gt;iov NULL\n3. PDU H2C_DATA para slot de comando no inicializado ? ambos punteros NULL\n\nLa solución valida tanto cmd-&gt;req.sg como cmd-&gt;iov antes de llamar a nvmet_tcp_build_pdu_iovec(). Ambas comprobaciones son necesarias porque:\n- Comandos no inicializados: ambos NULL\n- Comandos READ: cmd-&gt;req.sg asignado, cmd-&gt;iov NULL\n- Comandos WRITE: ambos asignados","source":"nvd"}],"published":"2026-01-25T14:36:12.935Z","modified":"2026-10-19T19:17:31.360Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"}],"cwes":["CWE-476"],"affected":[{"ranges":[{"type":"git","introduced":"f775f2621c2ac5cc3a0b3a64665dad4fb146e510","fixed":"baabe43a0edefac8cd7b981ff87f967f6034dafe","status":"affected"},{"type":"git","introduced":"4cb3cf7177ae3666be7fb27d4ad4d72a295fb02d","fixed":"76abc83a9d25593c2b7613c549413079c14a4686","status":"affected"},{"type":"git","introduced":"2871aa407007f6f531fae181ad252486e022df42","fixed":"7d75570002929d20e40110d6b03e46202c9d1bc7","status":"affected"},{"type":"git","introduced":"24e05760186dc070d3db190ca61efdbce23afc88","fixed":"fdecd3b6aac10d5a18d0dc500fe57f8648b66cd4","status":"affected"},{"type":"git","introduced":"efa56305908ba20de2104f1b8508c6a7401833be","fixed":"3def5243150716be86599c2a1767c29c68838b6d","status":"affected"},{"type":"git","introduced":"efa56305908ba20de2104f1b8508c6a7401833be","fixed":"374b095e265fa27465f34780e0eb162ff1bef913","status":"affected"},{"type":"git","introduced":"efa56305908ba20de2104f1b8508c6a7401833be","fixed":"32b63acd78f577b332d976aa06b56e70d054cbba","status":"affected"},{"type":"git","version":"ee5e7632e981673f42a50ade25e71e612e543d9d","status":"affected"},{"type":"git","version":"70154e8d015c9b4fb56c1a2ef1fc8b83d45c7f68","status":"affected"},{"type":"semver","introduced":"5.10.209","fixed":"5.10.249","status":"affected"},{"type":"semver","introduced":"5.15.148","fixed":"5.15.199","status":"affected"},{"type":"semver","introduced":"6.1.75","fixed":"6.1.162","status":"affected"},{"type":"semver","introduced":"6.6.14","fixed":"6.6.122","status":"affected"},{"type":"semver","introduced":"5.4.268","fixed":"5.5","status":"affected"},{"type":"semver","introduced":"6.7.2","fixed":"6.8","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"6.8","status":"affected"},{"type":"semver","introduced":"0","fixed":"6.8","status":"unaffected"},{"type":"semver","introduced":"5.10.249","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.199","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.1.162","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.122","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.67","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.7","lastAffected":"6.18.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.19","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"5.4.268","fixed":"5.5"},{"status":"affected","introduced":"5.10.209","fixed":"5.10.249"},{"status":"affected","introduced":"5.15.148","fixed":"5.15.199"},{"status":"affected","introduced":"6.1.75","fixed":"6.1.162"},{"status":"affected","introduced":"6.6.14","fixed":"6.6.122"},{"status":"affected","introduced":"6.7.2","fixed":"6.12.67"},{"status":"affected","introduced":"6.13","fixed":"6.18.7"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/baabe43a0edefac8cd7b981ff87f967f6034dafe","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/76abc83a9d25593c2b7613c549413079c14a4686","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7d75570002929d20e40110d6b03e46202c9d1bc7","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/fdecd3b6aac10d5a18d0dc500fe57f8648b66cd4","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/3def5243150716be86599c2a1767c29c68838b6d","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/374b095e265fa27465f34780e0eb162ff1bef913","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/32b63acd78f577b332d976aa06b56e70d054cbba","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-06-16T20:38:02.086Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-22998","url":"https://www.cve.org/CVERecord?id=CVE-2026-22998","licence":"CVE Terms of Use","modified":"2026-10-19T18:25:26.863Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-22998","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-22998","licence":"Public domain","modified":"2026-10-19T19:17:31.360Z"}],"updatedAt":"2026-11-25T22:59:13.168Z","epss":{"score":0.00778,"percentile":0.57076,"date":"2026-12-01T12:00:22.000Z"}}