7.1
HIGH
CVE-2021-46980
Linux Kernel USB Type-C UCSI PDO Array Index Out-of-Bounds Write
Description

In the Linux kernel, the following vulnerability has been resolved: usb: typec: ucsi: Retrieve all the PDOs instead of just the first 4 commit 4dbc6a4ef06d ("usb: typec: ucsi: save power data objects in PD mode") introduced retrieval of the PDOs when connected to a PD-capable source. But only the first 4 PDOs are received since that is the maximum number that can be fetched at a time given the MESSAGE_IN length limitation (16 bytes). However, as per the PD spec a connected source may advertise up to a maximum of 7 PDOs. If such a source is connected it's possible the PPM could have negotiated a power contract with one of the PDOs at index greater than 4, and would be reflected in the request data object's (RDO) object position field. This would result in an out-of-bounds access when the rdo_index() is used to index into the src_pdos array in ucsi_psy_get_voltage_now(). With the help of the UBSAN -fsanitize=array-bounds checker enabled this exact issue is revealed when connecting to a PD source adapter that advertise 5 PDOs and the PPM enters a contract having selected the 5th one. [ 151.545106][ T70] Unexpected kernel BRK exception at EL1 [ 151.545112][ T70] Internal error: BRK handler: f2005512 [#1] PREEMPT SMP ... [ 151.545499][ T70] pc : ucsi_psy_get_prop+0x208/0x20c [ 151.545507][ T70] lr : power_supply_show_property+0xc0/0x328 ... [ 151.545542][ T70] Call trace: [ 151.545544][ T70] ucsi_psy_get_prop+0x208/0x20c [ 151.545546][ T70] power_supply_uevent+0x1a4/0x2f0 [ 151.545550][ T70] dev_uevent+0x200/0x384 [ 151.545555][ T70] kobject_uevent_env+0x1d4/0x7e8 [ 151.545557][ T70] power_supply_changed_work+0x174/0x31c [ 151.545562][ T70] process_one_work+0x244/0x6f0 [ 151.545564][ T70] worker_thread+0x3e0/0xa64 We can resolve this by instead retrieving and storing up to the maximum of 7 PDOs in the con->src_pdos array. This would involve two calls to the GET_PDOS command.

INFO

Published Date :

Feb. 28, 2024, 9:15 a.m.

Last Modified :

Dec. 31, 2024, 4:06 p.m.

Source :

416baaa9-dc9f-4396-8d5f-8c081fb06d67

Remotely Exploitable :

No

Impact Score :

5.2

Exploitability Score :

1.8
Affected Products

The following products are affected by CVE-2021-46980 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Linux linux_kernel

We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).

Results are limited to the first 15 repositories due to potential performance issues.

The following list is the news that have been mention CVE-2021-46980 vulnerability anywhere in the article.

The following table lists the changes that have been made to the CVE-2021-46980 vulnerability over time.

Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.

  • Initial Analysis by [email protected]

    Dec. 31, 2024

    Action Type Old Value New Value
    Added CVSS V3.1 NIST AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H
    Added CWE NIST CWE-125
    Added CPE Configuration OR *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.8 up to (excluding) 5.10.38 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.11 up to (excluding) 5.11.22 *cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* versions from (including) 5.12 up to (excluding) 5.12.5 *cpe:2.3:o:linux:linux_kernel:5.13:rc1:*:*:*:*:*:*
    Changed Reference Type https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc No Types Assigned https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc Patch
    Changed Reference Type https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc No Types Assigned https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc Patch
    Changed Reference Type https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57 No Types Assigned https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57 Patch
    Changed Reference Type https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57 No Types Assigned https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57 Patch
    Changed Reference Type https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911 No Types Assigned https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911 Patch
    Changed Reference Type https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911 No Types Assigned https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911 Patch
    Changed Reference Type https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d No Types Assigned https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d Patch
    Changed Reference Type https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d No Types Assigned https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d Patch
  • CVE Modified by af854a3a-2127-422b-91ae-364da2661108

    Nov. 21, 2024

    Action Type Old Value New Value
    Added Reference https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc
    Added Reference https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57
    Added Reference https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911
    Added Reference https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    May. 28, 2024

    Action Type Old Value New Value
  • CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    May. 14, 2024

    Action Type Old Value New Value
  • CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67

    Feb. 28, 2024

    Action Type Old Value New Value
    Added Description In the Linux kernel, the following vulnerability has been resolved: usb: typec: ucsi: Retrieve all the PDOs instead of just the first 4 commit 4dbc6a4ef06d ("usb: typec: ucsi: save power data objects in PD mode") introduced retrieval of the PDOs when connected to a PD-capable source. But only the first 4 PDOs are received since that is the maximum number that can be fetched at a time given the MESSAGE_IN length limitation (16 bytes). However, as per the PD spec a connected source may advertise up to a maximum of 7 PDOs. If such a source is connected it's possible the PPM could have negotiated a power contract with one of the PDOs at index greater than 4, and would be reflected in the request data object's (RDO) object position field. This would result in an out-of-bounds access when the rdo_index() is used to index into the src_pdos array in ucsi_psy_get_voltage_now(). With the help of the UBSAN -fsanitize=array-bounds checker enabled this exact issue is revealed when connecting to a PD source adapter that advertise 5 PDOs and the PPM enters a contract having selected the 5th one. [ 151.545106][ T70] Unexpected kernel BRK exception at EL1 [ 151.545112][ T70] Internal error: BRK handler: f2005512 [#1] PREEMPT SMP ... [ 151.545499][ T70] pc : ucsi_psy_get_prop+0x208/0x20c [ 151.545507][ T70] lr : power_supply_show_property+0xc0/0x328 ... [ 151.545542][ T70] Call trace: [ 151.545544][ T70] ucsi_psy_get_prop+0x208/0x20c [ 151.545546][ T70] power_supply_uevent+0x1a4/0x2f0 [ 151.545550][ T70] dev_uevent+0x200/0x384 [ 151.545555][ T70] kobject_uevent_env+0x1d4/0x7e8 [ 151.545557][ T70] power_supply_changed_work+0x174/0x31c [ 151.545562][ T70] process_one_work+0x244/0x6f0 [ 151.545564][ T70] worker_thread+0x3e0/0xa64 We can resolve this by instead retrieving and storing up to the maximum of 7 PDOs in the con->src_pdos array. This would involve two calls to the GET_PDOS command.
    Added Reference Linux https://git.kernel.org/stable/c/e5366bea0277425e1868ba20eeb27c879d5a6e2d [No types assigned]
    Added Reference Linux https://git.kernel.org/stable/c/a453bfd7ef15fd9d524004d3ca7b05353a302911 [No types assigned]
    Added Reference Linux https://git.kernel.org/stable/c/5e9c6f58b01e6fdfbc740390c01f542a35c97e57 [No types assigned]
    Added Reference Linux https://git.kernel.org/stable/c/1f4642b72be79757f050924a9b9673b6a02034bc [No types assigned]
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.
CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2021-46980 is associated with the following CWEs:

Common Attack Pattern Enumeration and Classification (CAPEC)

Common Attack Pattern Enumeration and Classification (CAPEC) stores attack patterns, which are descriptions of the common attributes and approaches employed by adversaries to exploit the CVE-2021-46980 weaknesses.

CVSS31 - Vulnerability Scoring System
Attack Vector
Attack Complexity
Privileges Required
User Interaction
Scope
Confidentiality
Integrity
Availability
© cvefeed.io
Latest DB Update: Jul. 14, 2025 8:22