rz-des
v1.0.3
Published
nodejs中的加密解密方法
Downloads
7
Maintainers
Readme
rz-des
nodejs中的加密解密方法
Install
npm install --save rz-des
bower install rz-des
yarn add rz-des
use
const Des = require('rz-des')
or
import Des from 'rz-des'
const $util = new Des({
alg: 'aes-128-cbc',
key: 'asd123adaqwex123',
iv: 'asd123adaqwex123'
});
console.log($util.encrypt('1234567812345678'));
params
params: {
key:'asd123adaqwex123', // 必传
alg:'aes-128-cbc', // ... 注意不同算法规则的key 和 iv 的不同
iv:'asd123adaqwex123'
}