Advisory Database
  • Advisories
  • Dependency Scanning
  1. cargo
  2. ›
  3. soroban-sdk
  4. ›
  5. CVE-2026-24889

CVE-2026-24889: soroban-sdk has overflow in Bytes::slice, Vec::slice, GenRange::gen_range for u64

January 28, 2026 (updated January 29, 2026)

Arithmetic overflow can be triggered in the Bytes::slice, Vec::slice, and Prng::gen_range (for u64) methods in the soroban-sdk in versions prior to and including 25.0.1.

Contracts that pass user-controlled or computed range bounds to Bytes::slice, Vec::slice, or Prng::gen_range may silently operate on incorrect data ranges or generate random numbers from an unintended range, potentially resulting in corrupted contract state.

Note that the best practice when using the soroban-sdk and building Soroban contracts is to always enable overflow-checks = true. The stellar contract init tool that prepares the boiler plate for a Soroban contract, as well as all examples and docs, encourage the use of configuring overflow-checks = true on release profiles so that these arithmetic operations fail rather than silently wrap. Contracts are only impacted if they use overflow-checks = false either explicitly or implicitly. It is anticipated the majority of contracts could not be impacted because the best practice encouraged by tooling is to enable overflow-checks.

References

  • github.com/advisories/GHSA-96xm-fv9w-pf3f
  • github.com/stellar/rs-soroban-sdk
  • github.com/stellar/rs-soroban-sdk/commit/3890521426d71bb4d892b21f5a283a1e836cfa38
  • github.com/stellar/rs-soroban-sdk/commit/59fcef437260ed4da42d1efb357137a5c166c02e
  • github.com/stellar/rs-soroban-sdk/commit/c2757c6d774dbb28b34a0b77ffe282e59f0f8462
  • github.com/stellar/rs-soroban-sdk/pull/1703
  • github.com/stellar/rs-soroban-sdk/releases/tag/v22.0.9
  • github.com/stellar/rs-soroban-sdk/releases/tag/v23.5.1
  • github.com/stellar/rs-soroban-sdk/releases/tag/v25.0.2
  • github.com/stellar/rs-soroban-sdk/security/advisories/GHSA-96xm-fv9w-pf3f
  • nvd.nist.gov/vuln/detail/CVE-2026-24889

Code Behaviors & Features

Detect and mitigate CVE-2026-24889 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 22.0.9, all versions starting from 23.0.0 before 23.5.1, all versions starting from 25.0.0 before 25.0.2

Fixed versions

  • 25.0.2
  • 23.5.1
  • 22.0.9

Solution

Upgrade to versions 22.0.9, 23.5.1, 25.0.2 or above.

Impact 5.3 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-190: Integer Overflow or Wraparound

Source file

cargo/soroban-sdk/CVE-2026-24889.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 04 Feb 2026 00:35:14 +0000.