未验证 提交 7d930096 编写于 作者: 伞木希美 提交者: Gitee

update security_lite/huks/liteos_a_adapter/hks_safe_cipher_key_test.cpp.

Signed-off-by: N伞木希美 <zhanghanlin9@huawei.com>
上级 039f0bc3
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include "hks_test_curve25519.h" #include "hks_test_curve25519.h"
#include "hks_test_file_operator.h" #include "hks_test_file_operator.h"
#include "hks_test_mem.h" #include "hks_test_mem.h"
#include <stdlib.h>
#include "securec.h" #include "securec.h"
...@@ -85,8 +86,8 @@ HWTEST_F(HksSafeCipherKeyTest, HksSafeCipherKeyTest001, TestSize.Level1) ...@@ -85,8 +86,8 @@ HWTEST_F(HksSafeCipherKeyTest, HksSafeCipherKeyTest001, TestSize.Level1)
struct HksBlob X25519PubKey1 = { .size = HKS_CURVE25519_KEY_SIZE_256, .data = nullptr}; struct HksBlob X25519PubKey1 = { .size = HKS_CURVE25519_KEY_SIZE_256, .data = nullptr};
struct HksBlob X25519PubKey2 = { .size = HKS_CURVE25519_KEY_SIZE_256, .data = nullptr}; struct HksBlob X25519PubKey2 = { .size = HKS_CURVE25519_KEY_SIZE_256, .data = nullptr};
X25519PubKey1.data = (uint8_t *)HksMalloc(X25519PubKey1.size); X25519PubKey1.data = (uint8_t *)malloc(X25519PubKey1.size);
X25519PubKey2.data = (uint8_t *)HksMalloc(X25519PubKey2.size); X25519PubKey2.data = (uint8_t *)malloc(X25519PubKey2.size);
ret = HksExportPublicKey(&newAliasOne, null, &X25519PubKey1); ret = HksExportPublicKey(&newAliasOne, null, &X25519PubKey1);
EXPECT_EQ(ret, 0)<<"export alies1 fail"; EXPECT_EQ(ret, 0)<<"export alies1 fail";
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册