Files
vuln-cve/data/2026/98xxx/CVE-2026-98764.json
T

248 lines
13 KiB
JSON

{
"dataType": "CVE_RECORD",
"dataVersion": "5.2",
"cveMetadata": {
"cveId": "CVE-2026-98764",
"assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"state": "PUBLISHED",
"assignerShortName": "Linux",
"dateReserved": "2026-09-25T10:25:14.368Z",
"datePublished": "2026-10-18T15:47:56.225Z",
"dateUpdated": "2026-10-30T12:39:33.311Z"
},
"containers": {
"cna": {
"providerMetadata": {
"orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"shortName": "Linux",
"dateUpdated": "2026-10-30T12:39:33.311Z"
},
"descriptions": [
{
"lang": "en",
"value": "In the Linux kernel, the following vulnerability has been resolved:\n\nusb: gadget: f_fs: Fix NULL pointer dereference in FUNCTIONFS_ENDPOINT_DESC\n\nWhen user space sets up FunctionFS with only full-speed descriptors\n(e.g., flags = FUNCTIONFS_HAS_FS_DESC) and the gadget operates at a\nhigher speed (such as USB_SPEED_HIGH or USB_SPEED_SUPER),\nconfig_ep_by_speed() detects that the function lacks descriptors for\nthe current speed, logs a warning, and falls back to full-speed\ndescriptors. The endpoint is then successfully enabled via\nusb_ep_enable(), and epfile->ep becomes valid.\n\nHowever, when user space subsequently issues the FUNCTIONFS_ENDPOINT_DESC\nioctl to query the endpoint descriptor, ffs_epfile_ioctl() selects the\ndescriptor index solely based on gadget->speed:\n\n\tswitch (epfile->ffs->gadget->speed) {\n\tcase USB_SPEED_SUPER:\n\tcase USB_SPEED_SUPER_PLUS:\n\t\tdesc_idx = 2;\n\t\tbreak;\n\tcase USB_SPEED_HIGH:\n\t\tdesc_idx = 1;\n\t\tbreak;\n\tdefault:\n\t\tdesc_idx = 0;\n\t}\n\tdesc = epfile->ep->descs[desc_idx];\n\tmemcpy(&desc1, desc, desc->bLength);\n\nBecause user space only supplied full-speed descriptors,\nepfile->ep->descs[1] is NULL. Dereferencing desc->bLength triggers an\nimmediate kernel NULL pointer dereference panic.\n\nFix this by falling back through lower speed descriptors if the current\nspeed descriptor was not supplied, matching the fallback logic in\nconfig_ep_by_speed() and historical f_fs behavior. If still missing,\nfall back to epfile->ep->ep->desc (the active descriptor), and return\n-EINVAL safely if no valid descriptor is found. In addition, mark desc\nas const to match struct usb_ep::desc and avoid discarding qualifiers."
}
],
"affected": [
{
"product": "Linux",
"vendor": "Linux",
"defaultStatus": "unaffected",
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"programFiles": [
"drivers/usb/gadget/function/f_fs.c"
],
"versions": [
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "c5f452e057df6ef89300523d13ad6833bfd199cd",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "e5b9d6bb2a8906a1188c9a90cc8d102de3f07cad",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "7ef0ad5f462fa95bc4c6647d097d7c0384245b9c",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "06ac8609d6d185ac18c1d6a6a8a9b99e398bd124",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "9d8761b3c133f6c6a6d3486839dac60e2cf4bfe3",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "7811d8e26c77f8eea79e22d0d14c67ec0658b348",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "35ab269602e1f7c4c0fe6ea3477264bea77eced3",
"status": "affected",
"versionType": "git"
},
{
"version": "c559a353410939c0884e83bdb0e2420a986ac53b",
"lessThan": "9cd072788c76595529eb38f42bf94d23852f8534",
"status": "affected",
"versionType": "git"
}
]
},
{
"product": "Linux",
"vendor": "Linux",
"defaultStatus": "affected",
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"programFiles": [
"drivers/usb/gadget/function/f_fs.c"
],
"versions": [
{
"version": "3.18",
"status": "affected"
},
{
"version": "0",
"lessThan": "3.18",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "5.10.273",
"lessThanOrEqual": "5.10.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "5.15.224",
"lessThanOrEqual": "5.15.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "6.1.191",
"lessThanOrEqual": "6.1.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "6.6.160",
"lessThanOrEqual": "6.6.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "6.12.113",
"lessThanOrEqual": "6.12.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "6.18.56",
"lessThanOrEqual": "6.18.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "7.2.10",
"lessThanOrEqual": "7.2.*",
"status": "unaffected",
"versionType": "semver"
},
{
"version": "7.3",
"lessThanOrEqual": "*",
"status": "unaffected",
"versionType": "original_commit_for_fix"
}
]
}
],
"cpeApplicability": [
{
"nodes": [
{
"operator": "OR",
"negate": false,
"cpeMatch": [
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "5.10.273"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "5.15.224"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "6.1.191"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "6.6.160"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "6.12.113"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "6.18.56"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "7.2.10"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "3.18",
"versionEndExcluding": "7.3"
}
]
}
]
}
],
"references": [
{
"url": "https://git.kernel.org/stable/c/c5f452e057df6ef89300523d13ad6833bfd199cd"
},
{
"url": "https://git.kernel.org/stable/c/e5b9d6bb2a8906a1188c9a90cc8d102de3f07cad"
},
{
"url": "https://git.kernel.org/stable/c/7ef0ad5f462fa95bc4c6647d097d7c0384245b9c"
},
{
"url": "https://git.kernel.org/stable/c/06ac8609d6d185ac18c1d6a6a8a9b99e398bd124"
},
{
"url": "https://git.kernel.org/stable/c/9d8761b3c133f6c6a6d3486839dac60e2cf4bfe3"
},
{
"url": "https://git.kernel.org/stable/c/7811d8e26c77f8eea79e22d0d14c67ec0658b348"
},
{
"url": "https://git.kernel.org/stable/c/35ab269602e1f7c4c0fe6ea3477264bea77eced3"
},
{
"url": "https://git.kernel.org/stable/c/9cd072788c76595529eb38f42bf94d23852f8534"
}
],
"title": "usb: gadget: f_fs: Fix NULL pointer dereference in FUNCTIONFS_ENDPOINT_DESC",
"x_generator": {
"engine": "bippy-1.2.0"
}
}
}
}