mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-23 23:19:40 +01:00
change iv size from 32 to 16
This commit is contained in:
@@ -23,7 +23,7 @@ function encrypt(password, data) {
|
|||||||
return Aes.pbkdf2('password', 'salt', 5000, 256).then(aes => {
|
return Aes.pbkdf2('password', 'salt', 5000, 256).then(aes => {
|
||||||
key = aes;
|
key = aes;
|
||||||
|
|
||||||
return Aes.randomKey(32).then(iv => {
|
return Aes.randomKey(16).then(iv => {
|
||||||
return Aes.encrypt(data, key, iv).then(cipher => ({
|
return Aes.encrypt(data, key, iv).then(cipher => ({
|
||||||
cipher,
|
cipher,
|
||||||
iv,
|
iv,
|
||||||
|
|||||||
Reference in New Issue
Block a user