/base/security/device_auth/services/mk_agree/src/ |
H A D | mk_agree_task.c | 37 Uint8Buff devicePk = { NULL, 0 }; in GeneratePakeRequestPayload() local 38 if (InitUint8Buff(&devicePk, PAKE_X25519_KEY_PAIR_LEN) != HC_SUCCESS) { in GeneratePakeRequestPayload() 39 LOGE("Failed to init devicePk!"); in GeneratePakeRequestPayload() 42 res = GetDevicePubKey(pakeTask->taskBase.osAccountId, &devicePk); in GeneratePakeRequestPayload() 45 FreeUint8Buff(&devicePk); in GeneratePakeRequestPayload() 50 ClearFreeUint8Buff(&devicePk); in GeneratePakeRequestPayload() 53 if (AddByteToJson(payload, FIELD_PUBLIC_KEY, devicePk.val, devicePk.length) != HC_SUCCESS) { in GeneratePakeRequestPayload() 54 LOGE("Failed to add devicePk to payload!"); in GeneratePakeRequestPayload() 55 ClearFreeUint8Buff(&devicePk); in GeneratePakeRequestPayload() 99 Uint8Buff devicePk = { NULL, 0 }; GeneratePakeResponsePayload() local [all...] |
H A D | key_manager.c | 371 int32_t GetDevicePubKey(int32_t osAccountId, Uint8Buff *devicePk) in GetDevicePubKey() argument 373 if (devicePk == NULL) { in GetDevicePubKey() 385 res = GetLoaderInstance()->exportPublicKey(&keyParams, devicePk); in GetDevicePubKey()
|
/base/security/device_auth/services/mk_agree/src/mock/ |
H A D | key_manager_mock.c | 66 int32_t GetDevicePubKey(int32_t osAccountId, Uint8Buff *devicePk) in GetDevicePubKey() argument 69 (void)devicePk; in GetDevicePubKey()
|
/base/security/device_auth/test/unittest/deviceauth/source/ |
H A D | mk_agree_test.cpp | 262 Uint8Buff devicePk = { NULL, 0 }; in HWTEST_F() local 263 ret = InitUint8Buff(&devicePk, PAKE_X25519_KEY_PAIR_LEN); in HWTEST_F() 265 ret = GetDevicePubKey(DEFAULT_OS_ACCOUNT, &devicePk); in HWTEST_F() 267 FreeUint8Buff(&devicePk); in HWTEST_F() 272 Uint8Buff devicePk = { NULL, 0 }; in HWTEST_F() local 273 int32_t ret = GetDevicePubKey(DEFAULT_OS_ACCOUNT, &devicePk); in HWTEST_F()
|
/base/security/device_auth/services/legacy/authenticators/src/account_related/creds_manager/ |
H A D | asy_token_manager.c | 55 if (GetByteFromJson(pkInfoJson, FIELD_DEVICE_PK, info->devicePk.val, info->devicePk.length) != HC_SUCCESS) { in GeneratePkInfoFromJson() 56 LOGE("get devicePk failed"); in GeneratePkInfoFromJson() 59 const char *devicePk = GetStringFromJson(pkInfoJson, FIELD_DEVICE_PK); in GeneratePkInfoFromJson() local 60 info->devicePk.length = HcStrlen(devicePk) / BYTE_TO_HEX_OPER_LENGTH; in GeneratePkInfoFromJson() 558 if (memcpy_s(desInfo->devicePk.val, desInfo->devicePk.length, in GeneratePkInfoFromInfo() 559 srcInfo->devicePk.val, srcInfo->devicePk in GeneratePkInfoFromInfo() 656 DoExportPkAndCompare(int32_t osAccountId, const char *userId, const char *deviceId, const char *devicePk, Uint8Buff *keyAlias) DoExportPkAndCompare() argument 716 uint8_t *devicePk = (uint8_t *)HcMalloc(PK_SIZE, 0); CheckDevicePk() local [all...] |
/base/security/device_auth/services/mk_agree/inc/ |
H A D | key_manager.h | 37 int32_t GetDevicePubKey(int32_t osAccountId, Uint8Buff *devicePk);
|
/base/security/device_auth/services/legacy/authenticators/inc/account_related/creds_manager/ |
H A D | asy_token_manager.h | 28 Uint8Buff devicePk; member
|
/base/security/device_auth/services/legacy/authenticators/src/account_related/auth/pake_v2_auth_task/ |
H A D | pake_v2_auth_task_common.c | 270 const char *devicePk = GetStringFromJson(info, FIELD_DEVICE_PK); in GetPeerPkFromPkInfo() local 271 if (devicePk == NULL) { in GetPeerPkFromPkInfo() 272 LOGE("Failed to get peer devicePk!"); in GetPeerPkFromPkInfo() 276 uint32_t pkSize = HcStrlen(devicePk) / BYTE_TO_HEX_OPER_LENGTH; in GetPeerPkFromPkInfo() 377 if (memcpy_s(params->pkSelf, PK_SIZE, token->pkInfo.devicePk.val, token->pkInfo.devicePk.length) != EOK) { in GetAsyPubKeyInfo()
|
/base/security/device_auth/services/session_manager/src/session/v2/ |
H A D | dev_session_util.c | 90 const char *devicePk = GetStringFromJson(pkInfoJson, FIELD_DEVICE_PK); in BuildRealPkInfoJson() local 91 if (devicePk == NULL) { in BuildRealPkInfoJson() 92 LOGE("Failed to get devicePk!"); in BuildRealPkInfoJson() 110 if (AddStringToJson(realPkInfoJson, FIELD_DEVICE_PK, devicePk) != HC_SUCCESS) { in BuildRealPkInfoJson() 111 LOGE("Failed to add devicePk!"); in BuildRealPkInfoJson()
|
/base/security/device_auth/services/identity_manager/src/ |
H A D | cert_operation.c | 286 const char *devicePk = GetStringFromJson(pkInfoPeer, FIELD_DEVICE_PK); in GetPeerPubKeyFromCert() local 287 if (devicePk == NULL) { in GetPeerPubKeyFromCert() 288 LOGE("Failed to get peer devicePk!"); in GetPeerPubKeyFromCert() 292 uint32_t pkSize = HcStrlen(devicePk) / BYTE_TO_HEX_OPER_LENGTH; in GetPeerPubKeyFromCert()
|