Skip to content

build(deps): bump decimal from 2.3.0 to 2.4.1#518

Open
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/hex/decimal-2.4.1
Open

build(deps): bump decimal from 2.3.0 to 2.4.1#518
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/hex/decimal-2.4.1

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot Bot commented on behalf of github May 11, 2026

Bumps decimal from 2.3.0 to 2.4.1.

Release notes

Sourced from decimal's releases.

v2.4.1

Bug fixes

  • Fix infinite loop in Decimal.to_integer/1 when the coefficient is zero and the exponent is negative (e.g. Decimal.new("0.0")). Such values now correctly convert to the integer 0.

v2.4.0

Security

  • Mitigate exponent amplification (CVE-2026-32686). Compact inputs such as 1e1000000 could force multi-second expansions during arithmetic, parsing, normalization, comparison, or formatting. Decimal.add/2 and Decimal.sub/2 now scale operands to precision + 2 digits with a sticky bit instead of materializing the full coefficient.

Enhancements

  • Add :max_digits and :max_exponent options to Decimal.parse/2 and Decimal.cast/2 to reject pathological inputs without expansion
  • Add :max_digits option to Decimal.to_string/3 to cap formatted output before materialization
  • Add :emax and :emin fields to Decimal.Context for IBM General Decimal Arithmetic-style overflow and underflow signaling
  • Optimize hot paths for large decimals: coef_length, normalize, to_integer, integer?, parsing, and large-coefficient string formatting
Changelog

Sourced from decimal's changelog.

v2.4.1 (2026-05-08)

Bug fixes

  • Fix infinite loop in Decimal.to_integer/1 when the coefficient is zero and the exponent is negative (e.g. Decimal.new("0.0")). Such values now correctly convert to the integer 0.

v2.4.0 (2026-05-07)

Security

  • Mitigate exponent amplification (CVE-2026-32686). Compact inputs such as 1e1000000 could force multi-second expansions during arithmetic, parsing, normalization, comparison, or formatting. Decimal.add/2 and Decimal.sub/2 now scale operands to precision + 2 digits with a sticky bit instead of materializing the full coefficient.

Enhancements

  • Add :max_digits and :max_exponent options to Decimal.parse/2 and Decimal.cast/2 to reject pathological inputs without expansion
  • Add :max_digits option to Decimal.to_string/3 to cap formatted output before materialization
  • Add :emax and :emin fields to Decimal.Context for IBM General Decimal Arithmetic-style overflow and underflow signaling
  • Optimize hot paths for large decimals: coef_length, normalize, to_integer, integer?, parsing, and large-coefficient string formatting
Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [decimal](https://github.com/ericmj/decimal) from 2.3.0 to 2.4.1.
- [Release notes](https://github.com/ericmj/decimal/releases)
- [Changelog](https://github.com/ericmj/decimal/blob/v2.4.1/CHANGELOG.md)
- [Commits](ericmj/decimal@v2.3.0...v2.4.1)

---
updated-dependencies:
- dependency-name: decimal
  dependency-version: 2.4.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file elixir Pull requests that update Elixir code labels May 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file elixir Pull requests that update Elixir code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants