diff --git a/example/src/tests/subtle/derive_key.ts b/example/src/tests/subtle/derive_key.ts index cd01e193..393cef9a 100644 --- a/example/src/tests/subtle/derive_key.ts +++ b/example/src/tests/subtle/derive_key.ts @@ -1,8 +1,7 @@ import { test } from '../util'; import { expect } from 'chai'; -import { subtle, getRandomValues } from 'react-native-quick-crypto'; -import { CryptoKey } from 'react-native-quick-crypto'; -import type { CryptoKeyPair } from 'react-native-quick-crypto'; +import { subtle, getRandomValues, Buffer } from 'react-native-quick-crypto'; +import type { CryptoKey, CryptoKeyPair } from 'react-native-quick-crypto'; // eslint-disable-next-line @typescript-eslint/no-explicit-any const subtleAny = subtle as any; diff --git a/example/src/tests/subtle/wrap_unwrap.ts b/example/src/tests/subtle/wrap_unwrap.ts index 7a58aec0..6c031336 100644 --- a/example/src/tests/subtle/wrap_unwrap.ts +++ b/example/src/tests/subtle/wrap_unwrap.ts @@ -1,6 +1,6 @@ import { test } from '../util'; import { expect } from 'chai'; -import { subtle, getRandomValues } from 'react-native-quick-crypto'; +import { subtle, getRandomValues, Buffer } from 'react-native-quick-crypto'; import type { AesOcbParams, CryptoKey, diff --git a/packages/react-native-quick-crypto/src/hash.ts b/packages/react-native-quick-crypto/src/hash.ts index 229ce044..f798dfc4 100644 --- a/packages/react-native-quick-crypto/src/hash.ts +++ b/packages/react-native-quick-crypto/src/hash.ts @@ -1,6 +1,7 @@ import { Stream } from 'readable-stream'; import { NitroModules } from 'react-native-nitro-modules'; import type { TransformOptions } from 'readable-stream'; +import { Buffer } from '@craftzdog/react-native-buffer'; import type { Hash as NativeHash } from './specs/hash.nitro'; import type { BinaryLike, diff --git a/packages/react-native-quick-crypto/src/keys/publicCipher.ts b/packages/react-native-quick-crypto/src/keys/publicCipher.ts index 348f2487..68363ab7 100644 --- a/packages/react-native-quick-crypto/src/keys/publicCipher.ts +++ b/packages/react-native-quick-crypto/src/keys/publicCipher.ts @@ -1,4 +1,5 @@ import { NitroModules } from 'react-native-nitro-modules'; +import { Buffer } from '@craftzdog/react-native-buffer'; import type { RsaCipher } from '../specs/rsaCipher.nitro'; import type { BinaryLike } from '../utils'; import { diff --git a/packages/react-native-quick-crypto/src/rsa.ts b/packages/react-native-quick-crypto/src/rsa.ts index 5351bae8..c9bc71b6 100644 --- a/packages/react-native-quick-crypto/src/rsa.ts +++ b/packages/react-native-quick-crypto/src/rsa.ts @@ -1,4 +1,5 @@ import { NitroModules } from 'react-native-nitro-modules'; +import { Buffer } from '@craftzdog/react-native-buffer'; import { CryptoKey, KeyObject,