Home
last modified time | relevance | path

Searched refs:opCode (Results 1 – 25 of 50) sorted by relevance

12

/base/security/device_auth/services/authenticators/src/account_unrelated/pake_task/
Dpake_task_common.c41 if (params->opCode == AUTHENTICATE) { in ConstructOutJson()
87 GOTO_ERR_AND_SET_RET(AddIntToJson(sendToSelf, FIELD_OPERATION_CODE, params->opCode), res); in SendResultToSelf()
158 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in FillAuthId()
235 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in FillNonce()
251 if (GetIntFromJson(in, FIELD_OPERATION_CODE, &(params->opCode)) != HC_SUCCESS) { in FillDasPakeParams()
253 params->opCode = AUTHENTICATE; in FillDasPakeParams()
255 if (params->opCode != OP_BIND && params->opCode != OP_UNBIND && in FillDasPakeParams()
256 params->opCode != AUTHENTICATE && params->opCode != AUTH_KEY_AGREEMENT) { in FillDasPakeParams()
257 LOGE("Unsupported opCode: %d.", params->opCode); in FillDasPakeParams()
271 if (params->opCode != AUTH_KEY_AGREEMENT) { in FillDasPakeParams()
[all …]
Dpake_message_util.c33 if (AddIntToJson(payload, FIELD_OPERATION_CODE, params->opCode) != HC_SUCCESS) { in PackagePakeRequestData()
37 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in PackagePakeRequestData()
72 if (params->opCode == AUTHENTICATE || params->opCode == AUTH_KEY_AGREEMENT) { in ParsePakeRequestMessage()
95 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in PackagePakeResponseData()
142 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in ParsePakeResponseMessage()
/base/security/device_auth/services/group_manager/src/
Dgroup_manager_common.c28 task->opCode = taskParams->opCode; in InitGroupManagerTask()
80 int32_t InitAndPushGMTask(int32_t osAccountId, int32_t opCode, int64_t reqId, CJson *params, TaskFu… in InitAndPushGMTask() argument
89 taskParams.opCode = opCode; in InitAndPushGMTask()
/base/security/device_auth/services/authenticators/src/account_unrelated/pake_task/pake_v1_task/pake_v1_protocol_task/
Dpake_v1_client_protocol_task.c66 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in PakeRequest()
74 …if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND || params->opCode == AUTH_KEY_AG… in PakeRequest()
101 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in ParseMsgForClientConfirm()
156 if (params->isPskSupported && (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND)) { in PakeClientConfirm()
241 res = ClientProtocolMessageOut(out, params->opCode, step); in Process()
Dpake_v1_server_protocol_task.c65 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in PackageMsgForResponse()
91 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in PakeResponse()
99 if (params->isPskSupported && (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND)) { in PakeResponse()
206 res = ServerProtocolMessageOut(out, params->opCode, step); in Process()
/base/security/device_auth/services/authenticators/src/account_related/
Daccount_module.c37 int32_t opCode; in IsAccountMsgNeedIgnore() local
38 if (GetIntFromJson(in, FIELD_OPERATION_CODE, &opCode) != HC_SUCCESS) { in IsAccountMsgNeedIgnore()
43 if (opCode == OP_BIND) { in IsAccountMsgNeedIgnore()
45 } else if (opCode == AUTHENTICATE) { in IsAccountMsgNeedIgnore()
48 LOGE("Invalid opCode: %d.", opCode); in IsAccountMsgNeedIgnore()
/base/security/device_auth/services/group_manager/inc/
Dbase_group_manager_task.h27 int32_t opCode; member
35 int32_t opCode; member
/base/security/access_token/services/privacymanager/src/record/
Dpermission_record_manager.cpp82 record.tokenId, record.opCode, record.status, record.timestamp); in AddRecord()
94 int32_t opCode; in GetPermissionRecord() local
95 if (!Constant::TransferPermissionToOpcode(permissionName, opCode)) { in GetPermissionRecord()
107 record.opCode = opCode; in GetPermissionRecord()
339 …[record](const auto& rec) { return (rec.opCode == record.opCode) && (rec.tokenId == record.tokenId… in AddRecordIfNotStarted()
342 record.tokenId, record.opCode); in AddRecordIfNotStarted()
345 record.tokenId, record.opCode); in AddRecordIfNotStarted()
360 Constant::TransferOpcodeToPermission(it->opCode, perm); in FindRecordsToUpdateAndExecuted()
407 …CESSTOKEN_LOG_DEBUG(LABEL, "tokenId %{public}d, opCode %{public}d", record.tokenId, record.opCode); in RemoveRecordFromStartList()
410 if ((it->opCode == record.opCode) && (it->tokenId == record.tokenId)) { in RemoveRecordFromStartList()
[all …]
Dpermission_record.cpp25 values.Put(PrivacyFiledConst::FIELD_OP_CODE, record.opCode); in TranslationIntoGenericValues()
36 record.opCode = values.GetInt(PrivacyFiledConst::FIELD_OP_CODE); in TranslationIntoPermissionRecord()
/base/security/device_auth/services/authenticators/inc/account_unrelated/
Ddas_task_common.h39 int ClientProtocolMessageOut(CJson *out, int opCode, uint32_t step);
40 int ServerProtocolMessageOut(CJson *out, int opCode, uint32_t step);
Ddas_version_util.h43 int32_t opCode; member
60 ProtocolType GetPrototolType(VersionStruct *curVersion, OperationCode opCode);
/base/security/access_token/services/privacymanager/src/common/
Dconstant.cpp66 bool Constant::TransferPermissionToOpcode(const std::string& permissionName, int32_t& opCode) in TransferPermissionToOpcode() argument
71 opCode = PERMISSION_OPCODE_MAP.at(permissionName); in TransferPermissionToOpcode()
75 bool Constant::TransferOpcodeToPermission(int32_t opCode, std::string& permissionName) in TransferOpcodeToPermission() argument
78 [opCode](const std::map<std::string, int32_t>::value_type item) { in TransferOpcodeToPermission()
79 return item.second == opCode; in TransferOpcodeToPermission()
/base/security/device_auth/services/authenticators/src/account_unrelated/pake_task/pake_v1_task/
Dpake_v1_client_task.c67 switch (realTask->params.opCode) { in CreateNextTask()
79 LOGE("Unsupported opCode: %d.", realTask->params.opCode); in CreateNextTask()
83 … LOGE("Create and process next task failed, opcode: %d, res: %d.", realTask->params.opCode, res); in CreateNextTask()
94 LOGI("End client task successfully, opcode: %d.", realTask->params.opCode); in CreateNextTask()
Dpake_v1_server_task.c67 switch (realTask->params.opCode) { in CreateNextTask()
79 LOGE("Unsupported opCode: %d.", realTask->params.opCode); in CreateNextTask()
83 … LOGE("Create and process next task failed, opcode: %d, res: %d.", realTask->params.opCode, res); in CreateNextTask()
94 LOGI("End server task successfully, opcode: %d.", realTask->params.opCode); in CreateNextTask()
/base/security/device_auth/services/
Ddevice_auth.c321 int32_t opCode = GetOpCodeFromContext(context); in AddClientReqInfoToContext() local
322 if (AddIntToJson(context, FIELD_OPERATION_CODE, opCode) != HC_SUCCESS) { in AddClientReqInfoToContext()
326 if (opCode == MEMBER_JOIN) { in AddClientReqInfoToContext()
510 static int32_t AddServerReqInfoToContext(int64_t requestId, const char *appId, int32_t opCode, in AddServerReqInfoToContext() argument
544 if (AddIntToJson(context, FIELD_OPERATION_CODE, opCode) != HC_SUCCESS) { in AddServerReqInfoToContext()
549 if (opCode == MEMBER_INVITE) { in AddServerReqInfoToContext()
563 static int32_t BuildServerBindContext(int64_t requestId, const char *appId, int32_t opCode, in BuildServerBindContext() argument
566 int32_t res = AddServerReqInfoToContext(requestId, appId, opCode, receivedMsg, context); in BuildServerBindContext()
607 int32_t opCode; in OpenServerBindSession() local
608 if (GetIntFromJson(receivedMsg, FIELD_GROUP_OP, &opCode) != HC_SUCCESS) { in OpenServerBindSession()
[all …]
/base/security/access_token/services/privacymanager/include/common/
Dconstant.h80 static bool TransferPermissionToOpcode(const std::string& permissionName, int32_t& opCode);
81 static bool TransferOpcodeToPermission(int32_t opCode, std::string& permissionName);
/base/security/device_auth/services/authenticators/src/account_unrelated/iso_task/
Diso_task_common.c112 GOTO_ERR_AND_SET_RET(AddIntToJson(payload, FIELD_OPERATION_CODE, params->opCode), ret); in GenerateEncResult()
192 GOTO_ERR_AND_SET_RET(AddIntToJson(sendToSelf, FIELD_OPERATION_CODE, params->opCode), res); in GenEncResult()
316 if (params->opCode == OP_BIND) { in FillAuthId()
381 if (params->opCode == OP_BIND) { in FillPin()
435 if (params->opCode == OP_UNBIND || params->opCode == OP_BIND) { in GetKeyLength()
454 if (GetIntFromJson(in, FIELD_OPERATION_CODE, &(params->opCode)) != 0) { in InitIsoParams()
456 params->opCode = AUTHENTICATE; in InitIsoParams()
458 … if (params->opCode != OP_BIND && params->opCode != OP_UNBIND && params->opCode != AUTHENTICATE) { in InitIsoParams()
459 LOGE("Unsupported opCode: %d.", params->opCode); in InitIsoParams()
560 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in GeneratePsk()
/base/security/access_token/services/privacymanager/test/unittest/
Dpermission_record_manager_test.cpp93 .opCode = Constant::OP_CAMERA,
102 .opCode = Constant::OP_MICROPHONE,
111 .opCode = Constant::OP_CAMERA,
120 .opCode = Constant::OP_MICROPHONE,
307 .opCode = Constant::OP_CAMERA,
317 …PermissionRecordManager::GetInstance().GetRecordFromStartList(record1.tokenId, record1.opCode, rec…
337 .opCode = Constant::OP_MICROPHONE,
346 …PermissionRecordManager::GetInstance().GetRecordFromStartList(record1.tokenId, record1.opCode, rec…
365 .opCode = Constant::OP_CAMERA,
373 …PermissionRecordManager::GetInstance().GetRecordFromStartList(record1.tokenId, record1.opCode, rec…
[all …]
/base/security/device_auth/services/session_manager/src/session/
Ddev_session_fwk.c185 if (AddIntToJson(sendMsg, FIELD_OP_CODE, impl->base.opCode) != HC_SUCCESS) { in AddSessionInfo()
245 ProcessErrorCallback(impl->base.id, impl->base.opCode, res, NULL, &impl->base.callback); in StartSession()
323 return CombineConfirmData(impl->opCode, impl->context, receviedMsg); in CombindServerBindParams()
397 ProcessErrorCallback(impl->base.id, impl->base.opCode, errorCode, NULL, &impl->base.callback); in OnV1SessionError()
448 ProcessFinishCallback(impl->base.id, impl->base.opCode, returnData, &impl->base.callback); in OnDevSessionFinish()
463 …ProcessErrorCallback(impl->base.id, impl->base.opCode, HC_ERR_NOT_SUPPORT, NULL, &impl->base.callb… in ProcV2Session()
479 ProcessErrorCallback(impl->base.id, impl->base.opCode, res, NULL, &impl->base.callback); in ProcV2Session()
507 int32_t opCode; in BuildDevSessionByContext() local
508 if (GetIntFromJson(context, FIELD_OPERATION_CODE, &opCode) != HC_SUCCESS) { in BuildDevSessionByContext()
527 session->base.opCode = opCode; in BuildDevSessionByContext()
/base/security/device_auth/services/session_manager/src/session/v1/compatible_bind_sub_session/
Dcompatible_bind_sub_session.c105 static int32_t CreateBaseBindSubSession(int32_t sessionType, int32_t opCode, const CJson *params, in CreateBaseBindSubSession() argument
138 subSession->opCode = opCode; in CreateBaseBindSubSession()
147 static int32_t GenerateKeyPairIfNeeded(int isClient, int32_t opCode, CJson *jsonParams) in GenerateKeyPairIfNeeded() argument
149 if (!IsCreateGroupNeeded(isClient, opCode)) { in GenerateKeyPairIfNeeded()
204 … int32_t result = CheckServerStatusIfNotInvite(session->osAccountId, session->opCode, jsonParams); in GenerateServerBindParams()
213 return GenerateKeyPairIfNeeded(SERVER, session->opCode, jsonParams); in GenerateServerBindParams()
276 ProcessFinishCallback(session->reqId, session->opCode, jsonDataStr, session->base.callback); in InformSelfBindSuccess()
769 result = AddInfoToBindData((session->opCode == MEMBER_JOIN), session, *sendData); in PrepareServerData()
814 int32_t opCode = MEMBER_INVITE; in CreateClientBindSubSession() local
815 if (GetIntFromJson(jsonParams, FIELD_OPERATION_CODE, &opCode) != HC_SUCCESS) { in CreateClientBindSubSession()
[all …]
/base/security/device_auth/services/session_manager/inc/session/v1/compatible_bind_sub_session/
Dcompatible_bind_sub_session_defines.h27 int32_t opCode; member
/base/security/access_token/services/privacymanager/src/database/
Ddata_translator.cpp57 int32_t opCode = inGenericValues.GetInt(PrivacyFiledConst::FIELD_OP_CODE); in TranslationGenericValuesIntoPermissionUsedRecord() local
58 if (!Constant::TransferOpcodeToPermission(opCode, permission)) { in TranslationGenericValuesIntoPermissionUsedRecord()
/base/security/device_auth/services/authenticators/src/account_unrelated/
Ddas_version_util.c155 ProtocolType GetPrototolType(VersionStruct *curVersion, OperationCode opCode) in GetPrototolType() argument
157 switch (opCode) { in GetPrototolType()
165 LOGE("Unsupported opCode: %d.", opCode); in GetPrototolType()
/base/security/device_auth/services/authenticators/src/account_unrelated/iso_task/iso_protocol_task/
Diso_client_protocol_task.c64 GOTO_ERR_AND_SET_RET(AddIntToJson(payload, FIELD_OPERATION_CODE, params->opCode), res); in IsoClientStartPackData()
67 if (params->opCode == AUTHENTICATE || params->opCode == OP_UNBIND) { in IsoClientStartPackData()
140 if (params->opCode == OP_BIND) { in ParseServerStartMessage()
269 res = ClientProtocolMessageOut(out, params->opCode, step); in Process()
/base/security/access_token/services/privacymanager/include/record/
Dpermission_record.h26 int32_t opCode = 0; member

12