CVE-2025-37845 (GCVE-0-2025-37845)
Vulnerability from cvelistv5
Published
2025-05-09 06:41
Modified
2026-08-05 11:57
Summary
In the Linux kernel, the following vulnerability has been resolved: tracing: fprobe events: Fix possible UAF on modules Commit ac91052f0ae5 ("tracing: tprobe-events: Fix leakage of module refcount") moved try_module_get() from __find_tracepoint_module_cb() to find_tracepoint() caller, but that introduced a possible UAF because the module can be unloaded before try_module_get(). In this case, the module object should be freed too. Thus, try_module_get() does not only fail but may access to the freed object. To avoid that, try_module_get() in __find_tracepoint_module_cb() again.
Impacted products
Vendor Product Version
Linux Linux Version: 71c9cf87776eaa556fc0a0a060df94200e1f521c
Version: 9db2b8cf4ea07b579db588e0353d5680f5d1f071
Version: ac91052f0ae5be9e46211ba92cc31c0e3b0a933a
Version: ac91052f0ae5be9e46211ba92cc31c0e3b0a933a
Version: 6.12.21   
Version: 6.13.9   
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "kernel/trace/trace_fprobe.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "868df4eb784c3ccc7e4340a9ea993cbbedca167e",
              "status": "affected",
              "version": "71c9cf87776eaa556fc0a0a060df94200e1f521c",
              "versionType": "git"
            },
            {
              "lessThan": "a27d2de2472b1cc7d582ab405d1d5832a80481de",
              "status": "affected",
              "version": "9db2b8cf4ea07b579db588e0353d5680f5d1f071",
              "versionType": "git"
            },
            {
              "lessThan": "626f01f4d26e8cf92e69c1df53036153c8e98a20",
              "status": "affected",
              "version": "ac91052f0ae5be9e46211ba92cc31c0e3b0a933a",
              "versionType": "git"
            },
            {
              "lessThan": "dd941507a9486252d6fcf11814387666792020f3",
              "status": "affected",
              "version": "ac91052f0ae5be9e46211ba92cc31c0e3b0a933a",
              "versionType": "git"
            },
            {
              "lessThan": "6.12.24",
              "status": "affected",
              "version": "6.12.21",
              "versionType": "semver"
            },
            {
              "lessThan": "6.13.12",
              "status": "affected",
              "version": "6.13.9",
              "versionType": "semver"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "kernel/trace/trace_fprobe.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.14"
            },
            {
              "lessThan": "6.14",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.24",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.13.*",
              "status": "unaffected",
              "version": "6.13.12",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.14.*",
              "status": "unaffected",
              "version": "6.14.3",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.15",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.24",
                  "versionStartIncluding": "6.12.21",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.13.12",
                  "versionStartIncluding": "6.13.9",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.14.3",
                  "versionStartIncluding": "6.14",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.15",
                  "versionStartIncluding": "6.14",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\ntracing: fprobe events: Fix possible UAF on modules\n\nCommit ac91052f0ae5 (\"tracing: tprobe-events: Fix leakage of module\nrefcount\") moved try_module_get() from __find_tracepoint_module_cb()\nto find_tracepoint() caller, but that introduced a possible UAF\nbecause the module can be unloaded before try_module_get(). In this\ncase, the module object should be freed too. Thus, try_module_get()\ndoes not only fail but may access to the freed object.\n\nTo avoid that, try_module_get() in __find_tracepoint_module_cb()\nagain."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7.8,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:L - The vulnerable path is reached only by writing a tracepoint probe definition to the tracefs `dynamic_events` file (`trace_fprobe_create()` \u2192 `find_tracepoint()`), which requires local access to the machine. There is no network-facing consumer of this code.\nAC:L - The attacker drives both sides of the race \u2014 repeatedly issuing `t:` tprobe creations while causing module load/unload churn \u2014 and the operation can be retried indefinitely at no cost until the window between `mutex_unlock()` in `for_each_module_tracepoint()` and `try_module_get()` is hit. `CONFIG_FPROBE_EVENTS` is `default y`, so no rare configuration is required.\nPR:L - Exploitation needs write access to the tracefs `dynamic_events` interface, which is routinely delegated to non-root tracing/debug accounts and groups (Android shell/system, ChromeOS debugd, perf/tracing groups, container debug sidecars) rather than being an exclusively root-only capability. No credential check exists in the code path itself beyond file permissions.\nUI:N - The attacker performs the tracefs write and the concurrent module operations entirely on their own; no victim action or interaction is needed.\nS:U - The use-after-free corrupts kernel memory within the same security authority as the kernel itself; no VM, IOMMU, or sandbox boundary is crossed.\nC:H - The stale `struct module` and the stale tracepoint structure are read after being freed, and if the freed region is reclaimed by attacker-sprayed allocations the resulting values (`probestub` address, funcname resolved via `kallsyms_lookup()`) feed back into observable state, giving a path to kernel memory disclosure.\nI:H - `try_module_get()` performs an atomic increment into freed memory, and a \"successful\" get lets the code register a tracepoint probe and an ftrace hook using function pointers read out of freed, reclaimable memory \u2014 a write plus control-flow-hijack primitive.\nA:H - Touching the freed module allocation (vmalloc-backed, so frequently unmapped on free) produces an immediate oops or panic, and the subsequent probe registration on freed tracepoint data reliably destabilizes the kernel."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T11:57:48.902Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/868df4eb784c3ccc7e4340a9ea993cbbedca167e"
        },
        {
          "url": "https://git.kernel.org/stable/c/a27d2de2472b1cc7d582ab405d1d5832a80481de"
        },
        {
          "url": "https://git.kernel.org/stable/c/626f01f4d26e8cf92e69c1df53036153c8e98a20"
        },
        {
          "url": "https://git.kernel.org/stable/c/dd941507a9486252d6fcf11814387666792020f3"
        }
      ],
      "title": "tracing: fprobe events: Fix possible UAF on modules",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2025-37845",
    "datePublished": "2025-05-09T06:41:54.022Z",
    "dateReserved": "2025-04-16T04:51:23.953Z",
    "dateUpdated": "2026-08-05T11:57:48.902Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2"
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…