{
  "affected": [
    {
      "ranges": [
        {
          "events": [
            {
              "introduced": "317d9a054e1c6d5f18b02b99ce09911942f8e603"
            },
            {
              "fixed": "decf312cdffb13c2c3b5d5217ae7d85e45150f88"
            },
            {
              "fixed": "e4c6ebf03802ee9e6de2be36d231462d30d49fb0"
            },
            {
              "fixed": "cddbf0c270b7bb2b21deb7dbcffd9802be23da4f"
            },
            {
              "fixed": "54f911b9c19582927c932b809e693db840b97e3e"
            },
            {
              "fixed": "f2143b4ecaf6afb81a785b6bf976274e16e58997"
            },
            {
              "fixed": "ff9f9a86b5b3e0942a96b6a1f91ed074090203c7"
            },
            {
              "fixed": "64d601ac18874892cb96bf81dab1fedfe77f41df"
            },
            {
              "fixed": "d30844001360a403a511cf24fc75ecaa6a7a7544"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        }
      ]
    },
    {
      "package": {
        "ecosystem": "Linux",
        "name": "Kernel"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "4.13.0"
            },
            {
              "fixed": "5.10.275"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "5.11.0"
            },
            {
              "fixed": "5.15.226"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "5.16.0"
            },
            {
              "fixed": "6.1.193"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "6.2.0"
            },
            {
              "fixed": "6.6.163"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "6.7.0"
            },
            {
              "fixed": "6.12.119"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "6.13.0"
            },
            {
              "fixed": "6.18.65"
            }
          ],
          "type": "ECOSYSTEM"
        },
        {
          "events": [
            {
              "introduced": "6.19.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-99833.json"
  },
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\napparmor: fix query_data() output overlapping the lookup key\n\nIn query_data(), buf and query point into the same multi_transaction\nbuffer: buf at the start, query a few bytes in, and the lookup key\nright after the label string that query points to. Reusing the buffer\nis by design and is safe as long as the query is fully parsed before\nbuf is written to, but the key is not: it is dereferenced on every\niteration of label_for_each_confined(), after output has already been\nwritten. So when the label has more than one profile with a data\ntable, the data of the first matching profile is written to buf while\nthe key is still needed, and overwrites it if the data is large enough.\nThe later lookups then run on a corrupted key. Besides, if the data has\nno NUL byte from the key's position to the end of the allocation,\nstrhash() -\u003e strlen() -\u003e jhash() reads past the 4096-byte slab object,\ntriggering an out-of-bound read:\n\n  BUG: KASAN: slab-out-of-bounds in jhash+0x595/0x5e0\n  Read of size 1 at addr ff1100001159d000 by task exploit/155\n  CPU: 0 UID: 1000 PID: 155 Comm: exploit Not tainted 7.3.0-rc7 #1\n  Call Trace:\n   jhash+0x595/0x5e0\n   aa_write_access+0x880/0x1400\n   vfs_write+0x26f/0xd20\n   ksys_write+0x115/0x210\n\nWriting to the .access file is unprivileged (0666), but triggering this\nrequires loaded profiles that carry a data table, which needs\nCAP_MAC_ADMIN and is not the case on default distribution policies.\n\nFix by copying the key with kstrdup() before writing any output to buf,\nso the key stays valid across all loop iterations regardless of what\ngets written to the overlapping buffer.",
  "id": "CVE-2026-99833",
  "modified": "2026-11-30T14:45:44.931991135Z",
  "published": "2026-11-30T13:17:28.645Z",
  "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/54f911b9c19582927c932b809e693db840b97e3e"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/64d601ac18874892cb96bf81dab1fedfe77f41df"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/cddbf0c270b7bb2b21deb7dbcffd9802be23da4f"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/d30844001360a403a511cf24fc75ecaa6a7a7544"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/decf312cdffb13c2c3b5d5217ae7d85e45150f88"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/e4c6ebf03802ee9e6de2be36d231462d30d49fb0"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/f2143b4ecaf6afb81a785b6bf976274e16e58997"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/ff9f9a86b5b3e0942a96b6a1f91ed074090203c7"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99833.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-99833"
    }
  ],
  "schema_version": "1.9.2",
  "summary": "apparmor: fix query_data() output overlapping the lookup key"
}