CVE-2026-97604: fbdev: vfb: defer cleanup until the last reference

Published Sep 25, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

fbdev: vfb: defer cleanup until the last reference

FBIOGETCMAP takes a shallow snapshot of info->cmap and performs the usercopy after dropping info->lock. vfbremove() frees the colormap immediately after unregistering the framebuffer, even when an open file still holds a reference to fbinfo. A concurrent driver unbind can therefore free the colormap while the ioctl copies it to userspace.

KASAN reports:

BUG: KASAN: slab-use-after-free in copytouser Read of size 512 by task poc/125

copytouser (./include/linux/instrumented.h:129 ./include/linux/uaccess.h:201 lib/usercopy.c:24) fbcmaptouser (./include/linux/uaccess.h:230 drivers/video/fbdev/core/fbcmap.c:211) dofbioctl (drivers/video/fbdev/core/fbchrdev.c:114)

Allocated by task 1: fballoccmapgfp (./include/linux/slab.h:973 ./include/linux/slab.h:1290 drivers/video/fbdev/core/fbcmap.c:108) vfbprobe (drivers/video/fbdev/vfb.c:459)

Freed by task 124: fbdealloccmap (drivers/video/fbdev/core/fbcmap.c:151) vfbremove (drivers/video/fbdev/vfb.c:489)

unregisterframebuffer() drops the registration reference, and fbdev calls fbdestroy after the last putfbinfo(). Move the registered framebuffer's cleanup into an fbdestroy callback so its colormap and screen buffer stay alive until all file references have been released.

Affected Software

1 affected component
Linux Linux kernel

Event History

Sep 25, 2026
CVE Published
via MITRE·10:22 AM
Data Sourced
via MITRE·10:22 AM
Description
Data Sourced
via NVD·11:17 AM
Description

Frequently Asked Questions

1

What conditions are required to trigger the use-after-free?

An open framebuffer file must still hold a reference to fb_info while a user issues FBIOGETCMAP. A concurrent unbind of the vfb driver must then remove the framebuffer and free its colormap after the ioctl takes its snapshot but before its copy to userspace completes.

2

Which systems are exposed?

The affected path is specific to the Linux kernel's virtual framebuffer driver (vfb) and its framebuffer colormap handling. Systems that do not use the vfb driver are not described as reaching this vulnerable remove path.

3

How can administrators reduce exposure before applying the fix?

Avoid unbinding or removing the vfb driver while framebuffer device files may remain open or while FBIOGETCMAP operations are in progress. Coordinating driver removal with closure of framebuffer users prevents the described race condition.

4

How would an affected event appear in diagnostics?

KASAN can report a slab use-after-free in _copy_to_user, with the call path including fb_cmap_to_user and do_fb_ioctl. The allocation is associated with vfb_probe, while the free is associated with vfb_remove and fb_dealloc_cmap.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203