CVE-2021-47502 (GCVE-0-2021-47502)
Vulnerability from cvelistv5
Published
2024-05-24 15:01
Modified
2026-08-05 08:48
Summary
In the Linux kernel, the following vulnerability has been resolved: ASoC: codecs: wcd934x: handle channel mappping list correctly Currently each channel is added as list to dai channel list, however there is danger of adding same channel to multiple dai channel list which endups corrupting the other list where its already added. This patch ensures that the channel is actually free before adding to the dai channel list and also ensures that the channel is on the list before deleting it. This check was missing previously, and we did not hit this issue as we were testing very simple usecases with sequence of amixer commands.
Impacted products
Vendor Product Version
Linux Linux Version: dd9eb19b567303e4b92747dcfb5deedb182af111
Version: dd9eb19b567303e4b92747dcfb5deedb182af111
Version: dd9eb19b567303e4b92747dcfb5deedb182af111
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2021-47502",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-05-24T19:19:30.436874Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-06-04T17:14:49.622Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-04T05:39:59.770Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/1089dac26c6b4b833323ae6c0ceab29fb30ede72"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/339ffb5b56005582aacc860524d2d208604049d1"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/23ba28616d3063bd4c4953598ed5e439ca891101"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "sound/soc/codecs/wcd934x.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "1089dac26c6b4b833323ae6c0ceab29fb30ede72",
              "status": "affected",
              "version": "dd9eb19b567303e4b92747dcfb5deedb182af111",
              "versionType": "git"
            },
            {
              "lessThan": "339ffb5b56005582aacc860524d2d208604049d1",
              "status": "affected",
              "version": "dd9eb19b567303e4b92747dcfb5deedb182af111",
              "versionType": "git"
            },
            {
              "lessThan": "23ba28616d3063bd4c4953598ed5e439ca891101",
              "status": "affected",
              "version": "dd9eb19b567303e4b92747dcfb5deedb182af111",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "sound/soc/codecs/wcd934x.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.6"
            },
            {
              "lessThan": "5.6",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.85",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.8",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "5.16",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.85",
                  "versionStartIncluding": "5.6",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.8",
                  "versionStartIncluding": "5.6",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.16",
                  "versionStartIncluding": "5.6",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nASoC: codecs: wcd934x: handle channel mappping list correctly\n\nCurrently each channel is added as list to dai channel list, however\nthere is danger of adding same channel to multiple dai channel list\nwhich endups corrupting the other list where its already added.\n\nThis patch ensures that the channel is actually free before adding to\nthe dai channel list and also ensures that the channel is on the list\nbefore deleting it.\n\nThis check was missing previously, and we did not hit this issue as\nwe were testing very simple usecases with sequence of amixer commands."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7.8,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:L - The bug is reached via ALSA mixer ioctls (SNDRV_CTL_IOCTL_ELEM_WRITE) on /dev/snd/controlC*, writing DAPM controls such as \"SLIM RX* Mux\" / \"SLIM TX*\" that call slim_rx_mux_put/slim_tx_mixer_put. This requires local device access, not network or physical proximity.\nAC:L - An attacker can reliably trigger corruption with a simple amixer sequence that switches a channel from one AIF to another without returning to ZERO, which performs list_add_tail on a node still linked on another DAI list. No race or external conditions are required; the commit notes this occurs with sequential amixer commands.\nPR:L - snd_ctl_elem_write has no capability check; access is only via /dev/snd/controlC* permissions (typically root:audio 0660). On WCD934x devices (e.g. Qualcomm phones), an unprivileged local user or process in the audio group can exercise these controls, which is Low privilege, not root.\nUI:N - The attacker opens the ALSA control device and writes mixer values directly; no victim action such as mounting a filesystem or opening a malicious file is required.\nS:U - Impact stays within the host kernel\u2019s authority (local memory corruption / privilege escalation). There is no VM escape, IOMMU bypass, or other cross-boundary scope change.\nC:H - Double-linking a channel corrupts DAI slim_ch_list pointers so list_for_each_entry can follow into another list_head and container_of it as a wcd934x_slim_ch (list is not at offset 0), yielding type-confused reads of adjacent kernel memory. Per memory-corruption guidance this is High confidentiality impact.\nI:H - Kernel linked-list corruption and type-confused list walks/list_del updates can poison next/prev pointers and produce write-what-where style integrity damage, enabling control-flow hijacking rather than a pure crash. This meets High integrity impact for exploitable memory corruption.\nA:H - Corrupted lists cause infinite list walks (kernel hang) or oopses when DAPM/PCM paths (enable_slim, set_hw_params, get_channel_map) iterate slim_ch_list, which is High availability impact."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T08:48:08.082Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/1089dac26c6b4b833323ae6c0ceab29fb30ede72"
        },
        {
          "url": "https://git.kernel.org/stable/c/339ffb5b56005582aacc860524d2d208604049d1"
        },
        {
          "url": "https://git.kernel.org/stable/c/23ba28616d3063bd4c4953598ed5e439ca891101"
        }
      ],
      "title": "ASoC: codecs: wcd934x: handle channel mappping list correctly",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2021-47502",
    "datePublished": "2024-05-24T15:01:49.699Z",
    "dateReserved": "2024-05-22T06:20:56.204Z",
    "dateUpdated": "2026-08-05T08:48:08.082Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "vulnrichment": {
      "containers": "{\"adp\": [{\"title\": \"CVE Program Container\", \"references\": [{\"url\": \"https://git.kernel.org/stable/c/1089dac26c6b4b833323ae6c0ceab29fb30ede72\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/339ffb5b56005582aacc860524d2d208604049d1\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/23ba28616d3063bd4c4953598ed5e439ca891101\", \"tags\": [\"x_transferred\"]}], \"providerMetadata\": {\"orgId\": \"af854a3a-2127-422b-91ae-364da2661108\", \"shortName\": \"CVE\", \"dateUpdated\": \"2024-08-04T05:39:59.770Z\"}}, {\"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2021-47502\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2024-05-24T19:19:30.436874Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2024-05-24T19:19:41.387Z\"}, \"title\": \"CISA ADP Vulnrichment\"}], \"cna\": {\"title\": \"ASoC: codecs: wcd934x: handle channel mappping list correctly\", \"metrics\": [{\"cvssV3_1\": {\"version\": \"3.1\", \"baseScore\": 7.8, \"baseSeverity\": \"HIGH\", \"vectorString\": \"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H\"}, \"scenarios\": [{\"lang\": \"en\", \"value\": \"AV:L - The bug is reached via ALSA mixer ioctls (SNDRV_CTL_IOCTL_ELEM_WRITE) on /dev/snd/controlC*, writing DAPM controls such as \\\"SLIM RX* Mux\\\" / \\\"SLIM TX*\\\" that call slim_rx_mux_put/slim_tx_mixer_put. This requires local device access, not network or physical proximity.\\nAC:L - An attacker can reliably trigger corruption with a simple amixer sequence that switches a channel from one AIF to another without returning to ZERO, which performs list_add_tail on a node still linked on another DAI list. No race or external conditions are required; the commit notes this occurs with sequential amixer commands.\\nPR:L - snd_ctl_elem_write has no capability check; access is only via /dev/snd/controlC* permissions (typically root:audio 0660). On WCD934x devices (e.g. Qualcomm phones), an unprivileged local user or process in the audio group can exercise these controls, which is Low privilege, not root.\\nUI:N - The attacker opens the ALSA control device and writes mixer values directly; no victim action such as mounting a filesystem or opening a malicious file is required.\\nS:U - Impact stays within the host kernel\\u2019s authority (local memory corruption / privilege escalation). There is no VM escape, IOMMU bypass, or other cross-boundary scope change.\\nC:H - Double-linking a channel corrupts DAI slim_ch_list pointers so list_for_each_entry can follow into another list_head and container_of it as a wcd934x_slim_ch (list is not at offset 0), yielding type-confused reads of adjacent kernel memory. Per memory-corruption guidance this is High confidentiality impact.\\nI:H - Kernel linked-list corruption and type-confused list walks/list_del updates can poison next/prev pointers and produce write-what-where style integrity damage, enabling control-flow hijacking rather than a pure crash. This meets High integrity impact for exploitable memory corruption.\\nA:H - Corrupted lists cause infinite list walks (kernel hang) or oopses when DAPM/PCM paths (enable_slim, set_hw_params, get_channel_map) iterate slim_ch_list, which is High availability impact.\"}]}], \"affected\": [{\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"dd9eb19b567303e4b92747dcfb5deedb182af111\", \"lessThan\": \"1089dac26c6b4b833323ae6c0ceab29fb30ede72\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"dd9eb19b567303e4b92747dcfb5deedb182af111\", \"lessThan\": \"339ffb5b56005582aacc860524d2d208604049d1\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"dd9eb19b567303e4b92747dcfb5deedb182af111\", \"lessThan\": \"23ba28616d3063bd4c4953598ed5e439ca891101\", \"versionType\": \"git\"}], \"programFiles\": [\"sound/soc/codecs/wcd934x.c\"], \"defaultStatus\": \"unaffected\"}, {\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"5.6\"}, {\"status\": \"unaffected\", \"version\": \"0\", \"lessThan\": \"5.6\", \"versionType\": \"semver\"}, {\"status\": \"unaffected\", \"version\": \"5.10.85\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"5.10.*\"}, {\"status\": \"unaffected\", \"version\": \"5.15.8\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"5.15.*\"}, {\"status\": \"unaffected\", \"version\": \"5.16\", \"versionType\": \"original_commit_for_fix\", \"lessThanOrEqual\": \"*\"}], \"programFiles\": [\"sound/soc/codecs/wcd934x.c\"], \"defaultStatus\": \"affected\"}], \"references\": [{\"url\": \"https://git.kernel.org/stable/c/1089dac26c6b4b833323ae6c0ceab29fb30ede72\"}, {\"url\": \"https://git.kernel.org/stable/c/339ffb5b56005582aacc860524d2d208604049d1\"}, {\"url\": \"https://git.kernel.org/stable/c/23ba28616d3063bd4c4953598ed5e439ca891101\"}], \"x_generator\": {\"engine\": \"bippy-1.2.0\"}, \"descriptions\": [{\"lang\": \"en\", \"value\": \"In the Linux kernel, the following vulnerability has been resolved:\\n\\nASoC: codecs: wcd934x: handle channel mappping list correctly\\n\\nCurrently each channel is added as list to dai channel list, however\\nthere is danger of adding same channel to multiple dai channel list\\nwhich endups corrupting the other list where its already added.\\n\\nThis patch ensures that the channel is actually free before adding to\\nthe dai channel list and also ensures that the channel is on the list\\nbefore deleting it.\\n\\nThis check was missing previously, and we did not hit this issue as\\nwe were testing very simple usecases with sequence of amixer commands.\"}], \"cpeApplicability\": [{\"nodes\": [{\"negate\": false, \"cpeMatch\": [{\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.10.85\", \"versionStartIncluding\": \"5.6\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.15.8\", \"versionStartIncluding\": \"5.6\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.16\", \"versionStartIncluding\": \"5.6\"}], \"operator\": \"OR\"}]}], \"providerMetadata\": {\"orgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"shortName\": \"Linux\", \"dateUpdated\": \"2026-08-05T08:48:08.082Z\"}}}",
      "cveMetadata": "{\"cveId\": \"CVE-2021-47502\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2026-08-05T08:48:08.082Z\", \"dateReserved\": \"2024-05-22T06:20:56.204Z\", \"assignerOrgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"datePublished\": \"2024-05-24T15:01:49.699Z\", \"assignerShortName\": \"Linux\"}",
      "dataType": "CVE_RECORD",
      "dataVersion": "5.2"
    }
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…