{"id":"CVE-2026-90099","aliases":["CVE-2026-90099"],"related":[],"kind":"vulnerability","state":"published","title":"net/sched: account classifier filter allocations to memcg","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nnet/sched: account classifier filter allocations to memcg\n\nAllocations in the tc classifier *_change() paths (filter objects,\nper-CPU counters, and per-filter aux data) use plain GFP_KERNEL without\n__GFP_ACCOUNT, allowing unprivileged users to pin kernel memory outside\nmemcg charging. The shared tcf_exts_init_ex() action array allocation in\ncls_api.c was also uncharged; this patch closes it along with the\nper-classifier filter-object/percpu/aux allocations that remain\nunaccounted.\n\nAdd GFP_KERNEL_ACCOUNT to:\n- the shared tcf_exts_init_ex() action array (cls_api.c), common to every\n  filter of every classifier (32 pointers, 256 bytes);\n- the filter-object, per-CPU-counter, and per-filter aux allocations in\n  cls_basic, cls_bpf, cls_cgroup, cls_flow, cls_flower, cls_fw,\n  cls_matchall, cls_route and cls_u32;\n- the u32_init_knode() replace-path knode allocation (cls_u32.c), which\n  allocates the same struct tc_u_knode + sel.keys on every replace of an\n  existing knode and was missed by the create-path-only conversion.\n\nAlso fix the cls_basic error path: basic_change() inserts fnew into the\nIDR before allocating the per-CPU counter. If alloc_percpu() fails the\nerrout path kfree'd fnew without idr_remove, leaving a dangling pointer\nin the IDR. With GFP_KERNEL_ACCOUNT the percpu alloc becomes failable\non demand (memcg at memory.max), making the dead path attacker-reachable\nand burning the handle permanently. Add the idr_remove on the percpu\nfailure path, matching the basic_set_parms failure-path pattern.\n\nNote: vega@nebusec.ai provided a poc for basic_cls, but it was easy to\nextend to the other classifiers.\n\nConditions to recreate the bug:\n- CONFIG_NET_SCHED, CONFIG_NET_CLS_* (the classifier being used),\n  CONFIG_NET_CLS_ACT, CONFIG_MEMCG, CONFIG_USER_NS, CONFIG_NET_NS.\n- Unprivileged user in a fresh user+network namespace (unshare -Urn),\n  or root with CAP_NET_ADMIN.\n- Create a large number of tc filters (e.g. tc filter add dev lo\n  ingress ... <classifier> ...) while watching a memcg-limited cgroup:\n  system slab grows far faster than memory.current, pinning kernel\n  memory outside memcg charging.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nnet/sched: account classifier filter allocations to memcg\n\nAllocations in the tc classifier *_change() paths (filter objects,\nper-CPU counters, and per-filter aux data) use plain GFP_KERNEL without\n__GFP_ACCOUNT, allowing unprivileged users to pin kernel memory outside\nmemcg charging. The shared tcf_exts_init_ex() action array allocation in\ncls_api.c was also uncharged; this patch closes it along with the\nper-classifier filter-object/percpu/aux allocations that remain\nunaccounted.\n\nAdd GFP_KERNEL_ACCOUNT to:\n- the shared tcf_exts_init_ex() action array (cls_api.c), common to every\n  filter of every classifier (32 pointers, 256 bytes);\n- the filter-object, per-CPU-counter, and per-filter aux allocations in\n  cls_basic, cls_bpf, cls_cgroup, cls_flow, cls_flower, cls_fw,\n  cls_matchall, cls_route and cls_u32;\n- the u32_init_knode() replace-path knode allocation (cls_u32.c), which\n  allocates the same struct tc_u_knode + sel.keys on every replace of an\n  existing knode and was missed by the create-path-only conversion.\n\nAlso fix the cls_basic error path: basic_change() inserts fnew into the\nIDR before allocating the per-CPU counter. If alloc_percpu() fails the\nerrout path kfree'd fnew without idr_remove, leaving a dangling pointer\nin the IDR. With GFP_KERNEL_ACCOUNT the percpu alloc becomes failable\non demand (memcg at memory.max), making the dead path attacker-reachable\nand burning the handle permanently. Add the idr_remove on the percpu\nfailure path, matching the basic_set_parms failure-path pattern.\n\nNote: vega@nebusec.ai provided a poc for basic_cls, but it was easy to\nextend to the other classifiers.\n\nConditions to recreate the bug:\n- CONFIG_NET_SCHED, CONFIG_NET_CLS_* (the classifier being used),\n  CONFIG_NET_CLS_ACT, CONFIG_MEMCG, CONFIG_USER_NS, CONFIG_NET_NS.\n- Unprivileged user in a fresh user+network namespace (unshare -Urn),\n  or root with CAP_NET_ADMIN.\n- Create a large number of tc filters (e.g. tc filter add dev lo\n  ingress ... <classifier> ...) while watching a memcg-limited cgroup:\n  system slab grows far faster than memory.current, pinning kernel\n  memory outside memcg charging.","source":"cvelist"}],"published":"2026-09-17T16:06:10.858Z","modified":"2026-10-30T13:20:41.400Z","severities":[],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"8a622d5b4d81c1572f42bbf3fb823b6e63d44dae","status":"affected"},{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"5fbb06d4f3d4c509ffe95572384a498bf319e5bf","status":"affected"},{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"bf6006cea193cf065f7a64fc7974247f8112af33","status":"affected"},{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"68fb30607169c92de57c5c82b6af8a733af1cc09","status":"affected"},{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"18c68c8f3d3ff0a4def1391021b439c4333a6c71","status":"affected"},{"type":"git","introduced":"0da974f4f303a6842516b764507e3c0a03f41e5a","fixed":"1beb81947eb486716af80db7a584f9e9fef7e003","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"2.6.18","status":"affected"},{"type":"semver","introduced":"0","fixed":"2.6.18","status":"unaffected"},{"type":"semver","introduced":"6.1.191","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.160","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.114","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.57","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"7.2.6","lastAffected":"7.2.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.3","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"}],"references":[{"url":"https://git.kernel.org/stable/c/8a622d5b4d81c1572f42bbf3fb823b6e63d44dae","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/5fbb06d4f3d4c509ffe95572384a498bf319e5bf","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/bf6006cea193cf065f7a64fc7974247f8112af33","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/68fb30607169c92de57c5c82b6af8a733af1cc09","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/18c68c8f3d3ff0a4def1391021b439c4333a6c71","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/1beb81947eb486716af80db7a584f9e9fef7e003","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-90099","url":"https://www.cve.org/CVERecord?id=CVE-2026-90099","licence":"CVE Terms of Use","modified":"2026-10-30T12:34:07.767Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-90099","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-90099","licence":"Public domain","modified":"2026-10-30T13:20:41.400Z"}],"updatedAt":"2026-11-25T22:59:39.303Z","epss":{"score":0.00215,"percentile":0.0673,"date":"2026-11-30T12:00:22.000Z"}}