# CVE-2025-38581: crypto: ccp - Fix crash when rebind ccp device for ccp.ko

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.29% (percentile 14, 2026-11-26)
- **CWE:** CWE-476
- **Published:** 2025-08-19T17:03:03.718Z
- **Modified:** 2026-11-05T22:17:19.460Z

## Who should check

- Anyone running Linux \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< a25ab6dfa0ce323ec308966988be6b675eb9d3e5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< ce63a83925964ab7564bd216bd92b80bc365492e; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 20c0ed8dd65834e6bab464f54cd6ff68659bacb9; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 2d4060f05e74dbee884ba723f6afd9282befc3c5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< db111468531777cac8b4beb6515a88a54b0c4a74; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 9dea08eac4f6d6fbbae59992978252e2edab995d; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 6eadf50c1d894cb34f3237064063207460946040; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 64ec9a7e7a6398b172ab6feba60e952163a1c3d5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 181698af38d3f93381229ad89c09b5bd0496661a
- Anyone running Linux 4.13

## Description

In the Linux kernel, the following vulnerability has been resolved:

crypto: ccp - Fix crash when rebind ccp device for ccp.ko

When CONFIG\_CRYPTO\_DEV\_CCP\_DEBUGFS is enabled, rebinding
the ccp device causes the following crash:

$ echo '0000:0a:00.2' \> /sys/bus/pci/drivers/ccp/unbind
$ echo '0000:0a:00.2' \> /sys/bus/pci/drivers/ccp/bind

\[  204.976930\] BUG: kernel NULL pointer dereference, address: 0000000000000098
\[  204.978026\] \#PF: supervisor write access in kernel mode
\[  204.979126\] \#PF: error\_code(0x0002) - not-present page
\[  204.980226\] PGD 0 P4D 0
\[  204.981317\] Oops: Oops: 0002 \[\#1\] SMP NOPTI
...
\[  204.997852\] Call Trace:
\[  204.999074\]  \<TASK\>
\[  205.000297\]  start\_creating+0x9f/0x1c0
\[  205.001533\]  debugfs\_create\_dir+0x1f/0x170
\[  205.002769\]  ? srso\_return\_thunk+0x5/0x5f
\[  205.004000\]  ccp5\_debugfs\_setup+0x87/0x170 \[ccp\]
\[  205.005241\]  ccp5\_init+0x8b2/0x960 \[ccp\]
\[  205.006469\]  ccp\_dev\_init+0xd4/0x150 \[ccp\]
\[  205.007709\]  sp\_init+0x5f/0x80 \[ccp\]
\[  205.008942\]  sp\_pci\_probe+0x283/0x2e0 \[ccp\]
\[  205.010165\]  ? srso\_return\_thunk+0x5/0x5f
\[  205.011376\]  local\_pci\_probe+0x4f/0xb0
\[  205.012584\]  pci\_device\_probe+0xdb/0x230
\[  205.013810\]  really\_probe+0xed/0x380
\[  205.015024\]  \_\_driver\_probe\_device+0x7e/0x160
\[  205.016240\]  device\_driver\_attach+0x2f/0x60
\[  205.017457\]  bind\_store+0x7c/0xb0
\[  205.018663\]  drv\_attr\_store+0x28/0x40
\[  205.019868\]  sysfs\_kf\_write+0x5f/0x70
\[  205.021065\]  kernfs\_fop\_write\_iter+0x145/0x1d0
\[  205.022267\]  vfs\_write+0x308/0x440
\[  205.023453\]  ksys\_write+0x6d/0xe0
\[  205.024616\]  \_\_x64\_sys\_write+0x1e/0x30
\[  205.025778\]  x64\_sys\_call+0x16ba/0x2150
\[  205.026942\]  do\_syscall\_64+0x56/0x1e0
\[  205.028108\]  entry\_SYSCALL\_64\_after\_hwframe+0x76/0x7e
\[  205.029276\] RIP: 0033:0x7fbc36f10104
\[  205.030420\] Code: 89 02 48 c7 c0 ff ff ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 8d 05 e1 08 2e 00 8b 00 85 c0 75 13 b8 01 00 00 00 0f 05 \<48\> 3d 00 f0 ff ff 77 54 f3 c3 66 90 41 54 55 49 89 d4 53 48 89 f5

This patch sets ccp\_debugfs\_dir to NULL after destroying it in
ccp5\_debugfs\_destroy, allowing the directory dentry to be
recreated when rebinding the ccp device.

Tested on AMD Ryzen 7 1700X.

## Affected and fixed versions

- Linux: \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< a25ab6dfa0ce323ec308966988be6b675eb9d3e5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< ce63a83925964ab7564bd216bd92b80bc365492e; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 20c0ed8dd65834e6bab464f54cd6ff68659bacb9; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 2d4060f05e74dbee884ba723f6afd9282befc3c5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< db111468531777cac8b4beb6515a88a54b0c4a74; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 9dea08eac4f6d6fbbae59992978252e2edab995d; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 6eadf50c1d894cb34f3237064063207460946040; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 64ec9a7e7a6398b172ab6feba60e952163a1c3d5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 181698af38d3f93381229ad89c09b5bd0496661a (cvelist)
- Linux: 4.13 (cvelist)

## Mitigation

- Upgrade Linux to 181698af38d3f93381229ad89c09b5bd0496661a or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-38581. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-38581.md
Affected: Linux >= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, < a25ab6dfa0ce323ec308966988be6b675eb9d3e5; >= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, < ce63a83925964ab7564bd216bd92b80bc365492e; >= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, < 20c0ed8dd65834e6bab464f54cd6ff68659bacb9; >= 3cdbe346ed3f380eae1cb3e…
Fixed in: Linux 20c0ed8dd65834e6bab464f54cd6ff68659bacb9, Linux 2d4060f05e74dbee884ba723f6afd9282befc3c5, Linux 9dea08eac4f6d6fbbae59992978252e2edab995d, Linux 6eadf50c1d894cb34f3237064063207460946040, Linux 64ec9a7e7a6398b172ab6feba60e952163a1c3d5, Linux 181698af38d3f93381229ad89c09b5bd0496661a

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-38581 being exploited?

There is no confirmed exploitation: CVE-2025-38581 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.29% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-38581?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-38581?

Linux \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< a25ab6dfa0ce323ec308966988be6b675eb9d3e5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< ce63a83925964ab7564bd216bd92b80bc365492e; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 20c0ed8dd65834e6bab464f54cd6ff68659bacb9; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 2d4060f05e74dbee884ba723f6afd9282befc3c5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< db111468531777cac8b4beb6515a88a54b0c4a74; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 9dea08eac4f6d6fbbae59992978252e2edab995d; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 6eadf50c1d894cb34f3237064063207460946040; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 64ec9a7e7a6398b172ab6feba60e952163a1c3d5; \>= 3cdbe346ed3f380eae1cb3e9febfe703e7d8a7b0, \< 181698af38d3f93381229ad89c09b5bd0496661a; Linux 4.13.

### Is there a fix for CVE-2025-38581?

Yes. Fixed in Linux 20c0ed8dd65834e6bab464f54cd6ff68659bacb9, Linux 2d4060f05e74dbee884ba723f6afd9282befc3c5, Linux 9dea08eac4f6d6fbbae59992978252e2edab995d, Linux 6eadf50c1d894cb34f3237064063207460946040, Linux 64ec9a7e7a6398b172ab6feba60e952163a1c3d5, Linux 181698af38d3f93381229ad89c09b5bd0496661a. Upgrade Linux to 181698af38d3f93381229ad89c09b5bd0496661a or later.

### How do I check if I'm affected by CVE-2025-38581?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/a25ab6dfa0ce323ec308966988be6b675eb9d3e5>
- patch: <https://git.kernel.org/stable/c/ce63a83925964ab7564bd216bd92b80bc365492e>
- patch: <https://git.kernel.org/stable/c/20c0ed8dd65834e6bab464f54cd6ff68659bacb9>
- patch: <https://git.kernel.org/stable/c/2d4060f05e74dbee884ba723f6afd9282befc3c5>
- patch: <https://git.kernel.org/stable/c/db111468531777cac8b4beb6515a88a54b0c4a74>
- patch: <https://git.kernel.org/stable/c/9dea08eac4f6d6fbbae59992978252e2edab995d>
- patch: <https://git.kernel.org/stable/c/6eadf50c1d894cb34f3237064063207460946040>
- patch: <https://git.kernel.org/stable/c/64ec9a7e7a6398b172ab6feba60e952163a1c3d5>
- patch: <https://git.kernel.org/stable/c/181698af38d3f93381229ad89c09b5bd0496661a>
- other: <https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html>
- other: <https://lists.debian.org/debian-lts-announce/2025/10/msg00007.html>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-38581>

HTML: <https://flawdb.com/CVE-2025-38581> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-38581>
