{"id":"CVE-2026-31490","state":"PUBLISHED","title":"drm/xe/pf: Fix use-after-free in migration restore","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/xe/pf: Fix use-after-free in migration restore\n\nWhen an error is returned from xe_sriov_pf_migration_restore_produce(),\nthe data pointer is not set to NULL, which can trigger use-after-free\nin subsequent .write() calls.\nSet the pointer to NULL upon error to fix the problem.\n\n(cherry picked from commit 4f53d8c6d23527d734fe3531d08e15cb170a0819)","publishedAt":"2026-04-22T13:54:14.241Z","updatedAt":"2026-08-05T12:23:02.564Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"1ed30397c0b92b97381dbd11362fdbbf93e046d2","status":"affected","lessThan":"e28552b4ddea5cb4725380dd08237831af835124","versionType":"git"},{"version":"1ed30397c0b92b97381dbd11362fdbbf93e046d2","status":"affected","lessThan":"87997b6c6516e049cbaf2fc6810b213d587a06b1","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_sriov_packet.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.19","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.19","versionType":"semver"},{"version":"6.19.11","status":"unaffected","lessThanOrEqual":"6.19.*","versionType":"semver"},{"version":"7.0","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_sriov_packet.c"]}],"references":["https://git.kernel.org/stable/c/e28552b4ddea5cb4725380dd08237831af835124","https://git.kernel.org/stable/c/87997b6c6516e049cbaf2fc6810b213d587a06b1"],"weaknesses":[],"ingestedAt":"2026-10-29T20:11:40.391Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/31xxx/CVE-2026-31490.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-31490","state":"PUBLISHED","datePublished":"2026-04-22T13:54:14.241Z","dateUpdated":"2026-08-05T12:23:02.564Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-03-09T15:48:24.102Z"},"containers":{"cna":{"title":"drm/xe/pf: Fix use-after-free in migration restore","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/xe/pf: Fix use-after-free in migration restore\n\nWhen an error is returned from xe_sriov_pf_migration_restore_produce(),\nthe data pointer is not set to NULL, which can trigger use-after-free\nin subsequent .write() calls.\nSet the pointer to NULL upon error to fix the problem.\n\n(cherry picked from commit 4f53d8c6d23527d734fe3531d08e15cb170a0819)"}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"1ed30397c0b92b97381dbd11362fdbbf93e046d2","status":"affected","lessThan":"e28552b4ddea5cb4725380dd08237831af835124","versionType":"git"},{"version":"1ed30397c0b92b97381dbd11362fdbbf93e046d2","status":"affected","lessThan":"87997b6c6516e049cbaf2fc6810b213d587a06b1","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_sriov_packet.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.19","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.19","versionType":"semver"},{"version":"6.19.11","status":"unaffected","lessThanOrEqual":"6.19.*","versionType":"semver"},{"version":"7.0","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_sriov_packet.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/e28552b4ddea5cb4725380dd08237831af835124"},{"url":"https://git.kernel.org/stable/c/87997b6c6516e049cbaf2fc6810b213d587a06b1"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable restore write path is reached through local kernel interfaces, primarily the Xe VFIO migration resume data fd and also PF debugfs migration_data, not by network packets.\nAC:L - An attacker with access to the migration write interface can deliberately write a malformed complete packet, get an error from restore production, and then issue a subsequent write against the stale pending pointer.\nPR:L - The debugfs path is root-only, but the same helper is exposed through xe-vfio-pci migration to a process with an assigned VFIO device fd, which is commonly delegated to an unprivileged VMM user.\nUI:N - No victim action is needed once the attacker can operate the local VFIO/debugfs migration interface; the attacker directly performs the state transition and writes restore data.\nS:U - The bug corrupts host kernel memory from a host kernel driver path, so the impact remains within the same kernel security authority.\nC:H - This is a kernel use-after-free on a packet object containing attacker-influenced header and buffer pointer state, which can plausibly be shaped into disclosure of kernel memory.\nI:H - The stale packet pointer is reused on later writes, including copy_from_user through fields from freed/reallocated memory, making arbitrary kernel memory corruption defensible.\nA:H - At minimum the dangling pointer can be triggered repeatedly to cause kernel oops, panic, or device/host instability."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T12:23:02.564Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.19","versionEndExcluding":"6.19.11"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.19","versionEndExcluding":"7.0"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}