Skip to content

v0.3.0

Latest
Compare
Choose a tag to compare
@ovx ovx released this 12 May 12:44

Changes:

  • The salt now includes custom parameters in a URL-encoded query string, allowing to pass custom data and expiration time in a standardized format.
  • The createChallenge function now accepts expires: Date parameter, appending ?expires= parameter to the salt (as a Unix timestamp in seconds).
  • The verifySolution function now automatically verifies the expiration of the challenge if the salt contains ?expires= parameter. This feature can be disabled by utilizing checkExpires: false as the optional third argument.
  • Introduced the new function extractParams, enabling the extraction of custom parameters from the base64-encoded payload, payload object, or challenge object.