CVE-2021-47641:An integer divide-by-zero vulnerability in the Linux kernel's Cirrus framebuffer driver (cirrusfb) can occur when pixclock is zero, potentially causing a kernel fault; it has been fixed by adding a pixclock sanity check (cirrusfb_check_pixclock). The fix is included in kernel 5.18 and newer.

splash
Back

Description Preview

This CVE covers a defect in the Linux kernel’s Cirrus fbdev driver (drivers/video/fbdev/cirrusfb.c) where a zero pixclock value could lead to a divide-by-zero in the function cirrusfb_check_pixclock during framebuffer configuration. Syzkaller reported a divide error in cirrusfb_check_pixclock, which could result in a kernel fault or instability when manipulating framebuffer settings via ioctl calls. The vulnerability has been resolved by introducing a sanity check on pixclock to prevent division by zero. Affected versions include older Linux kernels prior to the fix; the patch is present in kernel 5.18 and later. To mitigate, upgrade to a fixed kernel or apply the corresponding backported patch for your distribution.

Overview

The issue is a divide-by-zero in the Cirrus framebuffer driver within the Linux kernel, triggered when pixclock is zero during frequency derivation. This was identified by Syzkaller and mitigated by adding a check to ensure pixclock is valid before performing divisions in cirrusfb_check_pixclock. The fix is incorporated in the 5.18 kernel line and later; kernels prior to this release are susceptible. Upgrading to a patched kernel or applying the equivalent patch to the cirrusfb driver is the recommended mitigation.

Remediation

  • Upgrade your Linux kernel to a version containing the fix (5.18 or newer) or apply the equivalent backported patch to the cirrusfb driver for your distribution.
  • If upgrading is not feasible, patch and backport the fix to your current kernel tree:
    • Implement a pixclock validation check in cirrusfb_check_pixclock to handle zero or invalid values before performing the division.
    • Rebuild and install the updated kernel and reboot.
  • If you do not use the Cirrus framebuffer driver, consider unloading or blacklisting the cirrusfb module to reduce exposure.
  • Validate the update with your normal kernel and framebuffer configuration workflows and monitor for any related issues after reboot.

References

  • https://git.kernel.org/stable/c/c656d04247a2654ede5cead2ecbf83431dad5261
  • https://git.kernel.org/stable/c/1d3fb46439ad4e8f0c5739eb33d1875ac9e0f135
  • https://git.kernel.org/stable/c/40b13e3d85744210db13457785646634e2d056bd
  • https://git.kernel.org/stable/c/53a2088a396cfa1da92690a1da289634cd73bf0d
  • https://git.kernel.org/stable/c/8c7e2141fb89c620ab4e41512e262fbf25b8260d
  • https://git.kernel.org/stable/c/6fe23ff94e7840097202e85c148688940b37c9b1
  • https://git.kernel.org/stable/c/45800c42ef000f417270bcfc08630e42486fca99
  • https://git.kernel.org/stable/c/e498b504f8c81b07efab9febf8503448de4dc9cf
  • https://git.kernel.org/stable/c/5c6f402bdcf9e7239c6bc7087eda71ac99b31379

Industry ExposureMost to least
This section illustrates the prevalence of a specific Common Vulnerabilities and Exposures (CVE) across various industries based on customer reports. The ranking displays industries from the most to least affected by this particular vulnerability, offering valuable insight into where this CVE has been most frequently observed. This information can help organizations within these sectors prioritize their security efforts, understand their relative risk exposure compared to their peers, and focus remediation strategies where they are most needed. By understanding the industry-specific impact, organizations can make more informed decisions regarding patching, resource allocation, and overall risk management related to this CVE.

  1. Manufacturing: Medium
    Manufacturing
  2. Health Care & Social Assistance: Low
    Health Care & Social Assistance
  3. Finance and Insurance: Low
    Finance and Insurance
  4. Arts, Entertainment & Recreation: Low
    Arts, Entertainment & Recreation
  5. Educational Services: Low
    Educational Services
  6. Management of Companies & Enterprises: Low
    Management of Companies & Enterprises
  7. Professional, Scientific, & Technical Services: Low
    Professional, Scientific, & Technical Services
  8. Other Services (except Public Administration): Low
    Other Services (except Public Administration)
  9. Retail Trade: Low
    Retail Trade
  10. Public Administration: Low
    Public Administration
  11. Transportation & Warehousing: Low
    Transportation & Warehousing
  12. Utilities: Low
    Utilities
  13. Accommodation & Food Services: Low
    Accommodation & Food Services
  14. Administrative, Support, Waste Management & Remediation Services: Low
    Administrative, Support, Waste Management & Remediation Services
  15. Agriculture, Forestry Fishing & Hunting: Low
    Agriculture, Forestry Fishing & Hunting
  16. Construction: Low
    Construction
  17. Information: Low
    Information
  18. Mining: Low
    Mining
  19. Real Estate Rental & Leasing: Low
    Real Estate Rental & Leasing
  20. Wholesale Trade: Low
    Wholesale Trade

Focus on What Matters

  1. See Everything.
  2. Identify True Risk.
  3. Proactively Mitigate Threats.

Let's talk!

background