{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2022-50668",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2025-12-09T01:26:45.990Z",
        "datePublished": "2025-12-09T01:29:19.526Z",
        "dateUpdated": "2026-08-05T08:59:19.230Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-08-05T08:59:19.230Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\next4: fix deadlock due to mbcache entry corruption\n\nWhen manipulating xattr blocks, we can deadlock infinitely looping\ninside ext4_xattr_block_set() where we constantly keep finding xattr\nblock for reuse in mbcache but we are unable to reuse it because its\nreference count is too big. This happens because cache entry for the\nxattr block is marked as reusable (e_reusable set) although its\nreference count is too big. When this inconsistency happens, this\ninconsistent state is kept indefinitely and so ext4_xattr_block_set()\nkeeps retrying indefinitely.\n\nThe inconsistent state is caused by non-atomic update of e_reusable bit.\ne_reusable is part of a bitfield and e_reusable update can race with\nupdate of e_referenced bit in the same bitfield resulting in loss of one\nof the updates. Fix the problem by using atomic bitops instead.\n\nThis bug has been around for many years, but it became *much* easier\nto hit after commit 65f8b80053a1 (\"ext4: fix race when reusing xattr\nblocks\")."
                }
            ],
            "metrics": [
                {
                    "cvssV3_1": {
                        "version": "3.1",
                        "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
                        "baseScore": 7.5,
                        "baseSeverity": "HIGH"
                    },
                    "scenarios": [
                        {
                            "lang": "en",
                            "value": "AV:N - The vulnerable ext4 xattr reuse path is reachable via VFS setxattr, and the same operations are driven remotely through in-kernel servers such as ksmbd and nfsd on an ext4-backed writable export, a reasonable severe deployment for file servers.\nAC:L - The attacker controls both sides of the race by issuing concurrent setxattr/removexattr operations that update e_reusable and e_referenced on a shared mbcache entry; creating ~1024 files with identical xattrs to reach REFCOUNT_MAX is also attacker-controlled.\nPR:N - In the most severe reasonable deployment, a guest/anonymous writable network export exposes create and xattr operations without real authentication; AUTH_SYS NFS UID spoofing similarly requires no privileged credentials.\nUI:N - The attacker triggers the bug directly by issuing filesystem requests; no separate victim action such as mounting a crafted image is required.\nS:U - The hang remains within the kernel/filesystem security authority with no VM escape, IOMMU bypass, or other cross-boundary impact.\nC:N - The bug only corrupts mbcache flag state into an inconsistent reusable/refcount combination; it does not disclose kernel or filesystem contents.\nI:N - There is no exploitable memory corruption or attacker-controlled data modification; the inconsistent flags only cause an infinite retry loop, not integrity compromise of stored data.\nA:H - ext4_xattr_block_set() loops indefinitely while holding a journal handle and inode xattr_sem, causing hung tasks and filesystem-wide denial of service; deadlock/infinite loop is high availability impact."
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "fs/ext4/xattr.c",
                        "fs/mbcache.c",
                        "include/linux/mbcache.h"
                    ],
                    "versions": [
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "efaa0ca678f56d47316a08030b2515678cebbc50",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "af53065276376750dfac35a7248af18806404c5d",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "1be16a0c2f10186df505e28b0cc92d7f3366e2a8",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "5bc0b2fda4b47c86278f7c6d30c211f425bf51cf",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "127b80cefb941a81255c72f11081123f3a705369",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "cc1538c693d25e282bed8c54b65c914a04023a78",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6048c64b26097a0ffbd966866b599f990e674e9b",
                            "lessThan": "a44e84a9b7764c72896f7241a0ec9ac7e7ef38dd",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "fs/ext4/xattr.c",
                        "fs/mbcache.c",
                        "include/linux/mbcache.h"
                    ],
                    "versions": [
                        {
                            "version": "4.6",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "4.6",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "4.19.270",
                            "lessThanOrEqual": "4.19.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.4.229",
                            "lessThanOrEqual": "5.4.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.10.163",
                            "lessThanOrEqual": "5.10.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.15.87",
                            "lessThanOrEqual": "5.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.0.18",
                            "lessThanOrEqual": "6.0.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.1.4",
                            "lessThanOrEqual": "6.1.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.2",
                            "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": "4.6",
                                    "versionEndExcluding": "4.19.270"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "5.4.229"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "5.10.163"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "5.15.87"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "6.0.18"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "6.1.4"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "4.6",
                                    "versionEndExcluding": "6.2"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/efaa0ca678f56d47316a08030b2515678cebbc50"
                },
                {
                    "url": "https://git.kernel.org/stable/c/af53065276376750dfac35a7248af18806404c5d"
                },
                {
                    "url": "https://git.kernel.org/stable/c/1be16a0c2f10186df505e28b0cc92d7f3366e2a8"
                },
                {
                    "url": "https://git.kernel.org/stable/c/5bc0b2fda4b47c86278f7c6d30c211f425bf51cf"
                },
                {
                    "url": "https://git.kernel.org/stable/c/127b80cefb941a81255c72f11081123f3a705369"
                },
                {
                    "url": "https://git.kernel.org/stable/c/cc1538c693d25e282bed8c54b65c914a04023a78"
                },
                {
                    "url": "https://git.kernel.org/stable/c/a44e84a9b7764c72896f7241a0ec9ac7e7ef38dd"
                }
            ],
            "title": "ext4: fix deadlock due to mbcache entry corruption",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        }
    }
}