/ohos5.0/drivers/peripheral/user_auth/hdi_service/key_mgr/src/ |
H A D | hmac_key.c | 28 static Buffer *GenerateHmacKey(const Buffer *peerUdid) in GenerateHmacKey() argument 30 if (!CheckBufferWithSize(peerUdid, UDID_LEN)) { in GenerateHmacKey() 44 if (memcmp(localUdidBuf.buf, peerUdid->buf, UDID_LEN) < 0) { in GenerateHmacKey() 45 salt = MergeBuffers(&localUdidBuf, peerUdid); in GenerateHmacKey() 47 salt = MergeBuffers(peerUdid, &localUdidBuf); in GenerateHmacKey() 54 ResultCode result = (ResultCode)GetDistributeKey(peerUdid, salt, &key); in GenerateHmacKey() 75 …Buffer peerUdidBuf = GetTmpBuffer(signParam.peerUdid.data, signParam.peerUdid.len, signParam.peerU… in HmacSign() 107 …Buffer peerUdidBuf = GetTmpBuffer(signParam.peerUdid.data, signParam.peerUdid.len, signParam.peerU… in HmacVerify()
|
/ohos5.0/foundation/communication/dsoftbus/core/bus_center/lnn/net_builder/src/ |
H A D | lnn_topo_manager.c | 79 char peerUdid[UDID_BUF_LEN]; member 170 const char *compareUdid = peerUdid; in FindTopoInfo() 174 topoItem = FindTopoItem(peerUdid); in FindTopoInfo() 185 if (strcmp(compareUdid, topoInfo->peerUdid) == 0) { in FindTopoInfo() 207 Anonymize(info->peerUdid, &anonyPeerUdid); in ClearTopoTable() 321 topoItem = FindTopoItem(peerUdid); in AddTopoInfo() 366 Anonymize(peerUdid, &anonyPeerUdid); in UpdateLocalTopo() 438 keyUdid = peerUdid; in TryCorrectRelation() 461 char udid[UDID_BUF_LEN], peerUdid[UDID_BUF_LEN]; in ProcessTopoUpdateInfo() local 482 if (strlen(udid) == 0 || strlen(peerUdid) == 0) { in ProcessTopoUpdateInfo() [all …]
|
H A D | lnn_net_builder_init.c | 414 const char *peerUdid = LnnConvertDLidToUdid(networkId, CATEGORY_NETWORK_ID); in TryElectAsMasterState() local 415 if (peerUdid == NULL) { in TryElectAsMasterState() 422 if (strcmp(masterUdid, peerUdid) != 0) { in TryElectAsMasterState() 425 Anonymize(peerUdid, &anonyPeerUdid); in TryElectAsMasterState() 597 static void OnDeviceNotTrusted(const char *peerUdid) in OnDeviceNotTrusted() argument 599 if (peerUdid == NULL) { in OnDeviceNotTrusted() 603 uint32_t udidLen = strlen(peerUdid) + 1; in OnDeviceNotTrusted() 608 if (DeletePcNodeInfo(peerUdid)) { in OnDeviceNotTrusted() 614 if (StringToLowerCase(peerUdid, udid, UDID_BUF_LEN) != SOFTBUS_OK) { in OnDeviceNotTrusted() 617 useUdid = SelectUseUdid(peerUdid, udid); in OnDeviceNotTrusted() [all …]
|
/ohos5.0/base/security/device_auth/services/legacy/group_manager/src/broadcast_manager/ |
H A D | broadcast_manager.c | 72 static void PostOnDeviceBound(const char *peerUdid, const char *messageStr) in PostOnDeviceBound() argument 74 if ((peerUdid == NULL) || (messageStr == NULL)) { in PostOnDeviceBound() 84 entry->listener->onDeviceBound(peerUdid, messageStr); in PostOnDeviceBound() 92 if ((peerUdid == NULL) || (messageStr == NULL)) { in PostOnDeviceUnBound() 102 entry->listener->onDeviceUnBound(peerUdid, messageStr); in PostOnDeviceUnBound() 108 static void PostOnDeviceNotTrusted(const char *peerUdid) in PostOnDeviceNotTrusted() argument 110 if (peerUdid == NULL) { in PostOnDeviceNotTrusted() 120 entry->listener->onDeviceNotTrusted(peerUdid); in PostOnDeviceNotTrusted() 126 static void PostOnLastGroupDeleted(const char *peerUdid, int groupType) in PostOnLastGroupDeleted() argument 128 if (peerUdid == NULL) { in PostOnLastGroupDeleted() [all …]
|
/ohos5.0/base/security/device_auth/services/legacy/group_manager/inc/broadcast_manager/ |
H A D | broadcast_manager.h | 29 void (*postOnDeviceBound)(const char *peerUdid, const char *messageStr); 30 void (*postOnDeviceUnBound)(const char *peerUdid, const char *messageStr); 31 void (*postOnDeviceNotTrusted)(const char *peerUdid); 32 void (*postOnLastGroupDeleted)(const char *peerUdid, int groupType);
|
/ohos5.0/foundation/communication/dsoftbus/core/bus_center/lnn/lane_hub/lane_manager/src/ |
H A D | lnn_lane_link.c | 176 strncmp(item->link.peerUdid, linkInfoItem->peerUdid, UDID_BUF_LEN) == 0 && in GetValidLaneResource() 646 if (strcmp(peerUdid, item->link.peerUdid) == 0 && type == item->link.type) { in FindLaneResourceByLinkType() 731 if (strcpy_s(item->link.peerUdid, UDID_BUF_LEN, peerUdid) != EOK) { in UpdateLaneResourceLaneId() 760 if (strcmp(peerUdid, item->link.peerUdid) == 0 && type == item->link.type) { in CheckLaneResourceNumByLinkType() 853 …int32_t ret = SoftBusGenerateStrHash((const unsigned char*)peerUdid, strlen(peerUdid), peerUdidHas… in ConvertUdidToHexStr() 872 char peerUdid[UDID_BUF_LEN] = {0}; in FetchLaneResourceByDevId() local 890 if ((!isSameDevice && strcmp(peerUdid, item->link.peerUdid) != 0) || in FetchLaneResourceByDevId() 891 (isSameDevice && strcmp(peerUdid, item->link.peerUdid) == 0)) { in FetchLaneResourceByDevId() 1267 char peerUdid[UDID_BUF_LEN] = {0}; in LaneLinkOfBle() local 1272 int32_t ret = SoftBusGenerateStrHash((uint8_t*)peerUdid, strlen(peerUdid), in LaneLinkOfBle() [all …]
|
H A D | lnn_lane_listener.c | 202 uint64_t laneId = GenerateLaneId(localUdid, laneLinkInfo->peerUdid, laneLinkInfo->type); in FindLaneBusinessInfoByLinkInfo() 262 int32_t LaneLinkupNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) in LaneLinkupNotify() argument 264 if (peerUdid == NULL || laneLinkInfo == NULL) { in LaneLinkupNotify() 294 uint64_t laneId = GenerateLaneId(localUdid, peerUdid, laneLinkInfo->type); in LaneLinkupNotify() 298 listenerList[i].listener.onLaneLinkup(laneId, peerUdid, &laneConnInfo); in LaneLinkupNotify() 304 int32_t LaneLinkdownNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) in LaneLinkdownNotify() argument 306 if (peerUdid == NULL || laneLinkInfo == NULL) { in LaneLinkdownNotify() 312 if (FindLaneResourceByLinkType(peerUdid, laneLinkInfo->type, &resourceItem) == SOFTBUS_OK) { in LaneLinkdownNotify() 320 FindLaneResourceByLinkType(peerUdid, LANE_HML_RAW, &resourceItem) == SOFTBUS_OK) { in LaneLinkdownNotify() 525 if (strlen(laneLinkInfo.peerUdid) != 0) { in LnnOnWifiDirectConnectedForSink() [all …]
|
/ohos5.0/foundation/distributedhardware/device_manager/radar/include/ |
H A D | dm_radar_helper.h | 128 std::string peerUdid; member 145 virtual bool ReportAuthStart(const std::string &peerUdid, const std::string &pkgName) = 0; 162 int32_t channelId, std::string peerUdid, int32_t errCode, int32_t stageRes) = 0; 164 std::string peerUdid, int32_t errCode, int32_t stageRes) = 0; 165 …oid ReportSendOrReceiveHolderMsg(int32_t bizStage, std::string funcName, std::string peerUdid) = 0; 176 bool ReportAuthStart(const std::string &peerUdid, const std::string &pkgName) override; 193 int32_t channelId, std::string peerUdid, int32_t errCode, int32_t stageRes) override; 195 std::string peerUdid, int32_t errCode, int32_t stageRes) override; 196 …void ReportSendOrReceiveHolderMsg(int32_t bizStage, std::string funcName, std::string peerUdid) ov…
|
/ohos5.0/base/security/device_auth/test/fuzztest/device_auth_service/devauthservregdatachangelistener_fuzzer/ |
H A D | devauthservregdatachangelistener_fuzzer.cpp | 27 static void OnDeviceBound(const char *peerUdid, const char *groupInfo) {} in OnDeviceBound() argument 29 static void OnDeviceUnBound(const char *peerUdid, const char *groupInfo) {} in OnDeviceUnBound() argument 31 static void OnDeviceNotTrusted(const char *peerUdid) {} in OnDeviceNotTrusted() argument 33 static void OnLastGroupDeleted(const char *peerUdid, int groupType) {} in OnLastGroupDeleted() argument
|
/ohos5.0/base/security/device_auth/test/fuzztest/group_manage/registerdatachangelistener_fuzzer/ |
H A D | registerdatachangelistener_fuzzer.cpp | 23 void onDeviceBound(const char *peerUdid, const char *groupInfo) {} in onDeviceBound() argument 25 void onDeviceUnBound(const char *peerUdid, const char *groupInfo) {} in onDeviceUnBound() argument 27 void onDeviceNotTrusted(const char *peerUdid) {} in onDeviceNotTrusted() argument 29 void onLastGroupDeleted(const char *peerUdid, int groupType) {} in onLastGroupDeleted() argument
|
/ohos5.0/foundation/distributedhardware/device_manager/radar/src/ |
H A D | dm_radar_helper.cpp | 179 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportAuthStart() 246 "PEER_UDID", GetAnonyUdid(info.peerUdid), in ReportAuthSessionOpenCb() 540 "PEER_UDID", GetAnonyUdid(info.peerUdid), in ReportNetworkOnline() 563 "PEER_UDID", GetAnonyUdid(info.peerUdid), in ReportNetworkOffline() 586 "PEER_UDID", GetAnonyUdid(info.peerUdid), in ReportDeleteTrustRelation() 614 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportCreatePinHolder() 634 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportCreatePinHolder() 661 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportDestroyPinHolder() 680 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportDestroyPinHolder() 706 "PEER_UDID", GetAnonyUdid(peerUdid), in ReportSendOrReceiveHolderMsg() [all …]
|
/ohos5.0/foundation/communication/dsoftbus/tests/core/bus_center/lnn/lane/trans_lane/ |
H A D | lnn_trans_lane_deps_mock.cpp | 129 int32_t LaneLinkupNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) in LaneLinkupNotify() argument 131 return GetTransLaneIf()->LaneLinkupNotify(peerUdid, laneLinkInfo); in LaneLinkupNotify() 134 int32_t LaneLinkdownNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) in LaneLinkdownNotify() argument 136 return GetTransLaneIf()->LaneLinkdownNotify(peerUdid, laneLinkInfo); in LaneLinkdownNotify() 154 int32_t CheckLaneResourceNumByLinkType(const char *peerUdid, LaneLinkType type, int32_t *laneNum) in CheckLaneResourceNumByLinkType() argument 156 return GetTransLaneIf()->CheckLaneResourceNumByLinkType(peerUdid, type, laneNum); in CheckLaneResourceNumByLinkType()
|
H A D | lnn_trans_lane_deps_mock.h | 50 virtual int32_t LaneLinkupNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) = 0; 51 virtual int32_t LaneLinkdownNotify(const char *peerUdid, const LaneLinkInfo *laneLinkInfo) = 0; 55 …virtual int32_t CheckLaneResourceNumByLinkType(const char *peerUdid, LaneLinkType type, int32_t *l… 77 … MOCK_METHOD2(LaneLinkupNotify, int32_t (const char *peerUdid, const LaneLinkInfo *laneLinkInfo)); 78 …MOCK_METHOD2(LaneLinkdownNotify, int32_t (const char *peerUdid, const LaneLinkInfo *laneLinkInfo)); 82 …MOCK_METHOD3(CheckLaneResourceNumByLinkType, int32_t (const char *peerUdid, LaneLinkType type, int…
|
/ohos5.0/base/security/device_auth/services/legacy/group_auth/src/group_auth_manager/account_related_group_auth/ |
H A D | account_related_group_auth.c | 303 const char *peerUdid = GetStringFromJson(paramsData, FIELD_PEER_CONN_DEVICE_ID); in FillAccountAuthInfo() local 304 if (peerUdid == NULL) { in FillAccountAuthInfo() 359 const char *peerUdid = GetStringFromJson(confirmationJson, FIELD_PEER_CONN_DEVICE_ID); in CombineAccountServerConfirms() local 360 if (peerUdid == NULL) { in CombineAccountServerConfirms() 580 if (peerUdid == NULL) { in AddSelfDevInfoForServer() 720 static int32_t PrepareTrustedDeviceInfo(const char *peerUdid, const char *groupId, in PrepareTrustedDeviceInfo() argument 746 !StringSetPointer(&(devEntry->udid), peerUdid) || in PrepareTrustedDeviceInfo() 763 const char *peerUdid = GetStringFromJson(authParam, FIELD_PEER_CONN_DEVICE_ID); in AddTrustedDeviceForAccount() local 764 if (peerUdid == NULL) { in AddTrustedDeviceForAccount() 773 if (IsDeviceImportedByCloud(osAccountId, peerUdid, groupId)) { in AddTrustedDeviceForAccount() [all …]
|
/ohos5.0/foundation/communication/dsoftbus/tests/core/bus_center/lnn/lane_listener/ |
H A D | lnn_lane_listener_deps_mock.cpp | 49 int32_t PostLaneStateChangeMessage(LaneState state, const char *peerUdid, const LaneLinkInfo *laneL… in PostLaneStateChangeMessage() argument 51 … return GetLaneListenerDepsInterface()->PostLaneStateChangeMessage(state, peerUdid, laneLinkInfo); in PostLaneStateChangeMessage() 64 int32_t FindLaneResourceByLinkType(const char *peerUdid, LaneLinkType type, LaneResource *resource) in FindLaneResourceByLinkType() argument 66 return GetLaneListenerDepsInterface()->FindLaneResourceByLinkType(peerUdid, type, resource); in FindLaneResourceByLinkType()
|
H A D | lnn_lane_listener_deps_mock.h | 34 virtual int32_t PostLaneStateChangeMessage(LaneState state, const char *peerUdid, 38 …virtual int32_t FindLaneResourceByLinkType(const char *peerUdid, LaneLinkType type, LaneResource *… 56 MOCK_METHOD3(PostLaneStateChangeMessage, int32_t (LaneState state, const char *peerUdid, 60 …MOCK_METHOD3(FindLaneResourceByLinkType, int32_t (const char *peerUdid, LaneLinkType type, LaneRes…
|
/ohos5.0/foundation/communication/dsoftbus/core/authentication/src/ |
H A D | auth_deviceprofile.cpp | 196 static void InsertDpSameAccount(const std::string peerUdid) in InsertDpSameAccount() argument 216 accessee.SetAccesseeDeviceId(peerUdid); in InsertDpSameAccount() 222 accessControlProfile.SetTrustDeviceId(peerUdid); in InsertDpSameAccount() 231 Anonymize(peerUdid.c_str(), &anonyUdid); in InsertDpSameAccount() 242 std::string peerUdid(deviceId); in UpdateDpSameAccount() local 244 InsertDpSameAccount(peerUdid); in UpdateDpSameAccount()
|
H A D | auth_device.c | 327 void AuthDeviceNotTrust(const char *peerUdid) in AuthDeviceNotTrust() argument 329 if (peerUdid == NULL || strlen(peerUdid) == 0) { in AuthDeviceNotTrust() 338 RemoveNotPassedAuthManagerByUdid(peerUdid); in AuthDeviceNotTrust() 339 AuthSessionHandleDeviceNotTrusted(peerUdid); in AuthDeviceNotTrust() 340 LnnDeleteSpecificTrustedDevInfo(peerUdid); in AuthDeviceNotTrust() 342 AuthRemoveDeviceKeyByUdid(peerUdid); in AuthDeviceNotTrust() 385 RemoveNotPassedAuthManagerByUdid(peerUdid); in OnDeviceNotTrusted() 386 AuthSessionHandleDeviceNotTrusted(peerUdid); in OnDeviceNotTrusted() 387 LnnDeleteSpecificTrustedDevInfo(peerUdid); in OnDeviceNotTrusted() 392 g_verifyListener.onDeviceNotTrusted(peerUdid); in OnDeviceNotTrusted() [all …]
|
/ohos5.0/base/security/device_auth/services/legacy/group_auth/src/group_auth_manager/account_unrelated_group_auth/ |
H A D | account_unrelated_group_auth.c | 98 const char *peerUdid = GetStringFromJson(authParam, FIELD_PEER_CONN_DEVICE_ID); in AddPeerUdidToSelfData() local 99 if (peerUdid == NULL) { in AddPeerUdidToSelfData() 103 if (AddStringToJson(returnToSelf, FIELD_PEER_CONN_DEVICE_ID, peerUdid) != HC_SUCCESS) { in AddPeerUdidToSelfData() 369 const char *peerUdid = GetStringFromJson(paramsData, FIELD_PEER_CONN_DEVICE_ID); in FillNonAccountAuthInfo() local 374 if (peerUdid != NULL) { in FillNonAccountAuthInfo() 375 res = GaGetTrustedDeviceEntryById(osAccountId, peerUdid, true, groupId, peerAuthInfo); in FillNonAccountAuthInfo() 417 const char *peerUdid = GetStringFromJson(confirmationJson, FIELD_PEER_CONN_DEVICE_ID); in CombineDasServerConfirmParams() local 418 if (peerUdid != NULL) { in CombineDasServerConfirmParams() 419 if (AddStringToJson(dataFromClient, FIELD_PEER_CONN_DEVICE_ID, peerUdid) != HC_SUCCESS) { in CombineDasServerConfirmParams()
|
/ohos5.0/foundation/communication/dsoftbus/tests/core/bus_center/lnn/lane/src/ |
H A D | lnn_wifi_adpter_mock.cpp | 67 char peerUdid[] = "222222222222222222"; in ActionOfLnnConnectP2p() local 71 if (strncpy_s(linkInfo.peerUdid, UDID_BUF_LEN, peerUdid, strlen(peerUdid)) != EOK) { in ActionOfLnnConnectP2p()
|
/ohos5.0/base/security/device_auth/services/session_manager/src/session/v1/compatible_bind_sub_session/ |
H A D | compatible_bind_sub_session.c | 185 const char *peerUdid = GetStringFromJson(jsonParams, FIELD_CONN_DEVICE_ID); in CheckServerStatusIfNotInvite() local 186 if (peerUdid == NULL) { in CheckServerStatusIfNotInvite() 200 result = CheckDeviceNumLimit(osAccountId, groupId, peerUdid); in CheckServerStatusIfNotInvite() 478 static int32_t AddPeerDevToGroup(const char *peerAuthId, const char *peerUdid, in AddPeerDevToGroup() argument 499 result = AddPeerDevToGroup(peerAuthId, peerUdid, groupId, session); in AddGroupAndDev() 510 int32_t result = AddGroupAndDev(peerAuthId, peerUdid, groupId, session); in HandleBindSuccess() 515 return InformSelfBindSuccess(peerAuthId, peerUdid, groupId, session, out); in HandleBindSuccess() 529 if (peerUdid == NULL) { in OnBindFinish() 530 peerUdid = GetStringFromJson(session->params, FIELD_PEER_UDID); in OnBindFinish() 531 if (peerUdid == NULL) { in OnBindFinish() [all …]
|
/ohos5.0/foundation/communication/dsoftbus/core/bus_center/lnn/lane_hub/lane_manager/include/ |
H A D | lnn_lane_link.h | 95 char peerUdid[UDID_BUF_LEN]; member 136 int32_t FindLaneResourceByLinkType(const char *peerUdid, LaneLinkType type, LaneResource *resource); 137 int32_t CheckLaneResourceNumByLinkType(const char *peerUdid, LaneLinkType type, int32_t *laneNum); 141 int32_t UpdateLaneResourceLaneId(uint64_t oldLaneId, uint64_t newLaneId, const char *peerUdid);
|
/ohos5.0/foundation/communication/dsoftbus/core/transmission/trans_channel/proxy/src/ |
H A D | softbus_proxychannel_listener.c | 127 TransGetRemoteDeviceVersion(extra->peerUdid, CATEGORY_UDID, (char *)(appInfo->peerVersion), in FillExtraByProxyChannelErrorEnd() 168 extra.peerUdid = appInfo->peerUdid; in OnProxyChannelOpened() 171 … extra.peerUdid = appInfo->appType == APP_TYPE_AUTH ? appInfo->peerData.deviceId : extra.peerUdid; in OnProxyChannelOpened() 282 … .peerUdid = appInfo->appType == APP_TYPE_AUTH ? appInfo->peerData.deviceId : appInfo->peerUdid, in TransProxyReportOpenChannelFailEvent() 288 … TransGetRemoteDeviceVersion(extra.peerUdid, CATEGORY_UDID, (char *)(appInfo->peerVersion), in TransProxyReportOpenChannelFailEvent() 397 GetRemoteUdidWithNetworkId(peerNetworkId, appInfo->peerUdid, sizeof(appInfo->peerUdid)); in TransProxyGetAppInfo()
|
/ohos5.0/foundation/distributedhardware/device_manager/radar/src/lite/ |
H A D | dm_radar_helper.cpp | 45 bool DmRadarHelper::ReportAuthStart(const std::string &peerUdid, const std::string &pkgName) in ReportAuthStart() argument 126 int32_t channelId, std::string peerUdid, int32_t errCode, int32_t stageRes) in ReportCreatePinHolder() argument 132 std::string peerUdid, int32_t errCode, int32_t stageRes) in ReportDestroyPinHolder() argument 137 …rHelper::ReportSendOrReceiveHolderMsg(int32_t bizStage, std::string funcName, std::string peerUdid) in ReportSendOrReceiveHolderMsg() argument
|
/ohos5.0/foundation/distributedhardware/device_manager/test/unittest/mock/ |
H A D | device_auth.h | 134 void (*onDeviceBound)(const char *peerUdid, const char *groupInfo); 135 void (*onDeviceUnBound)(const char *peerUdid, const char *groupInfo); 136 void (*onDeviceNotTrusted)(const char *peerUdid); 137 void (*onLastGroupDeleted)(const char *peerUdid, int groupType); 154 int32_t (*getAuthState)(int64_t authReqId, const char *groupId, const char *peerUdid,
|