1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-10-31 00:07:48 +02:00

Android: Fix build: Upgrade react-native-quick-crypto to v0.7.5 (#11294)

This commit is contained in:
Henry Heino
2024-10-30 13:47:59 -07:00
committed by GitHub
parent 4c0ec8c5a0
commit 441021bb7e
3 changed files with 14 additions and 680 deletions

View File

@@ -62,7 +62,7 @@
"react-native-paper": "5.12.5",
"react-native-popup-menu": "0.16.1",
"react-native-quick-actions": "0.3.13",
"react-native-quick-crypto": "0.7.2",
"react-native-quick-crypto": "0.7.5",
"react-native-rsa-native": "2.0.5",
"react-native-safe-area-context": "4.10.8",
"react-native-securerandom": "1.0.1",

View File

@@ -1,6 +1,5 @@
import { Crypto, CryptoBuffer, Digest, CipherAlgorithm, EncryptionResult, EncryptionParameters } from '@joplin/lib/services/e2ee/types';
import QuickCrypto from 'react-native-quick-crypto';
import { HashAlgorithm } from 'react-native-quick-crypto/lib/typescript/keys';
import type { CipherGCMOptions, CipherGCM, DecipherGCM } from 'crypto';
import {
generateNonce as generateNonceShared,
@@ -18,7 +17,7 @@ const digestNameMap: DigestNameMap = {
const pbkdf2Raw = (password: string, salt: CryptoBuffer, iterations: number, keylen: number, digest: Digest): Promise<CryptoBuffer> => {
return new Promise((resolve, reject) => {
QuickCrypto.pbkdf2(password, salt, iterations, keylen, digest as HashAlgorithm, (error, result) => {
QuickCrypto.pbkdf2(password, salt, iterations, keylen, digest, (error, result) => {
if (error) {
reject(error);
} else {