CVE-2025-39873

Source
https://nvd.nist.gov/vuln/detail/CVE-2025-39873
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-39873.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2025-39873
Downstream
Related
Published
2025-09-23T06:00:46.157Z
Modified
2025-11-28T02:33:50.644396Z
Summary
can: xilinx_can: xcan_write_frame(): fix use-after-free of transmitted SKB
Details

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

can: xilinxcan: xcanwrite_frame(): fix use-after-free of transmitted SKB

canputecho_skb() takes ownership of the SKB and it may be freed during or after the call.

However, xilinxcan xcanwrite_frame() keeps using SKB after the call.

Fix that by only calling canputecho_skb() after the code is done touching the SKB.

The txlock is held for the entire xcanwriteframe() execution and also on the cangetechoskb() side so the order of operations does not matter.

An earlier fix commit 3d3c817c3a40 ("can: xilinxcan: Fix usage of skb memory") did not move the canputechoskb() call far enough.

[mkl: add "commit" in front of sha1 in patch description] [mkl: fix indention]

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/39xxx/CVE-2025-39873.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
1598efe57b3e768056e4ca56cb9cf33111e68d1c
Fixed
e202ffd9e54538ef67ec301ebd6d9da4823466c9
Fixed
1139321161a3ba5e45e61e0738b37f42f20bc57a
Fixed
94b050726288a56a6b8ff55aa641f2fedbd3b44c
Fixed
725b33deebd6e4c96fe7893f384510a54258f28f
Fixed
668cc1e3bb21101d074e430de1b7ba8fd10189e7
Fixed
ef79f00be72bd81d2e1e6f060d83cf7e425deee4

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
4.19.0
Fixed
5.15.194
Type
ECOSYSTEM
Events
Introduced
5.16.0
Fixed
6.1.153
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.6.107
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.12.48
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.16.8