{"api_version":"1","generated_at":"2026-10-01T18:35:11+00:00","cve":"CVE-2026-90313","urls":{"html":"https://cve.report/CVE-2026-90313","api":"https://cve.report/api/cve/CVE-2026-90313.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-90313","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-90313"},"summary":{"title":"bpf, cgroup: Fix invalid storage access after __cgroup_bpf_attach failed","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf, cgroup: Fix invalid storage access after __cgroup_bpf_attach failed\n\nA potential invalid storage access issue can occur after replacing a\ncgroup bpf prog.\n\nThis occurs in the following scenario:\n1. prog1 with storage is attached to a cgroup in multi-attach mode.\n2. prog1 is replaced with prog2 using BPF_F_REPLACE in multi-attach\n   mode, but fails midway (e.g. in bpf_trampoline_link_cgroup_shim or\n   update_effective_progs).\n3. A new prog3 is attached to the cgroup in multi-attach mode.\n\nThe reason is that __cgroup_bpf_attach overwrites pl->storage with the\nnew storage prior to attachment completion. When attachment fails\nmidway, the cleanup path calls bpf_cgroup_storages_free(new_storage) to\nfree the newly allocated storage, but fails to restore pl->storage back\nto old_storage.\n\nConsequently, the still-active prog1 holds invalid or dangling storage\npointers, leading to an invalid memory access when prog1 executes and\ncalls bpf_get_local_storage. Additionally, original pl->flags and\ncgrp->bpf.flags[atype] are left unrestored.\n\nFix this by saving old_pl_flags, old_storage, and old_flags prior to the\nupdate, and properly restoring all of them in the cleanup path on error.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-09-17 17:17:29","updated_at":"2026-09-17 17:17:29"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/86ead176301109b78e1d14c0e9d0d9ff9723c769","name":"https://git.kernel.org/stable/c/86ead176301109b78e1d14c0e9d0d9ff9723c769","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/aaca16e042527f7efe48b50799bc662f1a191ce1","name":"https://git.kernel.org/stable/c/aaca16e042527f7efe48b50799bc662f1a191ce1","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/6655c409707ec8ce9ce0850ffe4fe02331fd4d9c","name":"https://git.kernel.org/stable/c/6655c409707ec8ce9ce0850ffe4fe02331fd4d9c","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/2c2218560b6e28a63ff7834ba26d09ff8efdee39","name":"https://git.kernel.org/stable/c/2c2218560b6e28a63ff7834ba26d09ff8efdee39","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/e26db0d636e4c24a6b16683ea95cf5077c64d74b","name":"https://git.kernel.org/stable/c/e26db0d636e4c24a6b16683ea95cf5077c64d74b","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-90313","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-90313","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7d9c3427894fe70d1347b4820476bf37736d2ff0 e26db0d636e4c24a6b16683ea95cf5077c64d74b git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7d9c3427894fe70d1347b4820476bf37736d2ff0 aaca16e042527f7efe48b50799bc662f1a191ce1 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7d9c3427894fe70d1347b4820476bf37736d2ff0 86ead176301109b78e1d14c0e9d0d9ff9723c769 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7d9c3427894fe70d1347b4820476bf37736d2ff0 2c2218560b6e28a63ff7834ba26d09ff8efdee39 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7d9c3427894fe70d1347b4820476bf37736d2ff0 6655c409707ec8ce9ce0850ffe4fe02331fd4d9c git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 5.9","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 5.9 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.6.157 6.6.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.12.110 6.12.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.18.52 6.18.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.2.6 7.2.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3-rc1 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["kernel/bpf/cgroup.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"e26db0d636e4c24a6b16683ea95cf5077c64d74b","status":"affected","version":"7d9c3427894fe70d1347b4820476bf37736d2ff0","versionType":"git"},{"lessThan":"aaca16e042527f7efe48b50799bc662f1a191ce1","status":"affected","version":"7d9c3427894fe70d1347b4820476bf37736d2ff0","versionType":"git"},{"lessThan":"86ead176301109b78e1d14c0e9d0d9ff9723c769","status":"affected","version":"7d9c3427894fe70d1347b4820476bf37736d2ff0","versionType":"git"},{"lessThan":"2c2218560b6e28a63ff7834ba26d09ff8efdee39","status":"affected","version":"7d9c3427894fe70d1347b4820476bf37736d2ff0","versionType":"git"},{"lessThan":"6655c409707ec8ce9ce0850ffe4fe02331fd4d9c","status":"affected","version":"7d9c3427894fe70d1347b4820476bf37736d2ff0","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["kernel/bpf/cgroup.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"5.9"},{"lessThan":"5.9","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"6.6.*","status":"unaffected","version":"6.6.157","versionType":"semver"},{"lessThanOrEqual":"6.12.*","status":"unaffected","version":"6.12.110","versionType":"semver"},{"lessThanOrEqual":"6.18.*","status":"unaffected","version":"6.18.52","versionType":"semver"},{"lessThanOrEqual":"7.2.*","status":"unaffected","version":"7.2.6","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.3-rc1","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.6.157","versionStartIncluding":"5.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.12.110","versionStartIncluding":"5.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.18.52","versionStartIncluding":"5.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.2.6","versionStartIncluding":"5.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3-rc1","versionStartIncluding":"5.9","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf, cgroup: Fix invalid storage access after __cgroup_bpf_attach failed\n\nA potential invalid storage access issue can occur after replacing a\ncgroup bpf prog.\n\nThis occurs in the following scenario:\n1. prog1 with storage is attached to a cgroup in multi-attach mode.\n2. prog1 is replaced with prog2 using BPF_F_REPLACE in multi-attach\n   mode, but fails midway (e.g. in bpf_trampoline_link_cgroup_shim or\n   update_effective_progs).\n3. A new prog3 is attached to the cgroup in multi-attach mode.\n\nThe reason is that __cgroup_bpf_attach overwrites pl->storage with the\nnew storage prior to attachment completion. When attachment fails\nmidway, the cleanup path calls bpf_cgroup_storages_free(new_storage) to\nfree the newly allocated storage, but fails to restore pl->storage back\nto old_storage.\n\nConsequently, the still-active prog1 holds invalid or dangling storage\npointers, leading to an invalid memory access when prog1 executes and\ncalls bpf_get_local_storage. Additionally, original pl->flags and\ncgrp->bpf.flags[atype] are left unrestored.\n\nFix this by saving old_pl_flags, old_storage, and old_flags prior to the\nupdate, and properly restoring all of them in the cleanup path on error."}],"providerMetadata":{"dateUpdated":"2026-09-17T16:08:32.932Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/e26db0d636e4c24a6b16683ea95cf5077c64d74b"},{"url":"https://git.kernel.org/stable/c/aaca16e042527f7efe48b50799bc662f1a191ce1"},{"url":"https://git.kernel.org/stable/c/86ead176301109b78e1d14c0e9d0d9ff9723c769"},{"url":"https://git.kernel.org/stable/c/2c2218560b6e28a63ff7834ba26d09ff8efdee39"},{"url":"https://git.kernel.org/stable/c/6655c409707ec8ce9ce0850ffe4fe02331fd4d9c"}],"title":"bpf, cgroup: Fix invalid storage access after __cgroup_bpf_attach failed","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-90313","datePublished":"2026-09-17T16:08:32.932Z","dateReserved":"2026-09-11T19:38:34.801Z","dateUpdated":"2026-09-17T16:08:32.932Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-09-17 17:17:29","lastModifiedDate":"2026-09-17 17:17:29","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"90313","Ordinal":"1","Title":"bpf, cgroup: Fix invalid storage access after __cgroup_bpf_attac","CVE":"CVE-2026-90313","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"90313","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf, cgroup: Fix invalid storage access after __cgroup_bpf_attach failed\n\nA potential invalid storage access issue can occur after replacing a\ncgroup bpf prog.\n\nThis occurs in the following scenario:\n1. prog1 with storage is attached to a cgroup in multi-attach mode.\n2. prog1 is replaced with prog2 using BPF_F_REPLACE in multi-attach\n   mode, but fails midway (e.g. in bpf_trampoline_link_cgroup_shim or\n   update_effective_progs).\n3. A new prog3 is attached to the cgroup in multi-attach mode.\n\nThe reason is that __cgroup_bpf_attach overwrites pl->storage with the\nnew storage prior to attachment completion. When attachment fails\nmidway, the cleanup path calls bpf_cgroup_storages_free(new_storage) to\nfree the newly allocated storage, but fails to restore pl->storage back\nto old_storage.\n\nConsequently, the still-active prog1 holds invalid or dangling storage\npointers, leading to an invalid memory access when prog1 executes and\ncalls bpf_get_local_storage. Additionally, original pl->flags and\ncgrp->bpf.flags[atype] are left unrestored.\n\nFix this by saving old_pl_flags, old_storage, and old_flags prior to the\nupdate, and properly restoring all of them in the cleanup path on error.","Type":"Description","Title":"bpf, cgroup: Fix invalid storage access after __cgroup_bpf_attac"}]}}}