CVE-2024-36904 — tcp: Use refcount_inc_not_zero() in tcp_twsk_unique().
In the Linux kernel, the following vulnerability has been resolved: tcp: Use refcount_inc_not_zero() in tcp_twsk_unique(). Anderson Nascimento reported a use-after-free splat in tcp_twsk_unique() with nice analysis. Since commit ec94c2696f0b ("tcp/dccp: avoid one atomic operation for timewait hashdance"), inet_twsk_hashdance() sets TIME-WAIT socket's sk_refcnt after putting it into ehash and releasing the bucket lock. Thus, there is a small race window where other threads could try to reuse the port during connect() and call sock_hold() in tcp_twsk_unique() for the TIME-WAIT socket with zero refcnt. If that happens, the refcnt taken by tcp_twsk_unique() is overwritten and sock_put() will cause underflow, triggering a real use-after-free somewhere else. To avoid the use-after-free, we need to use refcount_inc_not_zero() in tcp_twsk_unique() and give up on reusing the port if it returns false. [0]: refcount_t: addition on 0; use-after-free. WARNING: CPU: 0 PID: 1039313 at lib/refcount.c:25 refcount_warn_saturate+0xe5/0x110 CPU: 0 PID: 1039313 Comm: trigger Not tainted 6.8.6-200.fc39.x86_64 #1 Hardware name: VMware, Inc. VMware20,1/440BX Desktop Reference Platform, BIOS VMW201.00V.21805430.B64.2305221830 05/22/2023 RIP: 0010:refcount_warn_saturate+0xe5/0x110 Code: 42 8e ff 0f 0b c3 cc cc cc cc 80 3d aa 13 ea 01 00 0f 85 5e ff ff ff 48 c7 c7 f8 8e b7 82 c6 05 96 13 ea 01 01 e8 7b 42 8e ff <0f> 0b c3 cc cc cc cc 48 c7 c7 50 8f b7 82 c6 05 7a 13 ea 01 01 e8 RSP: 0018:ffffc90006b43b60 EFLAGS: 00010282 RAX: 0000000000000000 RBX: ffff888009bb3ef0 RCX: 0000000000000027 RDX: ffff88807be218c8 RSI: 0000000000000001 RDI: ffff88807be218c0 RBP: 0000000000069d70 R08: 0000000000000000 R09: ffffc90006b439f0 R10: ffffc90006b439e8 R11: 0000000000000003 R12: ffff8880029ede84 R13: 0000000000004e20 R14: ffffffff84356dc0 R15: ffff888009bb3ef0 FS: 00007f62c10926c0(0000) GS:ffff88807be00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000020ccb000 CR3: 000000004628c005 CR4: 0000000000f70ef0 PKRU: 55555554 Call Trace: <TASK> ? refcount_warn_saturate+0xe5/0x110 ? __warn+0x81/0x130 ? refcount_warn_saturate+0xe5/0x110 ? report_bug+0x171/0x1a0 ? refcount_warn_saturate+0xe5/0x110 ? handle_bug+0x3c/0x80 ? exc_invalid_op+0x17/0x70 ? asm_exc_invalid_op+0x1a/0x20 ? refcount_warn_saturate+0xe5/0x110 tcp_twsk_unique+0x186/0x190 __inet_check_established+0x176/0x2d0 __inet_hash_connect+0x74/0x7d0 ? __pfx___inet_check_established+0x10/0x10 tcp_v4_connect+0x278/0x530 __inet_stream_connect+0x10f/0x3d0 inet_stream_connect+0x3a/0x60 __sys_connect+0xa8/0xd0 __x64_sys_connect+0x18/0x20 do_syscall_64+0x83/0x170 entry_SYSCALL_64_after_hwframe+0x78/0x80 RIP: 0033:0x7f62c11a885d Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d a3 45 0c 00 f7 d8 64 89 01 48 RSP: 002b:00007f62c1091e58 EFLAGS: 00000296 ORIG_RAX: 000000000000002a RAX: ffffffffffffffda RBX: 0000000020ccb004 RCX: 00007f62c11a885d RDX: 0000000000000010 RSI: 0000000020ccb000 RDI: 0000000000000003 RBP: 00007f62c1091e90 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000296 R12: 00007f62c10926c0 R13: ffffffffffffff88 R14: 0000000000000000 R15: 00007ffe237885b0 </TASK>
Who exploits it and how urgent it is
A 0–100 score combining confirmed exploitation, ransomware and APT use, public exploits, EPSS and severity.
How the score was calculated
- EPSS 0.6% (30-day exploitation probability)+7
- Technical severity (high)+6
The score orders the patch queue; it does not replace your asset context (internet exposure, criticality, compensating controls).
Triage
Is it exploited, how likely is exploitation, what does it touch, and how severe do the sources call it.
CISA SSVC assessment CISA
Three decision points CISA publishes for the CVEs it assesses (SSVC 2.0.3). A stakeholder decision, not a severity score.
Remediation
Fixes and mitigations documented by the sources — linked to the original advisory.
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
- Documented patch — git.kernel.org (NIST National Vulnerability Database)
First 24 hours
Ordered from the record’s own fields — exposure first, because you cannot patch what you have not found. A rule-generated starting point.
- Identify exposed assets running the affected vendor/product/version combinations (Debian Debian Linux, Linux Linux, Linux Linux Kernel).
- Apply the fixed version or the patch documented under Remediation.
- Search available logs for exploit probes matching the vulnerability class (memory corruption), errors and authentication anomalies.
Affected scope
Vendor, product and versions as the sources word them.
| Vendor | Product | Versions | Status | Source |
|---|---|---|---|---|
| Debian | Debian Linux | version 10.0 | Vulnerable | NIST National Vulnerability Database |
| Linux | Linux |
version 4.16≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < f2db7230f73a80dbb179deab78f88a7947f0ab7e≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 517e32ea0a8c72202d0d8aa8df50a7cd3d6fdefc≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 6e48faad92be13166184d21506e4e54c79c13adc≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 13ed7cdf079686ccd3618335205700c03f6fb446≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 27b0284d8be182a81feb65581ab6a724dfd596e8≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 1d9cf07810c30ef7948879567d10fd1f01121d34≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 1796ca9c6f5bd50554214053af5f47d112818ee3 and 1 more≥ ec94c2696f0bcd5ae92a553244e4ac30d2171a2d and < 84546cc1aeeb4df3e444b18a4293c9823f974be9 |
Vulnerable | CVE Program (cve.org) e CISA ADP |
| Linux | Linux Kernel |
version 6.9-rc5version 6.9-rc7version 6.9-rc6version 6.9-rc4version 6.9-rc3version 6.9-rc2version 6.9-rc1≥ 6.7 and < 6.8.10 and 6 more≥ 6.2 and < 6.6.31≥ 5.16 and < 6.1.91≥ 5.11 and < 5.15.159≥ 5.5 and < 5.10.217≥ 4.20 and < 5.4.276≥ 4.16 and < 4.19.314 |
Vulnerable | NIST National Vulnerability Database |
Attack characteristics
The CVSS vector, decoded. It describes the attack, not your exposure to it.
Every base score collected
Sources score independently and may disagree; each row says who scored it and under which version.
| Score | Version | Severity | Expl. | Impact | Scored by |
|---|---|---|---|---|---|
| 7.8 | CVSS 3.1 | High | 1.8 | 5.9 | 416baaa9-dc9f-4396-8d5f-8c081fb06d67 via NIST National Vulnerability Database |
| 7.8 | CVSS 3.1 | High | 1.8 | 5.9 | nvd@nist.gov via NIST National Vulnerability Database |
| 7.8 | CVSS 3.1 | High | — | — | Linux via CVE Program (cve.org) e CISA ADP |
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H (score shown at the top: nvd@nist.gov) Weakness MITRE
Weakness class according to MITRE’s CWE catalog.
Detection
Read off the CVSS vector and the weakness class. Starting points, not tested rules.
- Local/physical vector: focus on endpoint telemetry (EDR) from affected hosts.
- Correlate service crashes/restarts with inbound traffic; repeated crashes may indicate attempts.
Timeline
What happened to this CVE, newest first.
- 2026
- Affected products added · linux/linux
- SSVC assessment updated
- Record published
- Fix documented
- Affected products added · linux/linux kernel, debian/debian linux
- CVSS changed · 7.8
- Source status changed · → Modified
- Record created in this database
- 2024
- CVE published
Source activity
Repeated readings are counted rather than listed.
- 1× References added · Oct 14, 2026 – Oct 14, 2026
- 1× Official description updated · Oct 14, 2026 – Oct 14, 2026
References
14 on the record
- git.kernel.org/stable/c/27b0284d8be182a81feb65581ab6a724dfd596e8
- git.kernel.org/stable/c/6e48faad92be13166184d21506e4e54c79c13adc
- git.kernel.org/stable/c/1d9cf07810c30ef7948879567d10fd1f01121d34
- git.kernel.org/stable/c/517e32ea0a8c72202d0d8aa8df50a7cd3d6fdefc
- git.kernel.org/stable/c/84546cc1aeeb4df3e444b18a4293c9823f974be9
- git.kernel.org/stable/c/1796ca9c6f5bd50554214053af5f47d112818ee3
- git.kernel.org/stable/c/13ed7cdf079686ccd3618335205700c03f6fb446
- git.kernel.org/stable/c/f2db7230f73a80dbb179deab78f88a7947f0ab7e
- security.netapp.com/advisory/ntap-20240905-0004/
- cert-portal.siemens.com/productcert/html/ssa-398330.html
- lists.debian.org/debian-lts-announce/2024/06/msg00019.html
- cert-portal.siemens.com/productcert/html/ssa-613116.html
- lists.debian.org/debian-lts-announce/2024/06/msg00020.html
- cert-portal.siemens.com/productcert/html/ssa-265688.html
Elsewhere on this site
Related CVEs (same products)
- Critical CVE-2026-99999 ipv4: validate checksum_start before completing checksum 10h
- Unknown CVE-2026-98432 ipv4: free inet_opt and ireq_opt after an RCU grace period 10h
- Unknown CVE-2026-98424 wifi: cfg80211: undo netns switch if renaming the wiphy fails 1d
- Unknown CVE-2026-98425 wifi: mac80211: don't warn when an IBSS has no channel to scan 1d
- Unknown CVE-2026-98426 wifi: mwifiex: fix IRQ leak using wrong index in MSI-X error path 1d
- Unknown CVE-2026-98427 net/sched: codel: bound the dropping loop per dequeue call 1d
Not in any source we poll
Listed rather than left blank: an empty field and an unmeasured one look identical on screen, and only one is a reason to look elsewhere.
- No confirmed IOCs, IP addresses, domains, file hashes, or malware artifacts supplied.
- No organization-specific asset inventory, compensating-control status, or patch deployment evidence supplied.
- No exploit packet captures, log samples, or incident case IDs supplied.
Answered from this record
Text assembled only from the fields above — no additional claims.
What should defenders know first?
CVE-2024-36904 is "tcp: Use refcount_inc_not_zero() in tcp_twsk_unique().", rated High. It affects Debian Linux (Debian); versions are in the scope table. It is not in CISA KEV, which does not rule out exploitation. CVSS 7.8 describes technical severity. EPSS 0.61% estimates the probability of exploitation in 30 days; neither replaces your asset context. First verify whether exposed or business-critical assets run the affected versions, apply vendor fixes or mitigations, and preserve logs for review.
Comments
Moderated technical discussion. Read the community guidelines.
No comments yet.
Sign in or create an account to comment and suggest corrections.