Skip to content

[ciqlts9_2] Multiple patches tested (9 commits) - #1727

Merged
bmastbergen merged 9 commits into
ciqlts9_2from
{bmastbergen_cves}_ciqlts9_2
Oct 23, 2026
Merged

bmastbergen merged 9 commits into
ciqlts9_2from
{bmastbergen_cves}_ciqlts9_2

Conversation

@ciq-kernel-automation

@ciq-kernel-automation ciq-kernel-automation Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Summary

This PR has been automatically created after successful completion of all CI stages.

Commit Message(s)

nvmet: Introduce nvmet_req_transfer_len()

jira VULN-200788
cve-pre CVE-2026-72130
commit-author Damien Le Moal <dlemoal@kernel.org>
commit 43043c9b97258a008b3402cfbbf1c5d82151c77f
nvme: Add the DHCHAP maximum HD IDs

jira VULN-220357
cve-pre CVE-2026-90230
commit-author Alistair Francis <alistair.francis@wdc.com>
commit 09e8f0f93491c6be867f32d4edc0b16fb5da785e
nvmet-auth: validate reply message payload bounds against transfer length

jira VULN-194523
cve CVE-2026-64319
commit-author Tianchu Chen <flynnnchen@tencent.com>
commit 3a413ece2504c70aa34a20be4dafec04e8c741f9
upstream-diff nvmet_auth_reply returns u16 in this kernel, and uses
              status (rather than dhchap_status) in nvmet_execute_auth_send
nvmet-auth: reject short AUTH_RECEIVE buffers

jira VULN-200788
cve CVE-2026-72130
commit-author Michael Bommarito <michael.bommarito@gmail.com>
commit 779575bc35c687697ba69e904f2cd22e60112534
nvme-auth: use crypto_memneq for DH-HMAC-CHAP response comparison

commit-author Xixin Liu <liuxixin@kylinos.cn>
commit 3a6d89836ab09d53f4c32c57588689a378ce4363
upstream-diff crypto_memneq is in crypto/algapi.h in this kernel
nvmet-auth: zero the AUTH_RECEIVE response buffer

jira VULN-223592
cve CVE-2026-80791
commit-author Bryam Vargas <hexlabsecurity@proton.me>
commit 3ddcfb013322aa37eaa7a0d344b73079c38dfa21
nvmet: fix heap out-of-bounds read in nvmet_auth_negotiate()

jira VULN-220357
cve CVE-2026-90230
commit-author Guixin Liu <kanie@linux.alibaba.com>
commit 5bb96cc218835769ab74ec7f3ea2bf81fbffe955
upstream-diff nvmet_auth_negotiate returns u16 in this kernel, and
              uses status rather than dhchap_status in
              nvmet_execute_auth_send
nvmet-auth: fix out-of-bounds write in nvmet_auth_challenge()

jira VULN-223593
cve CVE-2026-98725
commit-author Weiming Shi <bestswngs@gmail.com>
commit fa6778e030bed9841ddcdf96bc7018da9ac03562
net/sched: cls_api: Handle TC_ACT_CONSUMED in tcf_qevent_handle

jira VULN-193886
cve CVE-2026-64530
commit-author Jamal Hadi Salim <jhs@mojatatu.com>
commit a8a02897f2b479127db261de05cbf0c28b98d159

Test Results

✅ Build Stage

Architecture Build Time Total Time
x86_64 15m 53s 16m 38s
aarch64 17m 59s 18m 59s

✅ Boot Verification

✅ Kernel Selftests

Architecture Passed Failed Compared Against Status
x86_64 173 25 ciqlts9_2 ✅ No regressions
aarch64 141 27 ciqlts9_2 ✅ No regressions

✅ LTP Results

Architecture Passed Failed Compared Against Status
x86_64 1439 81 ciqlts9_2 ✅ No regressions
aarch64 1409 83 ciqlts9_2 ✅ No regressions

🤖 This PR was automatically generated by GitHub Actions
Run ID: 39844490298

jira VULN-200788
cve-pre CVE-2026-72130
commit-author Damien Le Moal <dlemoal@kernel.org>
commit 43043c9

Add the new function nvmet_req_transfer_len() to parse a request command
to extract the transfer length of the command. This function
implementation relies on multiple helper functions for parsing I/O
commands (nvmet_io_cmd_transfer_len()), admin commands
(nvmet_admin_cmd_data_len()) and fabrics connect commands
(nvmet_connect_cmd_data_len).

	Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Tested-by: Rick Wertenbroek <rick.wertenbroek@gmail.com>
	Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 43043c9)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
@ciq-kernel-automation ciq-kernel-automation Bot added the created-by-kernelci Tag PRs that were automatically created when a user branch was pushed to the repo (kernelCI) label Oct 22, 2026
@github-actions

Copy link
Copy Markdown

🤖 Validation Checks In Progress Workflow run: https://github.com/ctrliq/kernel-src-tree/actions/runs/39710961776

@github-actions

Copy link
Copy Markdown

🔍 Diffofdiffs: 1 of 3 backports differs from upstream

View the diffofdiffs report.

Open to anyone signed in to GitHub. Report expires 2027-01-20 02:14 UTC.

# Subject Backport Upstream
1 nvmet: Introduce nvmet_req_transfer_len() 01f541531376 43043c9b9725

Checked PR revision 1cb1fbc4117b against base de6d5aa1d7e5.

@github-actions

Copy link
Copy Markdown

✅ Validation checks completed successfully View full results: https://github.com/ctrliq/kernel-src-tree/actions/runs/39710961776

@PlaidCat
PlaidCat requested a review from a team October 22, 2026 13:44
jira VULN-220357
cve-pre CVE-2026-90230
commit-author Alistair Francis <alistair.francis@wdc.com>
commit 09e8f0f

In preperation for using DHCHAP length in upcoming host and target
patches let's add the hash and diffie-hellman ID length macros.

	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Reviewed-by: Yunje Shin <ioerts@kookmin.ac.kr>
	Reviewed-by: Hannes Reinecke <hare@suse.de>
	Reviewed-by: Chris Leech <cleech@redhat.com>
	Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 09e8f0f)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
…ngth

jira VULN-194523
cve CVE-2026-64319
commit-author Tianchu Chen <flynnnchen@tencent.com>
commit 3a413ec
upstream-diff nvmet_auth_reply returns u16 in this kernel, and uses
              status (rather than dhchap_status) in nvmet_execute_auth_send

nvmet_auth_reply() accesses the variable-length rval[] array using
attacker-controlled hl (hash length) and dhvlen (DH value length) fields
without verifying they fit within the allocated buffer of tl bytes.

A malicious NVMe-oF initiator can craft a DHCHAP_REPLY message with a
small transfer length but large hl/dhvlen values, causing out-of-bounds
heap reads when the target processes the DH public key (rval + 2*hl) or
performs the host response memcmp.

With DH authentication configured, the OOB pointer is passed directly to
sg_init_one() and read by crypto_kpp_compute_shared_secret(), reaching
up to 526 bytes past the buffer. This is exploitable pre-authentication.

Add bounds validation ensuring sizeof(*data) + 2*hl + dhvlen <= tl before
any access to the variable-length fields.

Discovered by Atuin - Automated Vulnerability Discovery Engine.

Fixes: db1312d ("nvmet: implement basic In-Band Authentication")
	Cc: stable@vger.kernel.org
	Reviewed-by: Hannes Reinecke <hare@kernel.org>
	Signed-off-by: Tianchu Chen <flynnnchen@tencent.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 3a413ec)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
jira VULN-200788
cve CVE-2026-72130
commit-author Michael Bommarito <michael.bommarito@gmail.com>
commit 779575b

nvmet_execute_auth_receive() trusts the AUTH_RECEIVE allocation length
after checking only that it is nonzero and matches the transfer length.
In the SUCCESS1 and FAILURE1/default states, that lets a remote NVMe-oF
initiator reach the fixed-size DH-HMAC-CHAP response builders with a
kmalloc() buffer shorter than the response, so nvmet_auth_success1() and
nvmet_auth_failure1() write past the allocation; both only WARN_ON the
short length and then format the message anyway.

Impact: A remote NVMe-oF initiator with access to an auth-enabled target
can trigger a 16-byte heap out-of-bounds write via a one-byte
AUTH_RECEIVE allocation length.

Compute the minimum response length for the current DH-HMAC-CHAP step in
nvmet_auth_receive_data_len() and report a zero data length when the
host-supplied allocation length is shorter, so the existing zero-length
check in nvmet_execute_auth_receive() rejects the command before any
builder runs. The SUCCESS1 minimum is sizeof(struct
nvmf_auth_dhchap_success1_data) plus the HMAC hash length, because the
response hash is written into the rval[] flexible-array tail, so the
minimum is state dependent rather than a flat sizeof. CHALLENGE keeps its
existing variable-length guard in nvmet_auth_challenge().

This is reachable only when in-band DH-HMAC-CHAP authentication is
configured on the target.

Fixes: db1312d ("nvmet: implement basic In-Band Authentication")
	Cc: stable@vger.kernel.org
Assisted-by: Codex:gpt-5-5-xhigh
Assisted-by: Claude:claude-opus-4-8
	Reviewed-by: Hannes Reinecke <hare@kernel.org>
	Signed-off-by: Michael Bommarito <michael.bommarito@gmail.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 779575b)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
commit-author Xixin Liu <liuxixin@kylinos.cn>
commit 3a6d898
upstream-diff crypto_memneq is in crypto/algapi.h in this kernel

DH-HMAC-CHAP authentication compares HMAC response digests with memcmp().
Standard memcmp() may stop at the first differing byte, which can leak
timing information to a remote attacker and allow incremental recovery
of the expected digest.

Use crypto_memneq() for constant-time comparison on both the host path
that validates the controller Success1 response and the target path that
validates the host Reply digest.  Other memcmp() uses in the NVMe auth
code (e.g. fixed string prefix checks) are not security-sensitive and
are left unchanged.

	Signed-off-by: Xixin Liu <liuxixin@kylinos.cn>
	Reviewed-by: Hannes Reinecke <hare@kernel.org>
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 3a6d898)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
jira VULN-223592
cve CVE-2026-80791
commit-author Bryam Vargas <hexlabsecurity@proton.me>
commit 3ddcfb0

nvmet_execute_auth_receive() allocates the response buffer with kmalloc()
sized by the host-supplied AUTH_RECEIVE allocation length, but the
DH-HMAC-CHAP builders write only a fixed-size message into it. The full
allocation length is then copied to the wire by nvmet_copy_to_sgl(), so a
remote initiator receives the bytes past the built message -- up to nearly
a page of uninitialized slab -- during the pre-authentication handshake.

Allocate the buffer with kzalloc() so the unwritten tail is zeroed before
it is sent; conforming responses are unaffected.

Fixes: db1312d ("nvmet: implement basic In-Band Authentication")
	Cc: stable@vger.kernel.org
	Signed-off-by: Bryam Vargas <hexlabsecurity@proton.me>
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 3ddcfb0)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
jira VULN-220357
cve CVE-2026-90230
commit-author Guixin Liu <kanie@linux.alibaba.com>
commit 5bb96cc
upstream-diff nvmet_auth_negotiate returns u16 in this kernel, and
              uses status rather than dhchap_status in
              nvmet_execute_auth_send

nvmet_execute_auth_send() allocates the DH-HMAC-CHAP message buffer with
the host-supplied transfer length (tl) and hands it to
nvmet_auth_negotiate() without passing tl along. nvmet_auth_negotiate()
then reads the negotiate header and, for each of the halen hash
identifiers and dhlen DH group identifiers, indexes into the fixed
idlist[60] array (hashes at idlist[0..halen), groups at idlist[30..]).

Neither the transfer length nor halen/dhlen is validated. A malicious or
non-conformant host can report a tl smaller than the negotiate structure,
or a halen/dhlen larger than the array (both are u8, up to 255), making
the loops read past the end of the allocated buffer (heap out-of-bounds
read). The sibling nvmet_auth_reply() already validates tl against the
structure size; the negotiate path did not.

Pass tl into nvmet_auth_negotiate(), reject a tl that does not cover the
negotiate data plus one full protocol descriptor, and reject halen/dhlen
larger than NVME_AUTH_DHCHAP_MAX_DH_IDS.

Fixes: db1312d ("nvmet: implement basic In-Band Authentication")
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Reviewed-by: Hannes Reinecke <hare@kernel.org>
	Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 5bb96cc)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
jira VULN-223593
cve CVE-2026-98725
commit-author Weiming Shi <bestswngs@gmail.com>
commit fa6778e

nvmet_auth_challenge() receives its output buffer as a void pointer.
sizeof(*d) therefore evaluates to one with GCC and undercounts the fixed
challenge header by 15 bytes.  A short AUTH_RECEIVE buffer can pass the
check before the challenge is copied past the end of its allocation.

Use the typed challenge pointer when calculating the response size.

  BUG: KASAN: slab-out-of-bounds in nvmet_execute_auth_receive (drivers/nvme/target/fabrics-cmd-auth.c:442 drivers/nvme/target/fabrics-cmd-auth.c:569)
  Write of size 32 by task kworker/1:1H/64
  Workqueue: nvmet_tcp_wq nvmet_tcp_io_work
  Call Trace:
  nvmet_execute_auth_receive (drivers/nvme/target/fabrics-cmd-auth.c:442 drivers/nvme/target/fabrics-cmd-auth.c:569)
  nvmet_tcp_try_recv_pdu (drivers/nvme/target/tcp.c:1119 drivers/nvme/target/tcp.c:1243)
  nvmet_tcp_io_work (drivers/nvme/target/tcp.c:1350 drivers/nvme/target/tcp.c:1382 drivers/nvme/target/tcp.c:1445)
  process_one_work (kernel/workqueue.c:3322)
  worker_thread (kernel/workqueue.c:3405 kernel/workqueue.c:3486)
  kthread (kernel/kthread.c:436)
  ret_from_fork (arch/x86/kernel/process.c:158)
  ret_from_fork_asm (arch/x86/entry/entry_64.S:245)
  The buggy address is located 16 bytes inside of
   allocated 33-byte region [ffff888000554e80, ffff888000554ea1)
  Kernel panic - not syncing: KASAN: panic_on_warn set ...

	Cc: stable@vger.kernel.org
Fixes: db1312d ("nvmet: implement basic In-Band Authentication")
	Reported-by: co+77553a7fc66ac133@bugs.sh
Closes: https://lore.kernel.org/all/Ah6QavQXwvshtqyUcYD1P1R7XE0ND9fB7lbV@bugs.sh/
Assisted-by: Codex:gpt-5.6
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Reviewed-by: Hannes Reinecke <hare@kernel.org>
	Signed-off-by: Weiming Shi <bestswngs@gmail.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit fa6778e)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
jira VULN-193886
cve CVE-2026-64530
commit-author Jamal Hadi Salim <jhs@mojatatu.com>
commit a8a0289

tcf_classify() can return TC_ACT_CONSUMED while the skb is held by the
defragmentation engine (e.g. act_ct on out-of-order fragments). When
that happens the skb is no longer owned by the caller and must not be
touched again.

tcf_qevent_handle() did not handle TC_ACT_CONSUMED: it fell through the
switch and returned the skb to the caller as if classification had
passed. The only qdisc that wires up qevents today is RED, via three call sites
(qe_mark on RED_PROB_MARK/HARD_MARK, qe_early_drop on congestion_drop)
red_enqueue() was continuing to operate on an skb it no longer owns  in this
case -- enqueueing it, dropping it, or updating statistics. Resulting in a UAF.

  tc qdisc add dev eth0 root handle 1: red ... qevent early_drop block 10
  tc filter add block 10 ... action ct

  (with ct defrag enabled and traffic that produces out-of-order
  fragments, e.g. a fragmented UDP stream)

Handle TC_ACT_CONSUMED in tcf_qevent_handle() the same way the ingress
and egress fast paths do: treat it as stolen and return NULL without
touching the skb. Unlike the TC_ACT_STOLEN case, the skb must not be
dropped/freed here, as it is no longer owned by us.

Fixes: 3f14b37 ("net/sched: act_ct: fix skb leak and crash on ooo frags")
	Reported-by: Zero Day Initiative <zdi-disclosures@trendmicro.com>
	Tested-by: Victor Nogueira <victor@mojatatu.com>
	Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com>
Link: https://patch.msgid.link/20260620130749.226642-1-jhs@mojatatu.com
	Signed-off-by: Jakub Kicinski <kuba@kernel.org>
(cherry picked from commit a8a0289)
	Signed-off-by: Brett Mastbergen <bmastbergen@ciq.com>
@bmastbergen
bmastbergen force-pushed the {bmastbergen_cves}_ciqlts9_2 branch from 1cb1fbc to 212b8d3 Compare October 22, 2026 19:55
@bmastbergen

Copy link
Copy Markdown
Collaborator

Based on some slack feedback from @PlaidCat I ended up expanding the nvme changset to 8 which gets us a few more CVE and a better end result.

212b8d37169c5 net/sched: cls_api: Handle TC_ACT_CONSUMED in tcf_qevent_handle
9443f266ad76a nvmet-auth: fix out-of-bounds write in nvmet_auth_challenge()
2e6e00853f8ac nvmet: fix heap out-of-bounds read in nvmet_auth_negotiate()
a2c472a5f8a35 nvmet-auth: zero the AUTH_RECEIVE response buffer
214fa2569ff81 nvme-auth: use crypto_memneq for DH-HMAC-CHAP response comparison
324a08b86a6f8 nvmet-auth: reject short AUTH_RECEIVE buffers
5df10ddd12f9c nvmet-auth: validate reply message payload bounds against transfer length
5c13827019013 nvme: Add the DHCHAP maximum HD IDs
01f5415313764 nvmet: Introduce nvmet_req_transfer_len()

@github-actions

Copy link
Copy Markdown

🔍 Diffofdiffs: 5 of 9 backports differ from upstream

View the diffofdiffs report.

Open to anyone signed in to GitHub. Report expires 2027-01-20 19:55 UTC.

# Subject Backport Upstream
1 nvmet: Introduce nvmet_req_transfer_len() 01f541531376 43043c9b9725
2 nvme: Add the DHCHAP maximum HD IDs 5c1382701901 09e8f0f93491
3 nvmet-auth: validate reply message payload bounds against transfer length 5df10ddd12f9 3a413ece2504
4 nvme-auth: use crypto_memneq for DH-HMAC-CHAP response comparison 214fa2569ff8 3a6d89836ab0
5 nvmet: fix heap out-of-bounds read in nvmet_auth_negotiate() 2e6e00853f8a 5bb96cc21883

Checked PR revision 212b8d37169c against base de6d5aa1d7e5.

@github-actions

Copy link
Copy Markdown

🤖 Validation Checks In Progress Workflow run: https://github.com/ctrliq/kernel-src-tree/actions/runs/39845681509

@github-actions

Copy link
Copy Markdown

✅ Validation checks completed successfully View full results: https://github.com/ctrliq/kernel-src-tree/actions/runs/39845681509

@bmastbergen bmastbergen changed the title [ciqlts9_2] Multiple patches tested (3 commits) [ciqlts9_2] Multiple patches tested (9 commits) Oct 22, 2026

@PlaidCat PlaidCat left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@PlaidCat
PlaidCat requested a review from a team October 22, 2026 20:49
@bmastbergen
bmastbergen merged commit 85353b4 into ciqlts9_2 Oct 23, 2026
5 of 6 checks passed
@bmastbergen
bmastbergen deleted the {bmastbergen_cves}_ciqlts9_2 branch October 23, 2026 12:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

created-by-kernelci Tag PRs that were automatically created when a user branch was pushed to the repo (kernelCI)

Development

Successfully merging this pull request may close these issues.

3 participants