mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-12-22 21:01:31 +03:00
8 lines
237 B
JavaScript
8 lines
237 B
JavaScript
import CryptoJS from 'crypto-js';
|
|
|
|
export const encryptKey = (key, data) => CryptoJS.AES.encrypt(key, data).toString();
|
|
|
|
export const decryptKey = (key, data) => {
|
|
return CryptoJS.AES.decrypt(key, data).toString(CryptoJS.enc.Utf8);
|
|
};
|