{"id":"CVE-2022-49127","state":"PUBLISHED","title":"ref_tracker: implement use-after-free detection","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nref_tracker: implement use-after-free detection\n\nWhenever ref_tracker_dir_init() is called, mark the struct ref_tracker_dir\nas dead.\n\nTest the dead status from ref_tracker_alloc() and ref_tracker_free()\n\nThis should detect buggy dev_put()/dev_hold() happening too late\nin netdevice dismantle process.","publishedAt":"2025-02-26T01:55:04.643Z","updatedAt":"2026-08-05T08:53:59.429Z","severity":{"score":7,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4e66934eaadc83b27ada8d42b60894018f3bfabf","status":"affected","lessThan":"3743c9de303fa36c2e2ca2522ab280c52bcafbd2","versionType":"git"},{"version":"4e66934eaadc83b27ada8d42b60894018f3bfabf","status":"affected","lessThan":"e3ececfe668facd87d920b608349a32607060e66","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["include/linux/ref_tracker.h","lib/ref_tracker.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.17","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.17","versionType":"semver"},{"version":"5.17.3","status":"unaffected","lessThanOrEqual":"5.17.*","versionType":"semver"},{"version":"5.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["include/linux/ref_tracker.h","lib/ref_tracker.c"]}],"references":["https://git.kernel.org/stable/c/3743c9de303fa36c2e2ca2522ab280c52bcafbd2","https://git.kernel.org/stable/c/e3ececfe668facd87d920b608349a32607060e66"],"weaknesses":["CWE-416"],"ingestedAt":"2026-10-29T20:05:26.763Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2022/49xxx/CVE-2022-49127.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2022-49127","state":"PUBLISHED","datePublished":"2025-02-26T01:55:04.643Z","dateUpdated":"2026-08-05T08:53:59.429Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-02-26T01:49:39.266Z"},"containers":{"cna":{"title":"ref_tracker: implement use-after-free detection","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nref_tracker: implement use-after-free detection\n\nWhenever ref_tracker_dir_init() is called, mark the struct ref_tracker_dir\nas dead.\n\nTest the dead status from ref_tracker_alloc() and ref_tracker_free()\n\nThis should detect buggy dev_put()/dev_hold() happening too late\nin netdevice dismantle process."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4e66934eaadc83b27ada8d42b60894018f3bfabf","status":"affected","lessThan":"3743c9de303fa36c2e2ca2522ab280c52bcafbd2","versionType":"git"},{"version":"4e66934eaadc83b27ada8d42b60894018f3bfabf","status":"affected","lessThan":"e3ececfe668facd87d920b608349a32607060e66","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["include/linux/ref_tracker.h","lib/ref_tracker.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.17","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.17","versionType":"semver"},{"version":"5.17.3","status":"unaffected","lessThanOrEqual":"5.17.*","versionType":"semver"},{"version":"5.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["include/linux/ref_tracker.h","lib/ref_tracker.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/3743c9de303fa36c2e2ca2522ab280c52bcafbd2"},{"url":"https://git.kernel.org/stable/c/e3ececfe668facd87d920b608349a32607060e66"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The ref_tracker path is reached through local netdev/netns lifecycle operations (netdev_hold/put during device or namespace teardown via netlink/syscalls), not by parsing attacker-controlled remote packets.\nAC:H - The vulnerable code exists only when CONFIG_NET_DEV_REFCNT_TRACKER or CONFIG_NET_NS_REFCNT_TRACKER is enabled (default n, DEBUG_KERNEL-only); without that rare debug config the tracker ops are compiled out as stubs.\nPR:L - An unprivileged user can obtain CAP_NET_ADMIN via user namespaces (unshare -Urn), create/destroy netdevs and network namespaces, and drive dismantle paths that exercise the tracker.\nUI:N - The attacker can create and tear down their own network devices/namespaces and trigger late hold/put paths without any victim action.\nS:U - Impact stays within the local kernel’s networking reference-tracking state; there is no VM escape, IOMMU bypass, or other cross-authority boundary crossing.\nC:H - Use-after-free of heap-allocated struct ref_tracker objects after dir_exit frees them can be leveraged for arbitrary kernel memory disclosure via heap reuse.\nI:H - The same UAF enables heap spraying and corruption of reused tracker/list metadata, which can yield arbitrary write or control-flow hijacking primitives.\nA:H - UAF of freed trackers and the WARN_ON_ONCE path can oops/panic the kernel (including under panic_on_warn), causing a full availability loss."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T08:53:59.429Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.17","versionEndExcluding":"5.17.3"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.17","versionEndExcluding":"5.18"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"cvssV3_1":{"scope":"UNCHANGED","version":"3.1","baseScore":7.8,"attackVector":"LOCAL","baseSeverity":"HIGH","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","integrityImpact":"HIGH","userInteraction":"NONE","attackComplexity":"LOW","availabilityImpact":"HIGH","privilegesRequired":"LOW","confidentialityImpact":"HIGH"}},{"other":{"type":"ssvc","content":{"id":"CVE-2022-49127","role":"CISA Coordinator","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"total"}],"version":"2.0.3","timestamp":"2025-02-27T18:17:18.309932Z"}}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-416","lang":"en","type":"CWE","description":"CWE-416 Use After Free"}]}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2025-02-27T18:22:34.926Z"}}]}}}