Description
soroban-fixed-point-math is a fixed-point math library for Soroban smart contacts. In versions 1.3.0 and 1.4.0, the `mulDiv(x, y, z)` function incorrectly handled cases where both the intermediate product $x * y$ and the divisor $z$ were negative. The logic assumed that if the intermediate product was negative, the final result must also be negative, neglecting the sign of $z$. This resulted in rounding being applied in the wrong direction for cases where both $x * y$ and $z$ were negative. The functions most at risk are `fixed_div_floor` and `fixed_div_ceil`, as they often use non-constant numbers as the divisor $z$ in `mulDiv`. This error is present in all signed `FixedPoint` and `SorobanFixedPoint` implementations, including `i64`, `i128`, and `I256`. Versions 1.3.1 and 1.4.1 contain a patch. No known workarounds for this issue are available.
Published: 2026-01-27
Score: 7.5 High
EPSS: < 1% Very Low
KEV: No
Impact: Incorrect arithmetic in signed fixed‑point math leading to erroneous calculation results
Action: Apply patch
AI Analysis

Impact

The vulnerability is a flaw in the mulDiv function of a fixed‑point math library used by Soroban smart contracts. When both the intermediate product (x * y) and the divisor (z) are negative, the code incorrectly assumes the final result must be negative and applies rounding in the wrong direction. This causes the fixed_div_floor and fixed_div_ceil functions, which often use dynamic divisors, to produce inaccurate results for negative operands. The bug could lead to financial miscalculation or consensus errors in affected contracts, and its CVSS score of 7.5 reflects a high impact on correctness and potential for financial loss.

Affected Systems

The issue exists in script3’s soroban-fixed-point-math library versions 1.3.0 and 1.4.0, affecting all signed FixedPoint and SorobanFixedPoint types (i64, i128, I256). Updated releases 1.3.1 and 1.4.1 contain the patch and resolve the problem. Any deployment that references the unpatched versions is vulnerable.

Risk and Exploitability

With a CVSS score of 7.5, the vulnerability poses a significant correctness risk, but the EPSS score is below 1%, indicating a low probability of exploitation. The bug is not listed in the CISA KEV catalog. An attacker would need to craft a contract that uses the affected division functions with negative operands to influence calculation results. While no remote code execution or denial‑of‑service effect is possible, the improper rounding could be exploited for financial manipulation or to trigger consensus faults in the network. The attack vector is likely through contract interaction rather than external access, making active exploitation difficult but not impossible in a malicious or buggy context.

Generated by OpenCVE AI on April 18, 2026 at 18:44 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to soroban‑fixed‑point‑math version 1.3.1 or newer (or 1.4.1 or newer) to apply the official patch
  • Add unit tests that exercise mulDiv, fixed_div_floor, and fixed_div_ceil with combinations of negative operands to detect rounding and overflow errors
  • Implement runtime validation to check the signs of the intermediate product and the divisor before performing division, and apply correct rounding logic as defined for signed fixed‑point arithmetic

Generated by OpenCVE AI on April 18, 2026 at 18:44 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-x5m4-43jf-hh65 soroban-fixed-point-math has Incorrect Rounding and Overflow Handling in Signed Fixed-Point Math with Negatives
History

Mon, 02 Mar 2026 21:30:00 +0000

Type Values Removed Values Added
CPEs cpe:2.3:a:script3:soroban-fixed-point-math:1.3.0:*:*:*:*:rust:*:*
cpe:2.3:a:script3:soroban-fixed-point-math:1.4.0:*:*:*:*:rust:*:*

Wed, 28 Jan 2026 21:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Wed, 28 Jan 2026 12:30:00 +0000

Type Values Removed Values Added
First Time appeared Script3
Script3 soroban-fixed-point-math
Vendors & Products Script3
Script3 soroban-fixed-point-math

Tue, 27 Jan 2026 22:15:00 +0000

Type Values Removed Values Added
Description soroban-fixed-point-math is a fixed-point math library for Soroban smart contacts. In versions 1.3.0 and 1.4.0, the `mulDiv(x, y, z)` function incorrectly handled cases where both the intermediate product $x * y$ and the divisor $z$ were negative. The logic assumed that if the intermediate product was negative, the final result must also be negative, neglecting the sign of $z$. This resulted in rounding being applied in the wrong direction for cases where both $x * y$ and $z$ were negative. The functions most at risk are `fixed_div_floor` and `fixed_div_ceil`, as they often use non-constant numbers as the divisor $z$ in `mulDiv`. This error is present in all signed `FixedPoint` and `SorobanFixedPoint` implementations, including `i64`, `i128`, and `I256`. Versions 1.3.1 and 1.4.1 contain a patch. No known workarounds for this issue are available.
Title soroban-fixed-point-math has Incorrect Rounding and Overflow Handling in Signed Fixed-Point Math with Negatives
Weaknesses CWE-682
References
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N'}


Subscriptions

Script3 Soroban-fixed-point-math
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-01-28T21:09:12.428Z

Reserved: 2026-01-26T21:06:47.869Z

Link: CVE-2026-24783

cve-icon Vulnrichment

Updated: 2026-01-28T21:09:08.630Z

cve-icon NVD

Status : Analyzed

Published: 2026-01-27T22:15:57.433

Modified: 2026-03-02T21:16:22.370

Link: CVE-2026-24783

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-04-18T18:45:05Z

Weaknesses