Skip to content

[ciqcbr7_9] sctp: don't free the ASCONF's own transport in DEL-IP processing - #1517

Merged
PlaidCat merged 1 commit into
ciqcbr7_9from
{jmaple}_ciqcbr7_9
Aug 7, 2026
Merged

[ciqcbr7_9] sctp: don't free the ASCONF's own transport in DEL-IP processing#1517
PlaidCat merged 1 commit into
ciqcbr7_9from
{jmaple}_ciqcbr7_9

Conversation

@ciq-kernel-automation

Copy link
Copy Markdown

Summary

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

Commit Message(s)

sctp: don't free the ASCONF's own transport in DEL-IP processing

jira VULN-196073
cve CVE-2026-64564
commit-author Jun Yang <junvyyang@tencent.com>
commit 9b2854f86f0b56e9027d68e7a3fc909d1a9b566f

Test Results

✅ Build Stage

  • Status: Passed (x86_64)

  • Build Time: 13m 13s

  • Total Time: 14m 19s

  • View build logs

✅ Boot Verification


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

jira VULN-196073
cve CVE-2026-64564
commit-author Jun Yang <junvyyang@tencent.com>
commit 9b2854f

sctp_process_asconf() caches the transport the ASCONF chunk is processed
against in asconf->transport (== chunk->transport, set once in sctp_rcv()).
For an ASCONF located through its Address Parameter by
__sctp_rcv_asconf_lookup(), that cached transport corresponds to the
Address Parameter, which need not be the packet's source address.

sctp_process_asconf_param() rejects a DEL-IP for the packet source address
(ADDIP D8, SCTP_ERROR_DEL_SRC_IP), but nothing protects asconf->transport.
A single ASCONF can therefore carry, in order:

    [Address Parameter L] [DEL-IP L] [DEL-IP 0.0.0.0]

where L differs from the source. The DEL-IP for L passes the D8 check and
calls sctp_assoc_rm_peer() on the transport that asconf->transport still
points at, freeing it (RCU-deferred). The following wildcard DEL-IP then
reuses the now-dangling asconf->transport in sctp_assoc_set_primary() and
sctp_assoc_del_nonprimary_peers(): set_primary() dereferences the freed
transport (->ipaddr, ->state) and plants the dangling pointer into
asoc->peer.primary_path / active_path, and del_nonprimary_peers(), keeping
only the pointer that is no longer on the list, removes every real
transport, leaving the association with a transport_count of 0 and
primary_path/active_path pointing at freed memory.

Reject a DEL-IP that targets the transport the ASCONF is being processed
against, mirroring the existing source-address guard, so the wildcard
branch can never reuse a freed transport.

Fixes: 42e30bf ("[SCTP]: Handle the wildcard ADD-IP Address parameter")
	Cc: stable@kernel.org
	Signed-off-by: Jun Yang <junvyyang@tencent.com>
	Acked-by: Xin Long <lucien.xin@gmail.com>
Link: https://patch.msgid.link/tencent_73762ED1DF08CC9D5F5F61954B01350CFE0A@qq.com
	Signed-off-by: Jakub Kicinski <kuba@kernel.org>
(cherry picked from commit 9b2854f)
	Signed-off-by: Jonathan Maple <jmaple@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 Aug 7, 2026
@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

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

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

JIRA PR Check Results

1 commit(s) with issues found:

Commit 6d442f3e8e56

Summary: sctp: don't free the ASCONF's own transport in DEL-IP processing

⚠️ Warnings:

  • VULN-196073: No time logged - please log time manually

Summary: Checked 1 commit(s) total.

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

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

@PlaidCat
PlaidCat requested a review from a team August 7, 2026 12:59

@bmastbergen bmastbergen 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.

🥌

@PlaidCat
PlaidCat merged commit ab0401c into ciqcbr7_9 Aug 7, 2026
4 checks passed
@PlaidCat
PlaidCat deleted the {jmaple}_ciqcbr7_9 branch August 7, 2026 13:08
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