{
  "affected": [
    {
      "ranges": [
        {
          "events": [
            {
              "introduced": "e631df89cd5d638a9d7c152dd9b0a92643efab3e"
            },
            {
              "fixed": "49b4791b48c1240084eb137ca2a2ea18de128461"
            },
            {
              "fixed": "e227cdac03dffa896e02ed7260f9149c4c382715"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        }
      ]
    },
    {
      "package": {
        "ecosystem": "Linux",
        "name": "Kernel"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "6.19.0"
            },
            {
              "fixed": "7.3.6"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "database_specific": {
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/142xxx/CVE-2026-142890.json"
  },
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\nnamei: don't assert S_ISDIR on a stale rcu-walk inode\n\nlookup_inode_permission_may_exec() asserts that it is only ever handed a\ndirectory, on the grounds that link_path_walk() has already checked\nd_can_lookup().  In rcu-walk that does not follow.  step_into() samples\n-\u003ed_inode and validates it against -\u003ed_seq, but link_path_walk() loads\n-\u003ed_flags again afterwards, and nothing orders that load against changes\nof the dentry:\n\n  CPU0 (rcu-walk of \"x/y\")              CPU1\n  step_into(x)\n    inode = x-\u003ed_inode   // regular file\n    read_seqcount_retry(\u0026x-\u003ed_seq) == 0\n    nd-\u003einode = inode\n                                        unlink(\"x\")\n                                          d_delete()  // x goes negative\n                                        mkdir(\"x\")\n                                          d_instantiate()  // same dentry\n  d_can_lookup(x)        // true now\n  may_lookup()\n    VFS_BUG_ON_INODE(!S_ISDIR(nd-\u003einode-\u003ei_mode))\n\nWith CONFIG_PREEMPT_RCU the walker can be preempted in that window, so it\nis not limited to a few instructions.  mkdir() only gets the same dentry\nback if the filesystem keeps negative dentries around.  tmpfs doesn't,\next4 does.\n\nApart from the assertion the stale inode is harmless, and has been there\nsince before the assertion was added: nd-\u003eseq no longer matches x-\u003ed_seq,\nso lookup_fast(), follow_dotdot_rcu() and try_to_unlazy() all fail with\n-ECHILD and the walk is redone in ref-walk, whatever the permission check\non the old inode said.\n\nKeep the assertion for ref-walk, where the dentry is pinned and can't\nchange type, and skip it for rcu-walk.  No change for kernels without\nCONFIG_DEBUG_VFS.",
  "id": "CVE-2026-142890",
  "modified": "2026-12-03T04:45:51.486745760Z",
  "published": "2026-12-03T03:25:43.087Z",
  "references": [
    {
      "type": "PACKAGE",
      "url": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/49b4791b48c1240084eb137ca2a2ea18de128461"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/e227cdac03dffa896e02ed7260f9149c4c382715"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/142xxx/CVE-2026-142890.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-142890"
    }
  ],
  "schema_version": "1.9.2",
  "summary": "namei: don't assert S_ISDIR on a stale rcu-walk inode"
}