Skip to content

SIWE 2.0.4 Release

Compare
Choose a tag to compare
@w4ll3 w4ll3 released this 18 Jul 19:18
· 54 commits to main since this release

To improve code quality and allow for easier contribution two new scripts to check for code smells and lint the code were added to package.json:

  • lint, which checks for code smells.
  • format, which fixes code accordingly to lint and format rules.

The deprecated function validate() was returning the result of the new function verify(), which was not the previous behavior therefore it is being fixed on this release to return the previous object (SiweMessage), tests were also added to make sure existing behavior will be maintained while this function is supported.

Upgrading from SIWE 1.x to 2.0
As mentioned in the previous release for most implementers, the existing code will continue to work as expected without changes, but there will be a warning message that validate() has been deprecated, and may be removed in future versions. To get rid of this warning, you can simply update instances of validate(signature) to const { data } = verify({ signature: signature }).