From b306fbc5d864dce271797d24babb0ea11d99d83e Mon Sep 17 00:00:00 2001 From: zhangcheng Date: Thu, 1 Sep 2022 16:25:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9HUKS=20demo=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zhangcheng --- zh-cn/application-dev/security/huks-guidelines.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/zh-cn/application-dev/security/huks-guidelines.md b/zh-cn/application-dev/security/huks-guidelines.md index 857d350ee3..c36adeabf3 100644 --- a/zh-cn/application-dev/security/huks-guidelines.md +++ b/zh-cn/application-dev/security/huks-guidelines.md @@ -1070,9 +1070,10 @@ async function testSignVerify() { }).catch((err) => { console.info('test update err information: ' + err); }); - rsaVerifyOptions.inData = finishRsaSignData; + rsaSignOptionsSecond.inData = new Uint8Array(new Array()); await huks.finish(rsaSignHandle, rsaSignOptionsSecond).then((data) => { console.info(`test finish data: ${JSON.stringify(data)}`); + finishRsaSignData = data.outData; }).catch((err) => { console.info('test finish err information: ' + JSON.stringify(err)); }); @@ -1797,9 +1798,9 @@ async function attestId() { }; generateKey(aliasString); - setTimeout(()=>huks.attestKey(aliasString, options, function (err, data) { + huks.attestKey(aliasString, options, function (err, data) { printLog(`key attest result : ${JSON.stringify(data)}`); - }), 1000); + }); } ``` @@ -1920,9 +1921,9 @@ async function attestKey() { properties: properties }; generateKey(aliasString); - setTimeout(()=>huks.attestKey(aliasString, options, function (err, data) { + huks.attestKey(aliasString, options, function (err, data) { printLog(`key attest result : ${JSON.stringify(data)}`); - }), 1000); + }); } ``` -- GitLab