/**
 *aes加解密
 * @author: qi.li@yoho.cn
 * @date: 2017/10/10
 */

'use strict';

const crypto = global.yoho.crypto;

/**
 * uid加密
 **/
const encryptUid = (uid) => {
    return crypto.encryption('yoho9646abcdefgh', uid + '');
};

/**
 * uid解密
 **/
const decryptUid = (uid) => {
    return crypto.decrypt('yoho9646abcdefgh', uid + '');
};

module.exports = {
    encryptUid,
    decryptUid
};