# ovl: fix UAF in ovl_dentry_update_reval by moving dput() in ovl_link_up

CVE record · `CVE-2025-21887`

- **Identifiers:** `CVE-2025-21887`
- **State:** Confirmed
- **Severity:** CVSS 7.8 High
- **Critical:** No
- **CNA:** Linux
- **Weakness (CWE):** [CWE-416](https://cwe.mitre.org/data/definitions/416.html)
- **Tags:** [Memory corruption](https://agentprime.io/advisories/tag/memory-corruption.md)
- **Technologies:** [Linux kernel](https://agentprime.io/advisories/technology/linux-kernel.md)
- **Published:** 27 Mar 2025
- **Updated:** 10 Nov 2026
- **Reviewed by a person:** No

Published by the CVE Program (CNA: Linux) at 27 Mar 2025, 14:57 UTC. agentprime has not analysed this yet, so whether it affects any app is not known. This CVE names a vendor and product rather than a package, so the lockfile check doesn’t match it.

## Affected products, as the CNA wrote them

- Vendor: Linux. Product: Linux.
  - affected: `714ba10a6dd19752a349e59aa875f3288ccb59b9 to before f77618291836168eca99e89cd175256f928f5e64` (git)
  - affected: `62f29ca45f832e281fc14966ac25f6ff3bd121ca to before 4b49d939b5a79117f939b77cc67efae2694d9799` (git)
  - affected: `e4f2a1feebb3f209a0fca82aa53507a5b8be4d53 to before a7c41830ffcd17b2177a95a9b99b270302090c35` (git)
  - affected: `b07d5cc93e1b28df47a72c519d09d0a836043613 to before 64455c8051c3aedc71abb7ec8d47c80301f99f00` (git)
  - affected: `b07d5cc93e1b28df47a72c519d09d0a836043613 to before 3594aad97e7be2557ca9fa9c931b206b604028c8` (git)
  - affected: `b07d5cc93e1b28df47a72c519d09d0a836043613 to before 60b4b5c1277fc491da9e1e7abab307bfa39c2db7` (git)
  - affected: `b07d5cc93e1b28df47a72c519d09d0a836043613 to before c84e125fff2615b4d9c259e762596134eddd2f27` (git)
  - affected: `33ab4dd6202f359558a0a2678b94d1b9994c17e5` (git)
  - affected: `1ecdc55e5cd9f70f8d7513802971d4cffb9f77af` (git)
  - affected: `5.10.188 to before 5.10.247` (semver)
  - affected: `5.15.121 to before 5.15.179` (semver)
  - affected: `6.1.39 to before 6.1.130` (semver)
  - and 2 more
  - Other versions: unaffected
- Vendor: Linux. Product: Linux.
  - affected: `6.5`
  - unaffected: `before 6.5` (semver)
  - unaffected: `5.10.247 to 5.10.*, inclusive` (semver)
  - unaffected: `5.15.179 to 5.15.*, inclusive` (semver)
  - unaffected: `6.1.130 to 6.1.*, inclusive` (semver)
  - unaffected: `6.6.81 to 6.6.*, inclusive` (semver)
  - unaffected: `6.12.18 to 6.12.*, inclusive` (semver)
  - unaffected: `6.13.6 to 6.13.*, inclusive` (semver)
  - unaffected: `6.14 to *, inclusive` (original_commit_for_fix)
  - Other versions: affected

## Machine-written summary

Summary written by Claude Haiku from the source advisory. Not reviewed by a person.

> Linux kernel versions from 6.5 up to the fixed releases contain a use-after-free in overlayfs (ovl_dentry_update_reval) during copy-up in rename operations. The source gives few details on attacker requirements or impact. Upgrade to 5.10.247, 5.15.179, 6.1.130, 6.6.81, or a newer release.

Written 19 Nov 2026.

## Not analysed yet

We haven’t published our own analysis of this CVE. If a person reviews it, this page will say what’s affected and what has to be true for it to matter.

## Severity and exploitation

- 7.8 High, CVSS 3.1: `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`, from CNA (Linux) (used for this record)
- 7.8 High, CVSS 3.1: `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`, from ADP (CISA-ADP)

- **CISA KEV:** Not listed.
- **EPSS:** 0.0022, the 13th percentile, on 20 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.

## Timeline

- 27 Mar 2025, 14:57 UTC: [Confirmed by the CVE List](https://www.cve.org/CVERecord?id=CVE-2025-21887)
- 27 Mar 2025, 15:15 UTC: [Confirmed by NVD](https://nvd.nist.gov/vuln/detail/CVE-2025-21887)

## Sources

- [CVE List: CVE-2025-21887](https://www.cve.org/CVERecord?id=CVE-2025-21887)
- [NVD: CVE-2025-21887](https://nvd.nist.gov/vuln/detail/CVE-2025-21887)

### References from the CNA

- <https://git.kernel.org/stable/c/f77618291836168eca99e89cd175256f928f5e64>
- <https://git.kernel.org/stable/c/4b49d939b5a79117f939b77cc67efae2694d9799>
- <https://git.kernel.org/stable/c/a7c41830ffcd17b2177a95a9b99b270302090c35>
- <https://git.kernel.org/stable/c/64455c8051c3aedc71abb7ec8d47c80301f99f00>
- <https://git.kernel.org/stable/c/3594aad97e7be2557ca9fa9c931b206b604028c8>
- <https://git.kernel.org/stable/c/60b4b5c1277fc491da9e1e7abab307bfa39c2db7>
- <https://git.kernel.org/stable/c/c84e125fff2615b4d9c259e762596134eddd2f27>

Facts on this page come from the CVE List as the CNA published them, with CVSS from the sources named above, CISA KEV and FIRST EPSS. Vendors, products and versions are shown as the CNA wrote them. We don’t reproduce the CVE’s description.

## Check whether this affects you

This CVE names a vendor and product rather than a package, so the lockfile check doesn’t match it. Compare the affected versions above with what you run.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), `get_advisory` returns this record and `search_advisories` finds related ones. Setup: <https://agentprime.io/mcp.md>
- As JSON: <https://api.agentprime.io/v1/advisories/CVE-2025-21887>
- Everything that needs attention now: <https://agentprime.io/advisories/critical.md>

---

The web page: <https://agentprime.io/advisories/CVE-2025-21887/>. Everything for agents: <https://agentprime.io/llms.txt>.
