{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2026-142976",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2026-12-03T03:10:28.341Z",
        "datePublished": "2026-12-03T09:17:06.769Z",
        "dateUpdated": "2026-12-03T09:17:06.769Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-12-03T09:17:06.769Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nw1: remove the master's files before taking its locks\n\n__w1_remove_master_device() calls w1_destroy_master_attributes() with\nboth the mutex of the master and list_mutex held.  Removing the files\nwaits for the callbacks which are running, and nearly all of them take\none of these two locks:\n\n  __w1_remove_master_device()           read() of .../w1_master_slaves\n    mutex_lock(&dev->mutex)               kernfs active reference\n    mutex_lock(&dev->list_mutex)          w1_master_attribute_show_slaves()\n    w1_destroy_master_attributes()          mutex_lock(&md->list_mutex)\n      sysfs_remove_group()                    waits\n        waits for the reference\n\nThe files are readable for everybody, and a bus master goes away when, for\ninstance, a DS2490 USB adapter is unplugged.\n\nRemove the files first, before the locks are taken.  That has to be done\nbefore the slaves are detached and not afterwards: as long as the files\nexist, a write to w1_master_add could attach a new slave behind the back\nof this function, which would then wait for the reference count of the\nmaster for ever.  And it is done before the thread is stopped, because a\nwrite to w1_master_search wakes the thread up."
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "drivers/w1/w1_int.c"
                    ],
                    "versions": [
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "da32f7a50135cf804947ab89f73edc846e60bb58",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "00a15f18d3e9780e6fa3747982edc66ba99db5d9",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "c388ba89918ee0d33e4d30972051bd3ab30ae9c5",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "ac2505e34311d46b4ff03eed67547499ee4450ca",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "a07b44d9a463f04928aa65b1d03dd42417c62ae6",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "c30c9b15187e977ab5928f7276e9dfcd8d6f9460",
                            "lessThan": "dfc57752ec53c3cc6105656d3037fb2f5e80e9cc",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "drivers/w1/w1_int.c"
                    ],
                    "versions": [
                        {
                            "version": "2.6.28",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "2.6.28",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.10.276",
                            "lessThanOrEqual": "5.10.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.15.227",
                            "lessThanOrEqual": "5.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.12.120",
                            "lessThanOrEqual": "6.12.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.18.66",
                            "lessThanOrEqual": "6.18.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "7.3.7",
                            "lessThanOrEqual": "7.3.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "7.4-rc4",
                            "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": "2.6.28",
                                    "versionEndExcluding": "5.10.276"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.28",
                                    "versionEndExcluding": "5.15.227"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.28",
                                    "versionEndExcluding": "6.12.120"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.28",
                                    "versionEndExcluding": "6.18.66"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.28",
                                    "versionEndExcluding": "7.3.7"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.28",
                                    "versionEndExcluding": "7.4-rc4"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/da32f7a50135cf804947ab89f73edc846e60bb58"
                },
                {
                    "url": "https://git.kernel.org/stable/c/00a15f18d3e9780e6fa3747982edc66ba99db5d9"
                },
                {
                    "url": "https://git.kernel.org/stable/c/c388ba89918ee0d33e4d30972051bd3ab30ae9c5"
                },
                {
                    "url": "https://git.kernel.org/stable/c/ac2505e34311d46b4ff03eed67547499ee4450ca"
                },
                {
                    "url": "https://git.kernel.org/stable/c/a07b44d9a463f04928aa65b1d03dd42417c62ae6"
                },
                {
                    "url": "https://git.kernel.org/stable/c/dfc57752ec53c3cc6105656d3037fb2f5e80e9cc"
                }
            ],
            "title": "w1: remove the master's files before taking its locks",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        }
    }
}