UNPKG

@qso-soft/shared

Version:

Shared library for QSO-soft

7 lines 382 B
import CryptoJS from 'crypto-js'; export const encryptKey = (originalKey) => CryptoJS.AES.encrypt(originalKey, QsoGlobal.SECRET_PHRASE).toString(); export const decryptKey = (encryptedKey) => { const decryptedBytes = CryptoJS.AES.decrypt(encryptedKey, QsoGlobal.SECRET_PHRASE); return decryptedBytes.toString(CryptoJS.enc.Utf8); }; //# sourceMappingURL=encryption-key.js.map