JuneAndGreen / sm-crypto

国密算法js版
MIT License
894 stars 245 forks source link

支持hmac_sm3 #71

Closed hyfree closed 1 year ago

hyfree commented 1 year ago

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

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

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

hyfree commented 1 year ago

可以