CVE-2022-50642 (GCVE-0-2022-50642)
Vulnerability from cvelistv5 – Published: 2025-12-09 00:00 – Updated: 2025-12-09 00:00
VLAI?
Title
platform/chrome: cros_ec_typec: zero out stale pointers
Summary
In the Linux kernel, the following vulnerability has been resolved:
platform/chrome: cros_ec_typec: zero out stale pointers
`cros_typec_get_switch_handles` allocates four pointers when obtaining
type-c switch handles. These pointers are all freed if failing to obtain
any of them; therefore, pointers in `port` become stale. The stale
pointers eventually cause use-after-free or double free in later code
paths. Zeroing out all pointer fields after freeing to eliminate these
stale pointers.
Severity ?
No CVSS data available.
Assigner
References
Impacted products
| Vendor | Product | Version | ||
|---|---|---|---|---|
| Linux | Linux |
Affected:
f28adb41dab4a2795fd959750df57adffd2bb0be , < 0ceadb5a3e45f1b81cf54bd496b40a5e50b6bd40
(git)
Affected: f28adb41dab4a2795fd959750df57adffd2bb0be , < b610758bb3e0674644c1255cdafc2f46b7e05ff9 (git) Affected: f28adb41dab4a2795fd959750df57adffd2bb0be , < 6613f36a2fa5c69e528bccba8b3d831f759dad2f (git) Affected: f28adb41dab4a2795fd959750df57adffd2bb0be , < 9a8aadcf0b459c1257b9477fd6402e1d5952ae07 (git) |
||
{
"containers": {
"cna": {
"affected": [
{
"defaultStatus": "unaffected",
"product": "Linux",
"programFiles": [
"drivers/platform/chrome/cros_ec_typec.c"
],
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"versions": [
{
"lessThan": "0ceadb5a3e45f1b81cf54bd496b40a5e50b6bd40",
"status": "affected",
"version": "f28adb41dab4a2795fd959750df57adffd2bb0be",
"versionType": "git"
},
{
"lessThan": "b610758bb3e0674644c1255cdafc2f46b7e05ff9",
"status": "affected",
"version": "f28adb41dab4a2795fd959750df57adffd2bb0be",
"versionType": "git"
},
{
"lessThan": "6613f36a2fa5c69e528bccba8b3d831f759dad2f",
"status": "affected",
"version": "f28adb41dab4a2795fd959750df57adffd2bb0be",
"versionType": "git"
},
{
"lessThan": "9a8aadcf0b459c1257b9477fd6402e1d5952ae07",
"status": "affected",
"version": "f28adb41dab4a2795fd959750df57adffd2bb0be",
"versionType": "git"
}
]
},
{
"defaultStatus": "affected",
"product": "Linux",
"programFiles": [
"drivers/platform/chrome/cros_ec_typec.c"
],
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"versions": [
{
"status": "affected",
"version": "5.9"
},
{
"lessThan": "5.9",
"status": "unaffected",
"version": "0",
"versionType": "semver"
},
{
"lessThanOrEqual": "5.15.*",
"status": "unaffected",
"version": "5.15.86",
"versionType": "semver"
},
{
"lessThanOrEqual": "6.0.*",
"status": "unaffected",
"version": "6.0.16",
"versionType": "semver"
},
{
"lessThanOrEqual": "6.1.*",
"status": "unaffected",
"version": "6.1.2",
"versionType": "semver"
},
{
"lessThanOrEqual": "*",
"status": "unaffected",
"version": "6.2",
"versionType": "original_commit_for_fix"
}
]
}
],
"cpeApplicability": [
{
"nodes": [
{
"cpeMatch": [
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "5.15.86",
"versionStartIncluding": "5.9",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.0.16",
"versionStartIncluding": "5.9",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.1.2",
"versionStartIncluding": "5.9",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.2",
"versionStartIncluding": "5.9",
"vulnerable": true
}
],
"negate": false,
"operator": "OR"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "In the Linux kernel, the following vulnerability has been resolved:\n\nplatform/chrome: cros_ec_typec: zero out stale pointers\n\n`cros_typec_get_switch_handles` allocates four pointers when obtaining\ntype-c switch handles. These pointers are all freed if failing to obtain\nany of them; therefore, pointers in `port` become stale. The stale\npointers eventually cause use-after-free or double free in later code\npaths. Zeroing out all pointer fields after freeing to eliminate these\nstale pointers."
}
],
"providerMetadata": {
"dateUpdated": "2025-12-09T00:00:16.490Z",
"orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"shortName": "Linux"
},
"references": [
{
"url": "https://git.kernel.org/stable/c/0ceadb5a3e45f1b81cf54bd496b40a5e50b6bd40"
},
{
"url": "https://git.kernel.org/stable/c/b610758bb3e0674644c1255cdafc2f46b7e05ff9"
},
{
"url": "https://git.kernel.org/stable/c/6613f36a2fa5c69e528bccba8b3d831f759dad2f"
},
{
"url": "https://git.kernel.org/stable/c/9a8aadcf0b459c1257b9477fd6402e1d5952ae07"
}
],
"title": "platform/chrome: cros_ec_typec: zero out stale pointers",
"x_generator": {
"engine": "bippy-1.2.0"
}
}
},
"cveMetadata": {
"assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"assignerShortName": "Linux",
"cveId": "CVE-2022-50642",
"datePublished": "2025-12-09T00:00:16.490Z",
"dateReserved": "2025-12-08T23:57:43.370Z",
"dateUpdated": "2025-12-09T00:00:16.490Z",
"state": "PUBLISHED"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.2",
"vulnerability-lookup:meta": {
"nvd": "{\"cve\":{\"id\":\"CVE-2022-50642\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-12-09T01:16:46.693\",\"lastModified\":\"2025-12-09T18:37:13.640\",\"vulnStatus\":\"Awaiting Analysis\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nplatform/chrome: cros_ec_typec: zero out stale pointers\\n\\n`cros_typec_get_switch_handles` allocates four pointers when obtaining\\ntype-c switch handles. These pointers are all freed if failing to obtain\\nany of them; therefore, pointers in `port` become stale. The stale\\npointers eventually cause use-after-free or double free in later code\\npaths. Zeroing out all pointer fields after freeing to eliminate these\\nstale pointers.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/0ceadb5a3e45f1b81cf54bd496b40a5e50b6bd40\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/6613f36a2fa5c69e528bccba8b3d831f759dad2f\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/9a8aadcf0b459c1257b9477fd6402e1d5952ae07\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/b610758bb3e0674644c1255cdafc2f46b7e05ff9\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}"
}
}
Loading…
Loading…
Sightings
| Author | Source | Type | Date |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Loading…
Loading…