-
Notifications
You must be signed in to change notification settings - Fork 0
/
ideas.txt
73 lines (67 loc) · 2.07 KB
/
ideas.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
// const canSaveToIndexDB = () => {
// return !!window?.indexedDB;
// }
// const startTimer = (durationInSeconds, callback) => {
// let remainingTime = durationInSeconds;
// const interval = setInterval(() => {
// remainingTime--;
// console.log(`Remaining time: ${remainingTime} seconds`);
// if (remainingTime <= 0) {
// clearInterval(interval);
// callback();
// }
// }, 1000);
// }
// const access_key = generateAccessKey();
// const {
// master_key,
// database_name,
// store_name,
// } = readAccessKey(access_key);
// startTimer(300, ()=>{
// console.log("Closing store...");
// });
// const name = "PassTest";
// const description = "Contraseña de prueba.";
// const password = "ramdom_password123.TEST";
// const {
// encrypted: encrypted_name,
// initialization_vector: initialization_vector_name
// } = await encryptData(name, master_key);
// const {
// encrypted: encrypted_description,
// initialization_vector: initialization_vector_description
// } = await encryptData(description, master_key);
// const {
// encrypted: encrypted_password,
// initialization_vector
// } = await encryptData(password, master_key);
// const decrypted_name = await decryptData(encrypted_name, master_key, initialization_vector_name);
// const decrypted_description = await decryptData(encrypted_description, master_key, initialization_vector_description);
// const decrypted_password = await decryptData(encrypted_password, master_key, initialization_vector);
// console.log([
// access_key,
// database_name,
// store_name,
// master_key,
// {
// name,
// description,
// password,
// },
// {
// encrypted_name,
// encrypted_description,
// encrypted_password,
// },
// {
// decrypted_name,
// decrypted_description,
// decrypted_password,
// },
// {
// initialization_vector,
// initialization_vector_name,
// initialization_vector_description,
// },
// ]);