{
  "schema_version": "1.6.1",
  "id": "RPI-CVE-2024-49924",
  "modified": "2026-10-09T11:39:44Z",
  "upstream": [
    "CVE-2024-49924"
  ],
  "published": "2024-10-21T18:02:47Z",
  "summary": "fbdev: pxafb: Fix possible use after free in pxafb_task()",
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\nfbdev: pxafb: Fix possible use after free in pxafb_task()\n\nIn the pxafb_probe function, it calls the pxafb_init_fbinfo function,\nafter which &fbi->task is associated with pxafb_task. Moreover,\nwithin this pxafb_init_fbinfo function, the pxafb_blank function\nwithin the &pxafb_ops struct is capable of scheduling work.\n\nIf we remove the module which will call pxafb_remove to make cleanup,\nit will call unregister_framebuffer function which can call\ndo_unregister_framebuffer to free fbi->fb through\nput_fb_info(fb_info), while the work mentioned above will be used.\nThe sequence of operations that may lead to a UAF bug is as follows:\n\nCPU0                                                CPU1\n\n                                   | pxafb_task\npxafb_remove                       |\nunregister_framebuffer(info)       |\ndo_unregister_framebuffer(fb_info) |\nput_fb_info(fb_info)               |\n// free fbi->fb                    | set_ctrlr_state(fbi, state)\n                                   | __pxafb_lcd_power(fbi, 0)\n                                   | fbi->lcd_power(on, &fbi->fb.var)\n                                   | //use fbi->fb\n\nFix it by ensuring that the work is canceled before proceeding\nwith the cleanup in pxafb_remove.\n\nNote that only root user can remove the driver at runtime.",
  "severity": [
    {
      "type": "CVSS_V3",
      "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
    }
  ],
  "affected": [
    {
      "package": {
        "ecosystem": "Raspberry Pi OS:12",
        "name": "linux"
      },
      "versions": [
        "1:6.1.47-1+rpt4"
      ],
      "ecosystem_specific": {
        "binaries": [
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-2712",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v6",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v7",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v7l",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v8",
            "binary_version": "1:6.1.47-1+rpt4"
          }
        ]
      },
      "database_specific": {
        "per_version": {
          "1:6.1.47-1+rpt4": {
            "linux_commit": "655fc658a15ae7a6f37103754adb39ba52a9a14e",
            "upstream_version": "6.1.47",
            "assessment": "commit ancestry (strak rule)",
            "upstream_fixed": "6.1.113",
            "compiled_filter": false
          }
        }
      }
    }
  ],
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://www.cve.org/CVERecord?id=CVE-2024-49924"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/e657fa2df4429f3805a9b3e47fb1a4a1b02a72bd"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/6d0a07f68b66269e167def6c0b90a219cd3e7473"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/e6897e299f57b103e999e62010b88e363b3eebae"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/4cda484e584be34d55ee17436ebf7ad11922b97a"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/3c0d416eb4bef705f699213cee94bf54b6acdacd"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/fdda354f60a576d52dcf90351254714681df4370"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/aaadc0cb05c999ccd8898a03298b7e5c31509b08"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/a3a855764dbacbdb1cc51e15dc588f2d21c93e0e"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/4a6921095eb04a900e0000da83d9475eb958e61e"
    }
  ],
  "database_specific": {
    "source": "https://git.kernel.org/pub/scm/linux/security/vulns.git",
    "upstream_modified": "2026-08-05T11:52:36Z",
    "severity": {
      "source": "kernel CNA",
      "cvss_v3_score": 7.8,
      "cvss_v3_severity": "High",
      "scenario": "AV:L - The vulnerability is reached entirely through local interfaces \u2014 `FBIOBLANK`/`FBIOPUT_VSCREENINFO` ioctls on `/dev/fbN` to queue `fbi->task`, and platform driver unbind/`rmmod` to free the devm-allocated `pxafb_info`. No network or physical device manipulation is involved.\nAC:L - The attacker deterministically arms the race by repeatedly queueing `pxafb_task` via `FBIOBLANK`, and the racing work sleeps up to 200 ms in `wait_for_completion_timeout(&fbi->disable_done, ...)` inside `pxafb_disable_controller()`, giving an enormous, reliably winnable window. No error path, unusual memory layout, or non-default configuration is required \u2014 `CONFIG_FB_PXA` is standard and tristate on every PXA platform.\nPR:L - An ordinary unprivileged user needs only DAC access to `/dev/fb0` \u2014 which requires no capability and is routinely granted on the embedded PXA handhelds and panel devices this driver targets \u2014 to queue the work and groom the slab that backs the freed `pxafb_info`. This matches this CNA's established treatment of driver-teardown UAFs (e.g. CVE-2025-21976, hyperv_fb), where `PR:H` is reserved for cases that cross a VM/container security boundary.\nUI:N - No victim action such as opening a file or mounting a filesystem is needed; the pending work is also queued automatically by the fbcon console-blank timer and by `pxafb_set_par()`, so the race can be live without any interactive user.\nS:U - The corrupted memory and the resulting code execution are both in the host kernel's own security authority, with no VM, IOMMU, or sandbox boundary crossed.\nC:H - The use-after-free lets the attacker control the contents of the reallocated `pxafb_info`, including `fbi->mmio_base`, which `lcd_readl()` dereferences \u2014 yielding an attacker-directed read primitive that, combined with the hijacked control flow, permits disclosure of arbitrary kernel memory.\nI:H - `__pxafb_lcd_power()` and `__pxafb_backlight_power()` call `fbi->lcd_power()` / `fbi->backlight_power()` \u2014 function pointers read straight out of the freed allocation \u2014 and `lcd_writel()` performs `__raw_writel()` to an address taken from the same freed object, giving both control-flow hijack and an arbitrary write.\nA:H - Even without successful exploitation the UAF reliably oopses the kernel \u2014 dereferencing a freed `mmio_base`, locking a freed mutex, or on `rmmod` executing `pxafb_task` text that has already been unmapped with the module."
    }
  }
}
