src/crypto/crypto.js
function(data) {
    // Errors
    if (!data) throw new Error('Missing argument !');
    // Processing
    let encKey = ua2words(data.key, 32);
    let encIv = {
        iv: ua2words(data.iv, 16)
    };
    // Result
    return CryptoJS.enc.Hex.stringify(CryptoJS.AES.decrypt(data, encKey, encIv));
}
function(data) {
    // Errors
    if (!data) throw new Error('Missing argument !');
    // Processing
    let encKey = ua2words(data.key, 32);
    let encIv = {
        iv: ua2words(data.iv, 16)
    };
    // Result
    return CryptoJS.enc.Hex.stringify(CryptoJS.AES.decrypt(data, encKey, encIv));
}
Decrypt data

@param {object} data - An encrypted data object

@return {string} - The decrypted hex string