Advisory Database
  • Advisories
  • Dependency Scanning
  1. nuget
  2. ›
  3. NCalc.Core
  4. ›
  5. CVE-2026-55254

CVE-2026-55254: NCalc: Denial of Service via Unbounded and Non-Terminating Factorial Evaluation

June 18, 2026

A denial-of-service (DoS) vulnerability exists in the factorial operator implementation of NCalc. Specially crafted expressions containing extremely large factorial operands can trigger excessive CPU consumption or cause evaluation to enter a non-terminating loop due to integer overflow in the factorial calculation logic.

Applications that evaluate untrusted expressions using affected versions of NCalc may be vulnerable to resource exhaustion, potentially resulting in service disruption or application unresponsiveness.

This issue can be triggered with expressions such as:

99999999999999!
9223372036854775807!
1.5e16!

References

  • github.com/advisories/GHSA-3w5p-95mh-gq75
  • github.com/ncalc/ncalc/pull/575
  • github.com/ncalc/ncalc/security/advisories/GHSA-3w5p-95mh-gq75
  • nvd.nist.gov/vuln/detail/CVE-2026-55254

Code Behaviors & Features

Detect and mitigate CVE-2026-55254 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 6.1.1

Fixed versions

  • 6.1.1

Solution

Upgrade to version 6.1.1 or above.

Impact 4.8 MEDIUM

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

Learn more about CVSS

Weakness

  • CWE-190: Integer Overflow or Wraparound
  • CWE-770: Allocation of Resources Without Limits or Throttling

Source file

nuget/NCalc.Core/CVE-2026-55254.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Tue, 23 Jun 2026 12:23:00 +0000.