/foundation/distributedhardware/device_manager/test/commonunittest/ |
H A D | UTTest_hichain_auth_connector.cpp | 244 std::string publicKey; in HWTEST_F() local 245 int32_t ret = hiChain_->GenerateCredential(localUdid, osAccountId, publicKey); in HWTEST_F() 253 std::string publicKey; in HWTEST_F() local 256 int32_t ret = hiChain_->GenerateCredential(localUdid, osAccountId, publicKey); in HWTEST_F() 264 std::string publicKey; in HWTEST_F() local 266 g_processCredentialReturnDataStr = R"({"result": "not_an_int", "publicKey": "key"})"; in HWTEST_F() 267 int32_t ret = hiChain_->GenerateCredential(localUdid, osAccountId, publicKey); in HWTEST_F() 275 std::string publicKey; in HWTEST_F() local 277 g_processCredentialReturnDataStr = R"({"result": 1, "publicKey": 1)"; in HWTEST_F() 278 int32_t ret = hiChain_->GenerateCredential(localUdid, osAccountId, publicKey); in HWTEST_F() 286 std::string publicKey; HWTEST_F() local 297 std::string publicKey; HWTEST_F() local 405 std::string publicKey; HWTEST_F() local 414 std::string publicKey = "4165145615"; HWTEST_F() local 421 std::string publicKey = "test"; HWTEST_F() local 432 std::string publicKey = "test"; HWTEST_F() local 443 std::string publicKey = "test"; HWTEST_F() local 454 std::string publicKey = "test"; HWTEST_F() local 465 std::string publicKey = "test"; HWTEST_F() local 476 std::string publicKey = "test"; HWTEST_F() local 489 std::string publicKey; HWTEST_F() local 498 std::string publicKey = "42125143613"; HWTEST_F() local 507 std::string publicKey = "test"; HWTEST_F() local 518 std::string publicKey = "test"; HWTEST_F() local 529 std::string publicKey = "test"; HWTEST_F() local 540 std::string publicKey = "test"; HWTEST_F() local [all...] |
H A D | UTTest_dm_auth_manager_first.cpp | 693 std::string publicKey = "publicKey"; in HWTEST_F() local 694 authManager_->GenerateCredential(publicKey); in HWTEST_F() 717 std::string publicKey = "publicKey"; in HWTEST_F() local 718 int32_t ret = authManager_->ImportCredential(deviceId, publicKey); in HWTEST_F()
|
/foundation/communication/dsoftbus/core/adapter/huks/src/ |
H A D | softbus_rsa_encrypt_virtual.c | 19 int32_t SoftBusGetPublicKey(uint8_t *publicKey, uint32_t publicKeyLen) in SoftBusGetPublicKey() argument 21 (void)publicKey; in SoftBusGetPublicKey() 26 int32_t SoftBusRsaEncrypt(const uint8_t *srcData, uint32_t srcDataLen, PublicKey *publicKey, uint8_t **encryptedData, in SoftBusRsaEncrypt() argument 31 (void)publicKey; in SoftBusRsaEncrypt()
|
H A D | softbus_rsa_encrypt.c | 118 int32_t SoftBusGetPublicKey(uint8_t *publicKey, uint32_t publicKeyLen) in SoftBusGetPublicKey() argument 120 if (publicKey == NULL || publicKeyLen == 0) { in SoftBusGetPublicKey() 149 if (memcpy_s(publicKey, publicKeyLen, publicKeyBlob.data, publicKeyBlob.size) != EOK) { in SoftBusGetPublicKey() 150 COMM_LOGE(COMM_UTILS, "publicKey memcpy_s failed."); in SoftBusGetPublicKey() 280 int32_t SoftBusRsaEncrypt(const uint8_t *srcData, uint32_t srcDataLen, PublicKey *publicKey, uint8_t **encryptedData, in SoftBusRsaEncrypt() argument 283 if (srcData == NULL || srcDataLen == 0 || publicKey == NULL || publicKey->key == NULL || in SoftBusRsaEncrypt() 284 publicKey->len <= RSA_PUB_KEY_LEN_SUBTRACT_ENCRYPT_LEN || encryptedData == NULL || encryptedDataLen == NULL) { in SoftBusRsaEncrypt() 289 if (DataToPublicKey(publicKey->key, publicKey in SoftBusRsaEncrypt() [all...] |
/foundation/communication/dsoftbus/tests/core/adapter/unittest/ |
H A D | dsoftbus_rsa_crypto_test.cpp | 77 uint8_t publicKey[pKeyLen]; in HWTEST_F() local 78 int32_t ret = SoftBusGetPublicKey(publicKey, pKeyLen); in HWTEST_F() 103 uint8_t publicKey[SOFTBUS_RSA_PUB_KEY_LEN]; in HWTEST_F() local 105 int32_t ret = SoftBusGetPublicKey(publicKey, pKeyLen); in HWTEST_F() 118 uint8_t publicKey[pKeyLen]; in HWTEST_F() local 124 int32_t ret = SoftBusGetPublicKey(publicKey, pKeyLen); in HWTEST_F() 128 PublicKey peerPublicKey = { publicKey, pKeyLen }; in HWTEST_F() 144 uint8_t publicKey[pKeyLen]; in HWTEST_F() local 150 int32_t ret = SoftBusGetPublicKey(publicKey, pKeyLen); in HWTEST_F() 154 PublicKey peerPublicKey = { publicKey, pKeyLe in HWTEST_F() 175 uint8_t publicKey[pKeyLen]; HWTEST_F() local 201 uint8_t publicKey[pKeyLen]; HWTEST_F() local 236 uint8_t publicKey[pKeyLen]; HWTEST_F() local 310 uint8_t publicKey[pKeyLen]; HWTEST_F() local [all...] |
/foundation/distributedhardware/device_manager/services/implementation/include/dependency/hichain/ |
H A D | hichain_auth_connector.h | 54 int32_t GenerateCredential(std::string &localUdid, int32_t osAccountId, std::string &publicKey); 56 int32_t ImportCredential(int32_t osAccountId, std::string deviceId, std::string publicKey); 59 int32_t GetCredential(std::string &localUdid, int32_t osAccountId, std::string &publicKey);
|
/foundation/communication/dsoftbus/core/adapter/huks/include/ |
H A D | softbus_rsa_encrypt.h | 36 int32_t SoftBusGetPublicKey(uint8_t *publicKey, uint32_t publicKeyLen); 37 int32_t SoftBusRsaEncrypt(const uint8_t *srcData, uint32_t srcDataLen, PublicKey *publicKey, uint8_t **encryptedData,
|
/foundation/distributedhardware/device_manager/services/implementation/src/dependency/hichain/ |
H A D | hichain_auth_connector.cpp | 154 int32_t HiChainAuthConnector::GenerateCredential(std::string &localUdid, int32_t osAccountId, std::string &publicKey) in GenerateCredential() argument 174 if (!IsInt32(jsonObject, "result") || !IsString(jsonObject, "publicKey") || in GenerateCredential() 183 publicKey = jsonObject["publicKey"].get<std::string>(); in GenerateCredential() 211 if (!IsString(jsonObject, "publicKey") || jsonObject["result"].get<int32_t>() == 1) { in QueryCredential() 218 int32_t HiChainAuthConnector::GetCredential(std::string &localUdid, int32_t osAccountId, std::string &publicKey) in GetCredential() argument 242 if (!IsString(jsonObject, "publicKey") || jsonObject["result"].get<int32_t>() == 1) { in GetCredential() 246 publicKey = jsonObject["publicKey"].get<std::string>(); in GetCredential() 250 int32_t HiChainAuthConnector::ImportCredential(int32_t osAccountId, std::string deviceId, std::string publicKey) in ImportCredential() argument [all...] |
/foundation/communication/bluetooth_service/services/bluetooth/stack/src/smp/ |
H A D | smp_sc_accepter.c | 38 (void)memcpy_s(SMP_GetPairMng()->peer.publicKey, SMP_PUBLICKEY_LEN, (uint8_t *)param->data, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericSlaveStep1() 63 SMP_GetPairMng()->local.publicKey, SMP_PUBLICKEY_LEN, eventParam->localP256PublicKey, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericSlaveStep2() 67 DHKeyParam.remoteP256PublicKey, SMP_PUBLICKEY_LEN, SMP_GetPairMng()->peer.publicKey, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericSlaveStep2() 89 SMP_SendPairingPublicKey(SMP_GetPairMng()->handle, SMP_GetPairMng()->local.publicKey, SMP_SendDataCallback); in SMP_ScPairJustworkOrNumericSlaveStep3() 162 SMP_GetPublicKeyX(SMP_GetPairMng()->local.publicKey, cryptF4Param.U, sizeof(cryptF4Param.U)); in SMP_ScPairJustworkOrNumericSlaveStep6() 163 SMP_GetPublicKeyX(SMP_GetPairMng()->peer.publicKey, cryptF4Param.V, sizeof(cryptF4Param.V)); in SMP_ScPairJustworkOrNumericSlaveStep6() 280 SMP_GetPublicKeyX(SMP_GetPairMng()->peer.publicKey, cryptG2Param.U, sizeof(cryptG2Param.U)); in SMP_ScPairJustworkOrNumericSlaveStep10() 281 SMP_GetPublicKeyX(SMP_GetPairMng()->local.publicKey, cryptG2Param.V, sizeof(cryptG2Param.V)); in SMP_ScPairJustworkOrNumericSlaveStep10() 369 (void)memcpy_s(SMP_GetPairMng()->peer.publicKey, SMP_PUBLICKEY_LEN, (uint8_t *)param->data, SMP_PUBLICKEY_LEN); in SMP_ScPairPasskeyEntrySlaveStep1() 394 SMP_GetPairMng()->local.publicKey, SMP_PUBLICKEY_LE in SMP_ScPairPasskeyEntrySlaveStep2() [all...] |
H A D | smp_oob.c | 48 (void)memcpy_s(g_smpScOobMng.publicKey, SMP_PUBLICKEY_LEN, eventParam->localP256PublicKey, SMP_PUBLICKEY_LEN); in SMP_GenerateScOobDataStep1() 90 SMP_GetPublicKeyX(g_smpScOobMng.publicKey, cryptF4Param.U, sizeof(cryptF4Param.U)); in SMP_GenerateScOobDataStep2() 91 SMP_GetPublicKeyX(g_smpScOobMng.publicKey, cryptF4Param.V, sizeof(cryptF4Param.V)); in SMP_GenerateScOobDataStep2()
|
H A D | smp_sc_initiator.c | 41 SMP_GetPairMng()->local.publicKey, SMP_PUBLICKEY_LEN, eventParam->localP256PublicKey, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericMasterStep1() 46 SMP_SendPairingPublicKey(SMP_GetPairMng()->handle, SMP_GetPairMng()->local.publicKey, SMP_SendDataCallback); in SMP_ScPairJustworkOrNumericMasterStep1() 65 (void)memcpy_s(SMP_GetPairMng()->peer.publicKey, SMP_PUBLICKEY_LEN, (uint8_t *)param->data, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericMasterStep2() 68 DHKeyParam.remoteP256PublicKey, SMP_PUBLICKEY_LEN, SMP_GetPairMng()->peer.publicKey, SMP_PUBLICKEY_LEN); in SMP_ScPairJustworkOrNumericMasterStep2() 190 SMP_GetPublicKeyX(SMP_GetPairMng()->peer.publicKey, cryptF4Param.U, sizeof(cryptF4Param.U)); in SMP_ScPairJustworkOrNumericMasterStep8() 191 SMP_GetPublicKeyX(SMP_GetPairMng()->local.publicKey, cryptF4Param.V, sizeof(cryptF4Param.V)); in SMP_ScPairJustworkOrNumericMasterStep8() 283 SMP_GetPublicKeyX(SMP_GetPairMng()->local.publicKey, cryptG2Param.U, sizeof(cryptG2Param.U)); in SMP_ScPairJustworkOrNumericMasterStep11() 284 SMP_GetPublicKeyX(SMP_GetPairMng()->peer.publicKey, cryptG2Param.V, sizeof(cryptG2Param.V)); in SMP_ScPairJustworkOrNumericMasterStep11() 352 SMP_GetPairMng()->local.publicKey, SMP_PUBLICKEY_LEN, eventParam->localP256PublicKey, SMP_PUBLICKEY_LEN); in SMP_ScPairPasskeyEntryMasterStep1() 357 SMP_SendPairingPublicKey(SMP_GetPairMng()->handle, SMP_GetPairMng()->local.publicKey, SMP_SendDataCallbac in SMP_ScPairPasskeyEntryMasterStep1() [all...] |
H A D | smp_cmd.h | 36 int SMP_SendPairingPublicKey(uint16_t handle, const uint8_t *publicKey, SMP_SendDataCb cb);
|
H A D | smp_def.h | 149 uint8_t publicKey[SMP_PUBLICKEY_LEN]; member 210 uint8_t publicKey[SMP_PUBLICKEY_LEN]; member
|
H A D | smp_cmd.c | 159 int SMP_SendPairingPublicKey(uint16_t handle, const uint8_t *publicKey, SMP_SendDataCb cb) in SMP_SendPairingPublicKey() argument 171 PacketPayloadWrite(pkt, publicKey, offset, SMP_PUBLICKEY_LEN); in SMP_SendPairingPublicKey()
|
H A D | smp.c | 1110 ret = SMP_SendPairingPublicKey(g_smpPairMng.handle, g_smpPairMng.local.publicKey, SMP_SendDataCallback); in SMP_AuthReqReplyStepTransMaster() 1245 DHKeyParam.remoteP256PublicKey, SMP_PUBLICKEY_LEN, g_smpPairMng.peer.publicKey, SMP_PUBLICKEY_LEN); in SMP_AuthReqReplyOobSlave() 1419 g_smpPairMng.local.publicKey, SMP_PUBLICKEY_LEN, SMP_GetScOobMng()->publicKey, SMP_PUBLICKEY_LEN); in SMP_PairReqReplyScPairOob() 1556 g_smpPairMng.local.publicKey, SMP_PUBLICKEY_LEN, SMP_GetScOobMng()->publicKey, SMP_PUBLICKEY_LEN); in SMP_PairRspReplyScPairOob()
|
/foundation/distributedhardware/device_manager/services/implementation/include/authentication/ |
H A D | dm_auth_manager.h | 161 std::string publicKey; member 495 void GenerateCredential(std::string &publicKey); 509 int32_t ImportCredential(std::string &deviceId, std::string &publicKey);
|
/foundation/distributedhardware/device_manager/services/implementation/src/authentication/ |
H A D | dm_auth_manager.cpp | 1860 std::string publicKey = ""; in RequestCredential() local 1861 GenerateCredential(publicKey); in RequestCredential() 1862 authResponseContext_->publicKey = publicKey; in RequestCredential() 1867 void DmAuthManager::GenerateCredential(std::string &publicKey) in GenerateCredential() argument 1874 hiChainAuthConnector_->GenerateCredential(localUdid, osAccountId, publicKey); in GenerateCredential() 1875 if (publicKey == "") { in GenerateCredential() 1876 hiChainAuthConnector_->GetCredential(localUdid, osAccountId, publicKey); in GenerateCredential() 1887 if (ImportCredential(remoteDeviceId_, authResponseContext_->publicKey) != DM_OK) { in RequestCredentialDone() 1897 int32_t DmAuthManager::ImportCredential(std::string &deviceId, std::string &publicKey) in ImportCredential() argument 1907 std::string publicKey = ""; ResponseCredential() local [all...] |
H A D | auth_message_processor.cpp | 146 json[TAG_PUBLICKEY] = authResponseContext_->publicKey; in CreatePublicKeyMessageExt() 305 authResponseContext_->publicKey = json[TAG_PUBLICKEY].get<std::string>(); in ParsePublicKeyMessageExt()
|
/foundation/distributedhardware/device_manager/test/unittest/ |
H A D | UTTest_auth_message_processor.cpp | 1326 "publicKey": "publicKey_test", in HWTEST_F() 1333 "publicKey": "publicKey_test", in HWTEST_F() 1340 "publicKey": "publicKey_test", in HWTEST_F() 1347 "publicKey": "publicKey_test", in HWTEST_F() 1430 authMessageProcessor->authResponseContext_->publicKey = "13213521"; in HWTEST_F() 1433 ASSERT_EQ(jsonObj[TAG_PUBLICKEY], authMessageProcessor->authResponseContext_->publicKey); in HWTEST_F() 1489 ASSERT_EQ(authMessageProcessor->authResponseContext_->publicKey.empty(), true); in HWTEST_F() 1503 ASSERT_EQ(authMessageProcessor->authResponseContext_->publicKey.empty(), false); in HWTEST_F()
|
/foundation/ability/dmsfwk/services/dtbschedmgr/src/mission/ |
H A D | distributed_bm_storage.cpp | 139 Key publicKey(keyOfPublic);
in UpdatePublicRecords() 150 Status status = kvStorePtr_->Put(publicKey, publicValue);
in UpdatePublicRecords() 597 Key publicKey(keyOfPublic);
in GetLastBundleNameId() 599 Status status = kvStorePtr_->Get(publicKey, value);
in GetLastBundleNameId()
|
/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_manage/wifi_native/client/hdi_client/hdi_interface/ |
H A D | wifi_hdi_struct.h | 288 const uint8_t *publicKey; member
|