Skip to content

Release of package sodium - Version 2.1.0

Choose a tag to compare

@Skycoder42 Skycoder42 released this 08 Mar 15:57
· 635 commits to main since this release
64588ce

Changelog

2.1.0 - 2023-03-08

Added

  • SodiumInit.init2 and SodiumSumoInit.init2 - these methods replace the now deprecated .init methods (#24)
    • This change was made to support the new Sodium.runIsolated APIs
    • The new variants take callbacks instead of the already resolved binaries
    • Your implementation should move the logic to load said binaries into these callbacks to allow the use of isolates.
    • Check the README, the example and the documentation for more details
  • KeyPair.copy and KeyPair.dispose methods to copy and dispose a key pair (#24)
  • Sodium.runIsolated method to allow execution of cryptographic operations on a separate isolate (#24)

Changed

  • Set minimum required dart SDK version to 2.19.0
  • Update dependencies

Deprecated

  • The sodium.crypto.pwhash API has been deprecated for non sumo variants of sodium
    • The SodiumSumo APIs still fully support pwhash
    • However, the simple Sodium APIs do not anymore
    • This is due to upstream changes in sodium.js, as there the pwhash APIs have been mode to the sumo variant of
      this library. If you use the library with the newest non sumo sodium.js, trying to use the pwhash APIs will throw
      an exception!
    • If you need the pwhash APIs, simply switch to using the sumo variant of the library
  • SodiumInit.init - use SodiumInit.init2 instead for support of the new Sodium.runIsolated APIs (#24)
  • SodiumSumoInit.init - use SodiumSumoInit.init2 instead for support of the new Sodium.runIsolated APIs (#24)

Removed

  • Removed the experimental Sodium.secureHandle, SecureKey.fromNativeHandle and SecureKey.nativeHandle APIs (#24)
    • They are not needed anymore to work around isolate limitations, as you can simply use Sodium.runIsolated instead

The package and it's documentation are available at pub.dev.