{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2022-50048",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2025-06-18T10:57:27.402Z",
        "datePublished": "2025-06-18T11:01:48.893Z",
        "dateUpdated": "2026-08-05T08:57:14.148Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-08-05T08:57:14.148Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nnetfilter: nf_tables: possible module reference underflow in error path\n\ndst->ops is set on when nft_expr_clone() fails, but module refcount has\nnot been bumped yet, therefore nft_expr_destroy() leads to module\nreference underflow."
                }
            ],
            "metrics": [
                {
                    "cvssV3_1": {
                        "version": "3.1",
                        "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
                        "baseScore": 7.8,
                        "baseSeverity": "HIGH"
                    },
                    "scenarios": [
                        {
                            "lang": "en",
                            "value": "AV:L - The bug is reached only through the local NETLINK_NETFILTER/nf_tables path (NFT_MSG_NEWSETELEM → nft_add_set_elem → nft_set_elem_expr_clone, or dynset init), which requires opening a netlink socket; it is not reachable from remote packet processing.\nAC:L - The attacker fully controls set creation with a stateful clone-capable expression (counter/limit/quota/last/connlimit) and element adds that omit per-element expressions, and can induce the GFP_ATOMIC clone allocation failure via memory pressure, so the underflow is reliably triggerable with no race or luck.\nPR:L - nfnetlink_rcv() gates on netlink_net_capable(skb, CAP_NET_ADMIN) against the network namespace's user_ns, so an ordinary unprivileged user obtains the needed capability via unshare -Urn on default distributions.\nUI:N - The attacker creates the set, induces clone failure, and triggers the destroy/module_put error path entirely from their own process with no victim action required.\nS:U - Impact is confined to the host kernel (module UAF / refcount corruption and privilege escalation within the same OS security authority); no VM, IOMMU, or hypervisor boundary is crossed.\nC:H - The erroneous module_put without a matching get underflows the expression module's refcount so it can be unloaded while set expressions still reference its ops/code, yielding a classic module UAF that enables arbitrary kernel memory disclosure.\nI:H - Premature unload of nft_limit/nft_quota/nft_connlimit (or nf_tables for built-in counter/last) leaves live expression ops pointing into freed module memory that can be sprayed for control-flow hijack; the connlimit path also wrongly calls nf_ct_netns_put, compounding refcount corruption.\nA:H - On connlimit, destroy runs nf_conncount_cache_free(NULL) and NULL-dereferences; on other expressions the module refcount underflow/UAF produces oops/panic, so availability impact is High even without full exploitation."
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "net/netfilter/nf_tables_api.c"
                    ],
                    "versions": [
                        {
                            "version": "8cfd9b0f8515e7c361bba27e2a2684cbd427fe01",
                            "lessThan": "b59bee8b05b0e789b5a298cacb09e8aaa3367a29",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "8cfd9b0f8515e7c361bba27e2a2684cbd427fe01",
                            "lessThan": "1e52e6cfec6342c3d0df47dc3a76724fb3dabf56",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "8cfd9b0f8515e7c361bba27e2a2684cbd427fe01",
                            "lessThan": "c485c35ff6783ccd12c160fcac6a0e504e83e0bf",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "net/netfilter/nf_tables_api.c"
                    ],
                    "versions": [
                        {
                            "version": "5.11",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "5.11",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.15.63",
                            "lessThanOrEqual": "5.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.19.4",
                            "lessThanOrEqual": "5.19.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.0",
                            "lessThanOrEqual": "*",
                            "status": "unaffected",
                            "versionType": "original_commit_for_fix"
                        }
                    ]
                }
            ],
            "cpeApplicability": [
                {
                    "nodes": [
                        {
                            "operator": "OR",
                            "negate": false,
                            "cpeMatch": [
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.11",
                                    "versionEndExcluding": "5.15.63"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.11",
                                    "versionEndExcluding": "5.19.4"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.11",
                                    "versionEndExcluding": "6.0"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/b59bee8b05b0e789b5a298cacb09e8aaa3367a29"
                },
                {
                    "url": "https://git.kernel.org/stable/c/1e52e6cfec6342c3d0df47dc3a76724fb3dabf56"
                },
                {
                    "url": "https://git.kernel.org/stable/c/c485c35ff6783ccd12c160fcac6a0e504e83e0bf"
                }
            ],
            "title": "netfilter: nf_tables: possible module reference underflow in error path",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        }
    }
}