{"id":"CVE-2025-22005","state":"PUBLISHED","title":"ipv6: Fix memleak of nhc_pcpu_rth_output in fib_check_nh_v6_gw().","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nipv6: Fix memleak of nhc_pcpu_rth_output in fib_check_nh_v6_gw().\n\nfib_check_nh_v6_gw() expects that fib6_nh_init() cleans up everything\nwhen it fails.\n\nCommit 7dd73168e273 (\"ipv6: Always allocate pcpu memory in a fib6_nh\")\nmoved fib_nh_common_init() before alloc_percpu_gfp() within fib6_nh_init()\nbut forgot to add cleanup for fib6_nh->nh_common.nhc_pcpu_rth_output in\ncase it fails to allocate fib6_nh->rt6i_pcpu, resulting in memleak.\n\nLet's call fib_nh_common_release() and clear nhc_pcpu_rth_output in the\nerror path.\n\nNote that we can remove the fib6_nh_release() call in nh_create_ipv6()\nlater in net-next.git.","publishedAt":"2025-04-03T07:19:06.716Z","updatedAt":"2026-10-15T01:05:19.139Z","severity":{"score":5.5,"label":"Medium","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","source":"CISA-ADP"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"16267a5036173d0173377545b4b6021b081d0933","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"1bd12dfc058e1e68759d313d7727d68dbc1b8964","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"596a883c4ce2d2e9c175f25b98fed3a1f33fea38","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"77c41cdbe6bce476e08d3251c0d501feaf10a9f3","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"119dcafe36795a15ae53351cbbd6177aaf94ffef","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"29d91820184d5cbc70f3246d4911d96eaeb930d6","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"d3d5b4b5ae263c3225db363ba08b937e2e2b0380","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"9740890ee20e01f99ff1dde84c63dcf089fabb98","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/ipv6/route.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.3","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.3","versionType":"semver"},{"version":"5.4.292","status":"unaffected","lessThanOrEqual":"5.4.*","versionType":"semver"},{"version":"5.10.236","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.180","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.132","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.85","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.21","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.13.9","status":"unaffected","lessThanOrEqual":"6.13.*","versionType":"semver"},{"version":"6.14","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/ipv6/route.c"]}],"references":["https://git.kernel.org/stable/c/16267a5036173d0173377545b4b6021b081d0933","https://git.kernel.org/stable/c/1bd12dfc058e1e68759d313d7727d68dbc1b8964","https://git.kernel.org/stable/c/596a883c4ce2d2e9c175f25b98fed3a1f33fea38","https://git.kernel.org/stable/c/77c41cdbe6bce476e08d3251c0d501feaf10a9f3","https://git.kernel.org/stable/c/119dcafe36795a15ae53351cbbd6177aaf94ffef","https://git.kernel.org/stable/c/29d91820184d5cbc70f3246d4911d96eaeb930d6","https://git.kernel.org/stable/c/d3d5b4b5ae263c3225db363ba08b937e2e2b0380","https://git.kernel.org/stable/c/9740890ee20e01f99ff1dde84c63dcf089fabb98","https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html","https://lists.debian.org/debian-lts-announce/2025/05/msg00030.html","https://cert-portal.siemens.com/productcert/html/ssa-019113.html","https://cert-portal.siemens.com/productcert/html/ssa-457936.html"],"weaknesses":["CWE-401"],"ingestedAt":"2026-10-29T20:08:39.238Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/22xxx/CVE-2025-22005.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-22005","state":"PUBLISHED","datePublished":"2025-04-03T07:19:06.716Z","dateUpdated":"2026-10-15T01:05:19.139Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2024-12-29T08:45:45.803Z"},"containers":{"cna":{"title":"ipv6: Fix memleak of nhc_pcpu_rth_output in fib_check_nh_v6_gw().","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nipv6: Fix memleak of nhc_pcpu_rth_output in fib_check_nh_v6_gw().\n\nfib_check_nh_v6_gw() expects that fib6_nh_init() cleans up everything\nwhen it fails.\n\nCommit 7dd73168e273 (\"ipv6: Always allocate pcpu memory in a fib6_nh\")\nmoved fib_nh_common_init() before alloc_percpu_gfp() within fib6_nh_init()\nbut forgot to add cleanup for fib6_nh->nh_common.nhc_pcpu_rth_output in\ncase it fails to allocate fib6_nh->rt6i_pcpu, resulting in memleak.\n\nLet's call fib_nh_common_release() and clear nhc_pcpu_rth_output in the\nerror path.\n\nNote that we can remove the fib6_nh_release() call in nh_create_ipv6()\nlater in net-next.git."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"16267a5036173d0173377545b4b6021b081d0933","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"1bd12dfc058e1e68759d313d7727d68dbc1b8964","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"596a883c4ce2d2e9c175f25b98fed3a1f33fea38","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"77c41cdbe6bce476e08d3251c0d501feaf10a9f3","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"119dcafe36795a15ae53351cbbd6177aaf94ffef","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"29d91820184d5cbc70f3246d4911d96eaeb930d6","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"d3d5b4b5ae263c3225db363ba08b937e2e2b0380","versionType":"git"},{"version":"7dd73168e273938b9e9bb42ca51b0c27d807992b","status":"affected","lessThan":"9740890ee20e01f99ff1dde84c63dcf089fabb98","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/ipv6/route.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.3","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.3","versionType":"semver"},{"version":"5.4.292","status":"unaffected","lessThanOrEqual":"5.4.*","versionType":"semver"},{"version":"5.10.236","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.180","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.132","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.85","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.21","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.13.9","status":"unaffected","lessThanOrEqual":"6.13.*","versionType":"semver"},{"version":"6.14","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/ipv6/route.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/16267a5036173d0173377545b4b6021b081d0933"},{"url":"https://git.kernel.org/stable/c/1bd12dfc058e1e68759d313d7727d68dbc1b8964"},{"url":"https://git.kernel.org/stable/c/596a883c4ce2d2e9c175f25b98fed3a1f33fea38"},{"url":"https://git.kernel.org/stable/c/77c41cdbe6bce476e08d3251c0d501feaf10a9f3"},{"url":"https://git.kernel.org/stable/c/119dcafe36795a15ae53351cbbd6177aaf94ffef"},{"url":"https://git.kernel.org/stable/c/29d91820184d5cbc70f3246d4911d96eaeb930d6"},{"url":"https://git.kernel.org/stable/c/d3d5b4b5ae263c3225db363ba08b937e2e2b0380"},{"url":"https://git.kernel.org/stable/c/9740890ee20e01f99ff1dde84c63dcf089fabb98"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T21:10:48.403Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"5.4.292"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"5.10.236"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"5.15.180"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"6.1.132"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"6.6.85"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"6.12.21"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"6.13.9"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.3","versionEndExcluding":"6.14"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"cvssV3_1":{"scope":"UNCHANGED","version":"3.1","baseScore":5.5,"attackVector":"LOCAL","baseSeverity":"MEDIUM","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","integrityImpact":"NONE","userInteraction":"NONE","attackComplexity":"LOW","availabilityImpact":"HIGH","privilegesRequired":"LOW","confidentialityImpact":"NONE"}},{"other":{"type":"ssvc","content":{"timestamp":"2025-10-01T17:09:45.806528Z","id":"CVE-2025-22005","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-401","type":"CWE","lang":"en","description":"CWE-401 Missing Release of Memory after Effective Lifetime"}]}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2025-10-01T17:09:48.269Z"}},{"title":"CVE Program Container","references":[{"url":"https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html"},{"url":"https://lists.debian.org/debian-lts-announce/2025/05/msg00030.html"}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2025-11-03T19:40:47.614Z"}},{"affected":[{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.6","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.7","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.6","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.7","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.6","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.7","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.6","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.7","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIPLUS S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.6","status":"affected","lessThan":"*","versionType":"custom"}]},{"vendor":"Siemens","product":"SIPLUS S7-1500 CPU 1518-4 PN/DP MFP","defaultStatus":"unknown","versions":[{"version":"V3.1.7","status":"affected","lessThan":"*","versionType":"custom"}]}],"references":[{"url":"https://cert-portal.siemens.com/productcert/html/ssa-019113.html"},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-457936.html"}],"providerMetadata":{"shortName":"siemens-SADP","orgId":"0b142b55-0307-4c5a-b3c9-f314f3fb7c5e","dateUpdated":"2026-10-15T01:05:19.139Z"},"x_adpType":"supplier"}]}}}