Cleanup deprecated methods.
Noticed a handful of deprecated methods and minor warnings while looking around. Replaces with recommended methods
This commit is contained in:
9 files changed
+16
-14
No files matched your search
+1
-1
@@ -27,7 +27,7 @@ object JsSodiumLoader {
|
||||
|
||||
}
|
||||
|
||||
suspend fun load() = suspendCoroutine<Unit> { continuation ->
|
||||
suspend fun load() = suspendCoroutine { continuation ->
|
||||
if (!getSodiumLoaded()) {
|
||||
_libsodiumPromise.then<dynamic> {
|
||||
sodium_init()
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ actual object Kdf {
|
||||
): UByteArray {
|
||||
return getSodium().crypto_kdf_derive_from_key(
|
||||
subkeyLength.toUInt(),
|
||||
subkeyId.toUInt(),
|
||||
subkeyId,
|
||||
context,
|
||||
masterKey.toUInt8Array()
|
||||
).toUByteArray()
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ import ext.libsodium.com.ionspin.kotlin.crypto.toUInt8Array
|
||||
actual object PasswordHash {
|
||||
/**
|
||||
* The crypto_pwhash() function derives an outlen bytes long key from a password passwd whose length is passwdlen
|
||||
* and a salt salt whose fixed length is crypto_pwhash_SALTBYTES bytes. passwdlen should be at least crypto_pwhash_
|
||||
* and a salt whose fixed length is crypto_pwhash_SALTBYTES bytes. passwdlen should be at least crypto_pwhash_
|
||||
* PASSWD_MIN and crypto_pwhash_PASSWD_MAX. outlen should be at least crypto_pwhash_BYTES_MIN = 16 (128 bits) and
|
||||
* at most crypto_pwhash_BYTES_MAX.
|
||||
*
|
||||
|
||||
Reference in new issue
Block a user