Ghc: Subword division operations may produce incorrect results
Affects ghcSource GCVE Database
Rated High by Threat Radar's AI analysis
- Patch
- Available – fixed in 9.12.4, 9.12.2
Data as of 13 Nov 2026, 18:41 UTC
What to do
Upgrade ghc to 9.12.4 or 9.12.2.
Patches and advisories
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| GHCghc | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Apply the official patches by upgrading to GHC versions 9.12.2 or 9.12.4, which contain fixes for this vulnerability. Since patches are available, remediation should be performed promptly to prevent potential exploitation.
Description
A vulnerability in GHC affects subword division operations, causing arithmetic operations to produce incorrect results when compiled with optimizations. This primarily leads to availability and data integrity issues, but in some cases, it may cause more severe security flaws such as buffer overflow conditions. Fixed versions 9.12.2 and 9.12.4 address this issue.
References
- gitlab.haskell.org/ghc/ghc/-/issues/25653 (opens in a new tab)
- discourse.haskell.org/t/psa-correctness-issue-in-ghc-9-12/11204 (opens in a new tab)
- discourse.haskell.org/t/critical-code-generation-bug-with-ghc-9-12-3/13505/2 (opens in a new tab)
- gitlab.haskell.org/ghc/ghc/-/merge_requests/13820 (opens in a new tab)
- gitlab.haskell.org/ghc/ghc/-/issues/26711 (opens in a new tab)
- gitlab.haskell.org/ghc/ghc/-/issues/26668 (opens in a new tab)