Numeric Errors Affecting @openzeppelin/contracts package, versions >=4.2.0 <4.3.3


Severity

Recommended
0.0
medium
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-JS-OPENZEPPELINCONTRACTS-1921095
  • published16 Nov 2021
  • disclosed15 Nov 2021
  • creditUnknown

Introduced: 15 Nov 2021

CVE NOT AVAILABLE CWE-189  (opens in a new tab)

How to fix?

Upgrade @openzeppelin/contracts to version 4.3.3 or higher.

Overview

@openzeppelin/contracts is a library for contract development.

Affected versions of this package are vulnerable to Numeric Errors. When ERC1155 tokens are minted, a callback is invoked on the receiver of those tokens, as required by the spec. When including the ERC1155Supply extension, the total supply is not updated until after the callback, thus during the callback the reported total supply is lower than the real number of tokens in circulation.

CVSS Scores

version 3.1