{
  "affected": [
    {
      "ranges": [
        {
          "events": [
            {
              "introduced": "d8ea44f6090c087fe255d9512fb808574b4d88e8"
            },
            {
              "fixed": "a20f98ffe158ea5eeb9932a3badbce267cd04917"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        },
        {
          "events": [
            {
              "introduced": "b1aea2c1960771a276d7e68c7424168eccd0c3da"
            },
            {
              "fixed": "43aba2eeaa34e045bdd73abfe66c8bd3fed97852"
            },
            {
              "fixed": "a913281f600157aa036b7c02afbb18a0ac115187"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        },
        {
          "events": [
            {
              "introduced": "d680472db98823d90fc91362910901e468269318"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        }
      ]
    },
    {
      "package": {
        "ecosystem": "Linux",
        "name": "Kernel"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "6.18.40"
            },
            {
              "fixed": "6.18.63"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "7.1.5"
            },
            {
              "fixed": "7.2"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "7.2.0"
            },
            {
              "fixed": "7.3.4"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "database_specific": {
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99847.json"
  },
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\napparmor: don't revalidate inherited files under files-\u003efile_lock\n\naa_inherit_files() revalidates inherited files on exec using\niterate_fd(), which calls the callback with files-\u003efile_lock held,\nso the revalidation is done with IN_ATOMIC. However the unix socket\nmediation path can sleep: aa_unix_file_perm() drops a ref on the\npeer's path with path_put(), and unix_fs_perm() -\u003e aa_path_perm()\nallocates a buffer with aa_get_buffer(false), resulting in\n\n  BUG: sleeping function called from invalid context at fs/dcache.c:1039\n  ...\n   dput.part.0+0x24/0x180\n   path_put+0x2c/0x60\n   aa_unix_file_perm+0x42a/0x17b0\n   aa_file_perm+0xcd3/0x1060\n   match_file+0x10b/0x190\n   iterate_fd+0xe6/0x280\n   aa_inherit_files+0x250/0x4f0\n\nOnly grab a ref on each file under iterate_fd(), and revalidate it\nafter the lock is dropped, so revalidation is done with no locks held\nand does not need to be atomic. Denied fds are still replaced with\n/dev/null, or closed if it can not be opened.",
  "id": "CVE-2026-99847",
  "modified": "2026-11-30T14:45:19.043741575Z",
  "published": "2026-11-30T13:17:36.624Z",
  "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/43aba2eeaa34e045bdd73abfe66c8bd3fed97852"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/a20f98ffe158ea5eeb9932a3badbce267cd04917"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/a913281f600157aa036b7c02afbb18a0ac115187"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99847.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-99847"
    }
  ],
  "schema_version": "1.9.2",
  "summary": "apparmor: don't revalidate inherited files under files-\u003efile_lock"
}