forked from tectiv3/react-native-aes
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.d.ts
More file actions
15 lines (14 loc) · 834 Bytes
/
index.d.ts
File metadata and controls
15 lines (14 loc) · 834 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
declare module 'react-native-aes-crypto' {
namespace Aes {
type Algorithms = 'aes-128-cbc' | 'aes-192-cbc' | 'aes-256-cbc'
function pbkdf2(password: string, salt: string, cost: number, length: number): Promise<string>
function encrypt(text: string, key: string, iv: string, algorithm: Algorithms): Promise<string>
function decrypt(ciphertext: string, key: string, iv: string, algorithm: Algorithms): Promise<string>
function hmac256(ciphertext: string, key: string): Promise<string>
function hmac512(ciphertext: string, key: string): Promise<string>
function randomKey(length: number): Promise<string>
function sha1(text: string): Promise<string>
function sha256(text: string): Promise<string>
function sha512(text: string): Promise<string>
}
}