### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
Update NCalc.Core to 6.1.1; NCalcSync to 6.1.1 if you use the affected versions. Test the change in a non-production environment first.
Local check
hol-guard supply-chain scanNCalc: Denial of Service via Unbounded and Non-Terminating Factorial Evaluation affects NCalc.Core (nuget), NCalcSync (nuget). Severity is medium. ### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
AI coding agents often install or upgrade packages automatically in nuget. A medium vulnerability in a dependency can be pulled into a project through a normal install or update without a human reviewing the change, expanding the blast radius from a single package to every agent workspace that depends on it.
| Package | Affected range | Fixed version |
|---|---|---|
| NCalc.Corenuget | <6.1.1 | 6.1.1 |
| NCalcSyncnuget | <6.1.1 | 6.1.1 |
Fixed versions are reported by the source feed; confirm compatibility before updating.
Reported by GitHub Security Advisories (ghsa).
HOL Guard can help your team review package activity against supported protection paths.
Explore HOL GuardUpdate NCalc.Core to 6.1.1; NCalcSync to 6.1.1 if you use the affected versions. Test the change in a non-production environment first.
Local check
hol-guard supply-chain scanNCalc: Denial of Service via Unbounded and Non-Terminating Factorial Evaluation affects NCalc.Core (nuget), NCalcSync (nuget). Severity is medium. ### Impact 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: ```text 99999999999999! 9223372036854775807! 1.5e16! ``` ### Patches The vulnerability has been fixed by adding bounds validation for factorial operands and rejecting unsupported values before evaluation. Users should upgrade to the first release containing the fix from pull request #575. (**v6.1.1+**) ### Workarounds If upgrading is not immediately possible: * Do not evaluate expressions originating from untrusted users. * Validate or sanitize expressions before evaluation and reject factorial operations on large values. * Implement execution time limits, request timeouts, or cancellation mechanisms around expression evaluation. These mitigations may reduce exposure but do not fully address the underlying vulnerability.
AI coding agents often install or upgrade packages automatically in nuget. A medium vulnerability in a dependency can be pulled into a project through a normal install or update without a human reviewing the change, expanding the blast radius from a single package to every agent workspace that depends on it.
| Package | Affected range | Fixed version |
|---|---|---|
| NCalc.Corenuget | <6.1.1 | 6.1.1 |
| NCalcSyncnuget | <6.1.1 | 6.1.1 |
Fixed versions are reported by the source feed; confirm compatibility before updating.
Reported by GitHub Security Advisories (ghsa).
HOL Guard can help your team review package activity against supported protection paths.
Explore HOL Guard