{
  "affected": [
    {
      "ranges": [
        {
          "events": [
            {
              "introduced": "38ea4c3dc306edf6f4e483e8ad9cb8d33943afde"
            },
            {
              "fixed": "7d329eff434a7f55cb34fbda52d0295123783e78"
            },
            {
              "fixed": "400874c97fbf537f6a58b5bb72ef3f78e2e2db52"
            },
            {
              "fixed": "8c0f05570df41f7fe7cb8b9485647eaee8274343"
            },
            {
              "fixed": "ba8c3d5fc27ac3f86962641dd3b6600906234bab"
            }
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "type": "GIT"
        }
      ]
    },
    {
      "package": {
        "ecosystem": "Linux",
        "name": "Kernel"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "6.12.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.6"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "database_specific": {
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/139xxx/CVE-2026-139329.json"
  },
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\nALSA: jack: Protect the index scan against control removal\n\nA control found during a jack-name index scan must remain alive until\nsnd_ctl_find_id() finishes comparing its ID and count. However,\nget_available_index() calls it without holding card-\u003econtrols_rwsem.\nWith CONFIG_SND_CTL_FAST_LOOKUP enabled, the lookup loads a raw control\npointer from ctl_hash and dereferences it in elem_id_matches() without\nany lock that excludes removal.\n\nThis can happen when a jack is created while a different jack owner on\nthe same card removes an existing control with the same name and index.\nFor example, probe and unbind of different HDA codecs can reach these\npaths on a shared card if their generated jack names match.\nThe codec device locks do not serialize operations on different\ncodecs. The unbind path can free the control during the index scan:\n\n  Codec A: probe                  Codec B: unbind\n  --------------                  ---------------\n  get_available_index()\n    snd_ctl_find_id()\n      kctl = xa_load(...)\n                                  hda_codec_driver_remove()\n                                    snd_hda_codec_cleanup_for_unbind()\n                                      snd_hda_jack_tbl_clear()\n                                        snd_device_free()\n                                          __snd_device_free()\n                                            snd_jack_dev_free()\n                                              snd_ctl_remove()\n                                                snd_ctl_remove_locked()\n                                                  __snd_ctl_remove()\n                                                    snd_ctl_free_one()\n                                                      kfree(kctl)\n      elem_id_matches(kctl, ...)\n        read freed id/count -\u003e UAF\n\nHold controls_rwsem for read across the index scan so removal cannot\nfree a control until the lookup has finished using it. Release the lock\nwhen get_available_index() returns, before the caller adds the new\ncontrol under the write lock.",
  "id": "CVE-2026-139329",
  "modified": "2026-11-30T14:45:24.761511854Z",
  "published": "2026-11-30T13:33:45.362Z",
  "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/400874c97fbf537f6a58b5bb72ef3f78e2e2db52"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/7d329eff434a7f55cb34fbda52d0295123783e78"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/8c0f05570df41f7fe7cb8b9485647eaee8274343"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/ba8c3d5fc27ac3f86962641dd3b6600906234bab"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/139xxx/CVE-2026-139329.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-139329"
    }
  ],
  "schema_version": "1.9.2",
  "summary": "ALSA: jack: Protect the index scan against control removal"
}