{"id":"CVE-2025-37887","state":"PUBLISHED","title":"pds_core: handle unsupported PDS_CORE_CMD_FW_CONTROL result","description":"In the Linux kernel, the following vulnerability has been resolved:\n\npds_core: handle unsupported PDS_CORE_CMD_FW_CONTROL result\n\nIf the FW doesn't support the PDS_CORE_CMD_FW_CONTROL command\nthe driver might at the least print garbage and at the worst\ncrash when the user runs the \"devlink dev info\" devlink command.\n\nThis happens because the stack variable fw_list is not 0\ninitialized which results in fw_list.num_fw_slots being a\ngarbage value from the stack.  Then the driver tries to access\nfw_list.fw_names[i] with i >= ARRAY_SIZE and runs off the end\nof the array.\n\nFix this by initializing the fw_list and by not failing\ncompletely if the devcmd fails because other useful information\nis printed via devlink dev info even if the devcmd fails.","publishedAt":"2025-05-09T06:45:49.492Z","updatedAt":"2026-08-05T11:58:04.745Z","severity":{"score":7.1,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"cdd784c96fe2e5edbf0ed9b3e96fe776e8092385","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"6702f5c6b22deaa95bf84f526148174a160a02cb","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"12a4651a80dbe4589a84e26785fbbe1ed4d043b7","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"2567daad69cd1107fc0ec29b1615f110d7cf7385","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/ethernet/amd/pds_core/devlink.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.4","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.4","versionType":"semver"},{"version":"6.6.89","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.26","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.14.5","status":"unaffected","lessThanOrEqual":"6.14.*","versionType":"semver"},{"version":"6.15","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/ethernet/amd/pds_core/devlink.c"]}],"references":["https://git.kernel.org/stable/c/cdd784c96fe2e5edbf0ed9b3e96fe776e8092385","https://git.kernel.org/stable/c/6702f5c6b22deaa95bf84f526148174a160a02cb","https://git.kernel.org/stable/c/12a4651a80dbe4589a84e26785fbbe1ed4d043b7","https://git.kernel.org/stable/c/2567daad69cd1107fc0ec29b1615f110d7cf7385"],"weaknesses":[],"ingestedAt":"2026-10-29T20:09:03.054Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/37xxx/CVE-2025-37887.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-37887","state":"PUBLISHED","datePublished":"2025-05-09T06:45:49.492Z","dateUpdated":"2026-08-05T11:58:04.745Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-04-16T04:51:23.963Z"},"containers":{"cna":{"title":"pds_core: handle unsupported PDS_CORE_CMD_FW_CONTROL result","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\npds_core: handle unsupported PDS_CORE_CMD_FW_CONTROL result\n\nIf the FW doesn't support the PDS_CORE_CMD_FW_CONTROL command\nthe driver might at the least print garbage and at the worst\ncrash when the user runs the \"devlink dev info\" devlink command.\n\nThis happens because the stack variable fw_list is not 0\ninitialized which results in fw_list.num_fw_slots being a\ngarbage value from the stack.  Then the driver tries to access\nfw_list.fw_names[i] with i >= ARRAY_SIZE and runs off the end\nof the array.\n\nFix this by initializing the fw_list and by not failing\ncompletely if the devcmd fails because other useful information\nis printed via devlink dev info even if the devcmd fails."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"cdd784c96fe2e5edbf0ed9b3e96fe776e8092385","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"6702f5c6b22deaa95bf84f526148174a160a02cb","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"12a4651a80dbe4589a84e26785fbbe1ed4d043b7","versionType":"git"},{"version":"45d76f492938cdc27ddadc16e1e75103f4cfbf56","status":"affected","lessThan":"2567daad69cd1107fc0ec29b1615f110d7cf7385","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/ethernet/amd/pds_core/devlink.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.4","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.4","versionType":"semver"},{"version":"6.6.89","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.26","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.14.5","status":"unaffected","lessThanOrEqual":"6.14.*","versionType":"semver"},{"version":"6.15","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/ethernet/amd/pds_core/devlink.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/cdd784c96fe2e5edbf0ed9b3e96fe776e8092385"},{"url":"https://git.kernel.org/stable/c/6702f5c6b22deaa95bf84f526148174a160a02cb"},{"url":"https://git.kernel.org/stable/c/12a4651a80dbe4589a84e26785fbbe1ed4d043b7"},{"url":"https://git.kernel.org/stable/c/2567daad69cd1107fc0ec29b1615f110d7cf7385"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","baseScore":7.1,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable code is reached through the devlink generic-netlink interface (`DEVLINK_CMD_INFO_GET`), which requires a local socket on the host. There is no remote or adjacent-network path to `pdsc_dl_info_get()`.\nAC:L - On an affected system (AMD Pensando DSC whose firmware rejects PDS_CORE_CMD_FW_CONTROL, or any device state producing -EIO) the bug fires deterministically on every `devlink dev info`, and the attacker can repeat it at will to resample stack contents. Nothing about the trigger depends on winning a race or on memory layout the attacker cannot re-roll.\nPR:L - `DEVLINK_CMD_INFO_GET` is registered with only `GENL_CMD_CAP_DO`/`GENL_CMD_CAP_DUMP` and no `GENL_ADMIN_PERM`, and `devlink_nl_pre_doit()` adds no capability check, so an ordinary unprivileged user can issue the query. Only a local unprivileged account in the initial network namespace is needed.\nUI:N - The attacker issues the devlink netlink request directly; no administrator or other user action is required for the path to execute.\nS:U - The uninitialized read, out-of-bounds read, and any resulting crash are all confined to the kernel of the same host. No VM, IOMMU, or sandbox boundary is crossed.\nC:H - Up to 512 bytes of uninitialized kernel stack (and considerably more in the pre-clamp versions, plus the unbounded `strlen()` walk past the struct) are copied into a netlink reply readable by an unprivileged user, potentially disclosing kernel pointers and stack canaries and defeating KASLR/stack-protector. This is an out-of-bounds/uninitialized read that is not bounded to a few bytes.\nI:N - All writes on this path are bounded (`strscpy`, `snprintf`, `memcpy_fromio` of `sizeof(fw_list)`); the defect is purely a read of uninitialized and out-of-bounds memory. No kernel data can be modified through it.\nA:H - The unterminated `char[32]` fields make `nla_put_string()`'s `strlen()` run off the end of the stack frame — and in the unclamped versions the loop reads roughly 10 KB past it — which can touch the VMAP_STACK guard page and oops the kernel; the fix's changelog explicitly says the driver may \"at the worst crash\". An unprivileged user can retry this repeatedly."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T11:58:04.745Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.6.89"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.12.26"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.14.5"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.15"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}