# CVE-2026-139646: crypto: ccp - fix SFS ioctl race against device teardown

- Severity: not scored yet
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.20%, higher than 10% of CVEs (2026-12-01)
- Published: 2026-11-30T13:36:40.715Z
- Modified: 2026-11-30T14:19:48.207Z
- Assigned by: Linux

## Description

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

crypto: ccp - fix SFS ioctl race against device teardown

sfs_ioctl() reads psp_master->sfs_data and caches it in sfs_dev before
taking sfs_ioctl_mutex, while sfs_dev_destroy() frees sfs_dev->page
and sfs_dev->command_buf with no locking at all and only clears
psp->sfs_data afterwards. A call to sfs_ioctl() that reads sfs_data
just before sfs_dev_destroy() runs will still acquire the mutex and
go on to use the now-freed command buffer in send_sfs_cmd().

Have both functions take sfs_ioctl_mutex before touching
psp->sfs_data, so a call that is already using sfs_dev completes
before teardown can free it, and a call arriving after teardown sees
sfs_data cleared and returns -ENODEV instead of racing it.

(As written by CVE List.)

## Affected

- Linux Linux: from 648dbccc03a000cd64c2a9d86012d98053545e64 before 54a7e3828df45fdb85ea5a1e79a94d4e95b78823; from 648dbccc03a000cd64c2a9d86012d98053545e64 before 6beb23aa2ec4c64f477d1c8e419c7e7da7046f26; from 648dbccc03a000cd64c2a9d86012d98053545e64 before de4929b47683ed22d8c05f68d2d0f0cfd95b90a1; 6.18 (not affected: before 6.18; from 6.18.65 up to 6.18.*; from 7.3.6 up to 7.3.*; from 7.4-rc1 up to *)

## References

- <https://git.kernel.org/stable/c/54a7e3828df45fdb85ea5a1e79a94d4e95b78823>
- <https://git.kernel.org/stable/c/6beb23aa2ec4c64f477d1c8e419c7e7da7046f26>
- <https://git.kernel.org/stable/c/de4929b47683ed22d8c05f68d2d0f0cfd95b90a1>

## Sources

- CVE List: [CVE-2026-139646](https://www.cve.org/CVERecord?id=CVE-2026-139646), CVE Terms of Use, modified 2026-11-30
- NVD: [CVE-2026-139646](https://nvd.nist.gov/vuln/detail/CVE-2026-139646), Public domain, modified 2026-11-30

---

Page: https://cve.day/CVE-2026-139646 · Whole record: https://cve.day/CVE-2026-139646.json · Rebuilt by cve.day 2026-11-30T14:33:14.112Z
