JuneAndGreen / sm-crypto

国密算法js版
MIT License
954 stars 254 forks source link

支持hmac_sm3 #71

Closed hyfree closed 2 years ago

hyfree commented 2 years ago

增加hmac_sm3的支持 增加hmac_sm3的单元测试用例

const hmac= require('sm-crypto').hmac
let hmac_sm3=hmac(hexToArray('0102030405060708010203040506070801020304050607080102030405060708'),//input
    hexToArray('0102030405060708010203040506070801020304050607080102030405060708'));//key
JuneAndGreen commented 2 years ago

thx,不过代码略有调整,可对照 README.md / 测试用例中的使用方式

hyfree commented 2 years ago

可以