mirror of
https://gitee.com/openharmony/useriam_user_auth_framework
synced 2024-11-23 07:39:51 +00:00
move ipc code to single .h file and add CODEOWNERS file
Signed-off-by: dengjiewen <dengjiewen1@huawei.com> Change-Id: I145b9a00e007e9918776fc09936cba099ac99fac
This commit is contained in:
parent
44811bf80d
commit
4c24a00762
29
CODEOWNERS
Normal file
29
CODEOWNERS
Normal file
@ -0,0 +1,29 @@
|
||||
# Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
#any change to frameworks/native/ipc/common_defines/co_auth_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/co_auth_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/executor_callback_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/executor_callback_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/executor_messenger_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/executor_messenger_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/idm_callback_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/idm_callback_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/idm_get_cred_info_callback_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/idm_get_cred_info_callback_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/idm_get_secure_user_info_callback_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/idm_get_secure_user_info_callback_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/user_auth_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/user_auth_interface_ipc_interface_code.h @leonchan5
|
||||
#any change to frameworks/native/ipc/common_defines/user_idm_interface_ipc_interface_code.h needs to be reviewed by @leonchan5
|
||||
frameworks/native/ipc/common_defines/user_idm_interface_ipc_interface_code.h @leonchan5
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2022-2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -21,6 +21,7 @@
|
||||
#include "executor_callback_interface.h"
|
||||
#include "iam_common_defines.h"
|
||||
|
||||
#include "co_auth_interface_ipc_interface_code.h"
|
||||
#include "iremote_broker.h"
|
||||
#include "refbase.h"
|
||||
|
||||
@ -29,11 +30,6 @@ namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class CoAuthInterface : public IRemoteBroker {
|
||||
public:
|
||||
/* Message ID */
|
||||
enum : uint32_t {
|
||||
CO_AUTH_EXECUTOR_REGISTER = 0,
|
||||
};
|
||||
|
||||
struct ExecutorRegisterInfo {
|
||||
AuthType authType;
|
||||
ExecutorRole executorRole;
|
||||
|
@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef CO_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define CO_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 931 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class CoAuthInterfaceCode {
|
||||
CO_AUTH_EXECUTOR_REGISTER = 0,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // CO_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2022-2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -21,19 +21,12 @@
|
||||
#include "iremote_broker.h"
|
||||
|
||||
#include "executor_messenger_interface.h"
|
||||
#include "executor_callback_interface_ipc_interface_code.h"
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class ExecutorCallbackInterface : public IRemoteBroker {
|
||||
public:
|
||||
/* Message ID */
|
||||
enum : uint32_t {
|
||||
ON_MESSENGER_READY = 1,
|
||||
ON_BEGIN_EXECUTE,
|
||||
ON_END_EXECUTE,
|
||||
ON_SET_PROPERTY,
|
||||
ON_GET_PROPERTY,
|
||||
};
|
||||
virtual void OnMessengerReady(sptr<ExecutorMessengerInterface> &messenger, const std::vector<uint8_t> &publicKey,
|
||||
const std::vector<uint64_t> &templateIdList) = 0;
|
||||
virtual int32_t OnBeginExecute(uint64_t scheduleId, const std::vector<uint8_t> &publicKey,
|
||||
|
@ -0,0 +1,33 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef EXECUTOR_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define EXECUTOR_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 931 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class ExecutorCallbackInterfaceCode {
|
||||
ON_MESSENGER_READY = 1,
|
||||
ON_BEGIN_EXECUTE,
|
||||
ON_END_EXECUTE,
|
||||
ON_SET_PROPERTY,
|
||||
ON_GET_PROPERTY,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // EXECUTOR_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -19,6 +19,7 @@
|
||||
#include "iremote_broker.h"
|
||||
|
||||
#include "attributes.h"
|
||||
#include "executor_messenger_interface_ipc_interface_code.h"
|
||||
#include "iam_common_defines.h"
|
||||
|
||||
namespace OHOS {
|
||||
@ -26,11 +27,6 @@ namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class ExecutorMessengerInterface : public IRemoteBroker {
|
||||
public:
|
||||
/* Message ID */
|
||||
enum : uint32_t {
|
||||
CO_AUTH_SEND_DATA = 0,
|
||||
CO_AUTH_FINISH,
|
||||
};
|
||||
virtual int32_t SendData(uint64_t scheduleId, uint64_t transNum, ExecutorRole srcRole, ExecutorRole dstRole,
|
||||
const std::vector<uint8_t> &msg) = 0;
|
||||
virtual int32_t Finish(uint64_t scheduleId, ExecutorRole srcRole, ResultCode resultCode,
|
||||
|
@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef EXECUTOR_MESSENGER_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define EXECUTOR_MESSENGER_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 931 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class ExecutorMessengerInterfaceCode {
|
||||
CO_AUTH_SEND_DATA = 0,
|
||||
CO_AUTH_FINISH,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // EXECUTOR_MESSENGER_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef IDM_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define IDM_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 901 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class IdmCallbackInterfaceCode{
|
||||
IDM_CALLBACK_ON_RESULT = 0,
|
||||
IDM_CALLBACK_ON_ACQUIRE_INFO,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // IDM_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef IDM_GET_CRED_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define IDM_GET_CRED_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 901 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class IdmGetCredInfoCallbackInterfaceCode{
|
||||
ON_GET_INFO = 0,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // IDM_GET_CRED_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef IDM_GET_SECURE_USER_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define IDM_GET_SECURE_USER_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 901 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class IdmGetSecureUserInfoCallbackInterfaceCode{
|
||||
ON_GET_SEC_INFO = 0,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // IDM_GET_SECURE_USER_INFO_CALLBACK_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2022-2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -24,30 +24,13 @@
|
||||
|
||||
#include "attributes.h"
|
||||
#include "user_auth_callback_interface.h"
|
||||
#include "user_auth_interface_ipc_interface_code.h"
|
||||
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class UserAuthInterface : public IRemoteBroker {
|
||||
public:
|
||||
/* Message ID */
|
||||
enum : uint32_t {
|
||||
USER_AUTH_GET_AVAILABLE_STATUS = 0,
|
||||
USER_AUTH_GET_PROPERTY,
|
||||
USER_AUTH_SET_PROPERTY,
|
||||
USER_AUTH_AUTH,
|
||||
USER_AUTH_AUTH_USER,
|
||||
USER_AUTH_CANCEL_AUTH,
|
||||
USER_AUTH_GET_VERSION,
|
||||
USER_AUTH_ON_RESULT,
|
||||
USER_AUTH_GET_EX_PROP,
|
||||
USER_AUTH_SET_EX_PROP,
|
||||
USER_AUTH_ACQUIRE_INFO,
|
||||
USER_AUTH_IDENTIFY,
|
||||
USER_AUTH_CANCEL_IDENTIFY,
|
||||
USER_AUTH_ON_IDENTIFY_RESULT,
|
||||
};
|
||||
|
||||
virtual int32_t GetAvailableStatus(int32_t apiVersion, AuthType authType, AuthTrustLevel authTrustLevel) = 0;
|
||||
|
||||
virtual void GetProperty(int32_t userId, AuthType authType,
|
||||
|
@ -0,0 +1,42 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef USER_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define USER_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 921 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class UserAuthInterfaceCode {
|
||||
USER_AUTH_GET_AVAILABLE_STATUS = 0,
|
||||
USER_AUTH_GET_PROPERTY,
|
||||
USER_AUTH_SET_PROPERTY,
|
||||
USER_AUTH_AUTH,
|
||||
USER_AUTH_AUTH_USER,
|
||||
USER_AUTH_CANCEL_AUTH,
|
||||
USER_AUTH_GET_VERSION,
|
||||
USER_AUTH_ON_RESULT,
|
||||
USER_AUTH_GET_EX_PROP,
|
||||
USER_AUTH_SET_EX_PROP,
|
||||
USER_AUTH_ACQUIRE_INFO,
|
||||
USER_AUTH_IDENTIFY,
|
||||
USER_AUTH_CANCEL_IDENTIFY,
|
||||
USER_AUTH_ON_IDENTIFY_RESULT,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // USER_AUTH_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -23,6 +23,9 @@
|
||||
#include "attributes.h"
|
||||
#include "iam_common_defines.h"
|
||||
#include "iam_callback_interface.h"
|
||||
#include "idm_callback_interface_ipc_interface_code.h"
|
||||
#include "idm_get_cred_info_callback_interface_ipc_interface_code.h"
|
||||
#include "idm_get_secure_user_info_callback_interface_ipc_interface_code.h"
|
||||
#include "user_idm_client_defines.h"
|
||||
|
||||
namespace OHOS {
|
||||
@ -30,10 +33,6 @@ namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class IdmGetCredInfoCallbackInterface : public IRemoteBroker {
|
||||
public:
|
||||
enum {
|
||||
ON_GET_INFO = 0,
|
||||
};
|
||||
|
||||
/*
|
||||
* return all registered credential information.
|
||||
*/
|
||||
@ -44,10 +43,6 @@ public:
|
||||
|
||||
class IdmGetSecureUserInfoCallbackInterface : public IRemoteBroker {
|
||||
public:
|
||||
enum {
|
||||
ON_GET_SEC_INFO = 0,
|
||||
};
|
||||
|
||||
/*
|
||||
* return all registered security information.
|
||||
*/
|
||||
@ -58,11 +53,6 @@ public:
|
||||
|
||||
class IdmCallbackInterface : public IamCallbackInterface {
|
||||
public:
|
||||
enum {
|
||||
IDM_CALLBACK_ON_RESULT = 0,
|
||||
IDM_CALLBACK_ON_ACQUIRE_INFO,
|
||||
};
|
||||
|
||||
DECLARE_INTERFACE_DESCRIPTOR(u"ohos.useridm.IIDMCallback");
|
||||
};
|
||||
} // namespace UserAuth
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2022-2023 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -20,25 +20,13 @@
|
||||
|
||||
#include "refbase.h"
|
||||
#include "user_idm_callback_interface.h"
|
||||
#include "user_idm_interface_ipc_interface_code.h"
|
||||
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
class UserIdmInterface : public IRemoteBroker {
|
||||
public:
|
||||
enum : uint32_t {
|
||||
USER_IDM_OPEN_SESSION = 0,
|
||||
USER_IDM_CLOSE_SESSION,
|
||||
USER_IDM_GET_CRED_INFO,
|
||||
USER_IDM_GET_SEC_INFO,
|
||||
USER_IDM_ADD_CREDENTIAL,
|
||||
USER_IDM_UPDATE_CREDENTIAL,
|
||||
USER_IDM_CANCEL,
|
||||
USER_IDM_ENFORCE_DEL_USER,
|
||||
USER_IDM_DEL_USER,
|
||||
USER_IDM_DEL_CRED,
|
||||
};
|
||||
|
||||
struct CredentialPara {
|
||||
AuthType authType {ALL};
|
||||
PinSubType pinType {PIN_SIX};
|
||||
|
@ -0,0 +1,38 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef USER_IDM_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
#define USER_IDM_INTERFACE_IPC_INTERFACE_CODE_H
|
||||
|
||||
/* SAID: 931 */
|
||||
namespace OHOS {
|
||||
namespace UserIam {
|
||||
namespace UserAuth {
|
||||
enum class UserIdmInterfaceCode {
|
||||
USER_IDM_OPEN_SESSION = 0,
|
||||
USER_IDM_CLOSE_SESSION,
|
||||
USER_IDM_GET_CRED_INFO,
|
||||
USER_IDM_GET_SEC_INFO,
|
||||
USER_IDM_ADD_CREDENTIAL,
|
||||
USER_IDM_UPDATE_CREDENTIAL,
|
||||
USER_IDM_CANCEL,
|
||||
USER_IDM_ENFORCE_DEL_USER,
|
||||
USER_IDM_DEL_USER,
|
||||
USER_IDM_DEL_CRED,
|
||||
};
|
||||
} // namespace UserAuth
|
||||
} // namespace UserIam
|
||||
} // namespace OHOS
|
||||
#endif // USER_IDM_INTERFACE_IPC_INTERFACE_CODE_H
|
@ -82,7 +82,7 @@ uint64_t CoAuthProxy::ExecutorRegister(const ExecutorRegisterInfo &info, sptr<Ex
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(CoAuthInterface::CO_AUTH_EXECUTOR_REGISTER, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(CoAuthInterfaceCode::CO_AUTH_EXECUTOR_REGISTER), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
return BAD_CONTEXT_ID;
|
||||
|
@ -35,7 +35,7 @@ int32_t CoAuthStub::OnRemoteRequest(uint32_t code, MessageParcel &data, MessageP
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
switch (code) {
|
||||
case CoAuthInterface::CO_AUTH_EXECUTOR_REGISTER:
|
||||
case static_cast<uint32_t>(CoAuthInterfaceCode::CO_AUTH_EXECUTOR_REGISTER):
|
||||
return ExecutorRegisterStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -51,7 +51,7 @@ void ExecutorCallbackProxy::OnMessengerReady(sptr<ExecutorMessengerInterface> &m
|
||||
return;
|
||||
}
|
||||
|
||||
bool result = SendRequest(ExecutorCallbackInterface::ON_MESSENGER_READY, data, reply);
|
||||
bool result = SendRequest(static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_MESSENGER_READY), data, reply);
|
||||
if (!result) {
|
||||
IAM_LOGE("send request failed");
|
||||
return;
|
||||
@ -82,7 +82,7 @@ int32_t ExecutorCallbackProxy::OnBeginExecute(uint64_t scheduleId, const std::ve
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorCallbackInterface::ON_BEGIN_EXECUTE, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_BEGIN_EXECUTE), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
return GENERAL_ERROR;
|
||||
@ -114,7 +114,7 @@ int32_t ExecutorCallbackProxy::OnEndExecute(uint64_t scheduleId, const Attribute
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorCallbackInterface::ON_END_EXECUTE, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_END_EXECUTE), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
return GENERAL_ERROR;
|
||||
@ -142,7 +142,7 @@ int32_t ExecutorCallbackProxy::OnSetProperty(const Attributes &properties)
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorCallbackInterface::ON_SET_PROPERTY, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_SET_PROPERTY), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
return GENERAL_ERROR;
|
||||
@ -170,7 +170,7 @@ int32_t ExecutorCallbackProxy::OnGetProperty(const Attributes &condition, Attrib
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorCallbackInterface::ON_GET_PROPERTY, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_GET_PROPERTY), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
return GENERAL_ERROR;
|
||||
|
@ -33,15 +33,15 @@ int32_t ExecutorCallbackStub::OnRemoteRequest(uint32_t code, MessageParcel &data
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
switch (code) {
|
||||
case ExecutorCallbackInterface::ON_MESSENGER_READY:
|
||||
case static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_MESSENGER_READY):
|
||||
return OnMessengerReadyStub(data, reply);
|
||||
case ExecutorCallbackInterface::ON_BEGIN_EXECUTE:
|
||||
case static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_BEGIN_EXECUTE):
|
||||
return OnBeginExecuteStub(data, reply);
|
||||
case ExecutorCallbackInterface::ON_END_EXECUTE:
|
||||
case static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_END_EXECUTE):
|
||||
return OnEndExecuteStub(data, reply);
|
||||
case ExecutorCallbackInterface::ON_SET_PROPERTY:
|
||||
case static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_SET_PROPERTY):
|
||||
return OnSetPropertyStub(data, reply);
|
||||
case ExecutorCallbackInterface::ON_GET_PROPERTY:
|
||||
case static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_GET_PROPERTY):
|
||||
return OnGetPropertyStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -58,7 +58,7 @@ int32_t ExecutorMessengerProxy::SendData(uint64_t scheduleId, uint64_t transNum,
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorMessengerInterface::CO_AUTH_SEND_DATA, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_SEND_DATA), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
return GENERAL_ERROR;
|
||||
@ -103,7 +103,7 @@ int32_t ExecutorMessengerProxy::Finish(uint64_t scheduleId, ExecutorRole srcRole
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ExecutorMessengerInterface::CO_AUTH_FINISH, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_FINISH), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
return GENERAL_ERROR;
|
||||
|
@ -36,9 +36,9 @@ int32_t ExecutorMessengerStub::OnRemoteRequest(uint32_t code, MessageParcel &dat
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
switch (code) {
|
||||
case ExecutorMessengerInterface::CO_AUTH_SEND_DATA:
|
||||
case static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_SEND_DATA):
|
||||
return SendDataStub(data, reply);
|
||||
case ExecutorMessengerInterface::CO_AUTH_FINISH:
|
||||
case static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_FINISH):
|
||||
return FinishStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -45,7 +45,7 @@ void UserAuthCallbackProxy::OnResult(int32_t result, const Attributes &extraInfo
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_ON_RESULT, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ON_RESULT), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
}
|
||||
@ -76,7 +76,7 @@ void UserAuthCallbackProxy::OnAcquireInfo(int32_t module, int32_t acquireInfo, c
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_ACQUIRE_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ACQUIRE_INFO), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
}
|
||||
@ -121,7 +121,7 @@ void GetExecutorPropertyCallbackProxy::OnGetExecutorPropertyResult(int32_t resul
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_GET_EX_PROP, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_EX_PROP), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
}
|
||||
@ -161,7 +161,7 @@ void SetExecutorPropertyCallbackProxy::OnSetExecutorPropertyResult(int32_t resul
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_SET_EX_PROP, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_EX_PROP), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("send request failed");
|
||||
}
|
||||
|
@ -35,9 +35,9 @@ int32_t UserAuthCallbackStub::OnRemoteRequest(uint32_t code, MessageParcel &data
|
||||
}
|
||||
|
||||
switch (code) {
|
||||
case UserAuthInterface::USER_AUTH_ON_RESULT:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ON_RESULT):
|
||||
return OnResultStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_ACQUIRE_INFO:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ACQUIRE_INFO):
|
||||
return OnAcquireInfoStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
@ -98,7 +98,7 @@ int32_t GetExecutorPropertyCallbackStub::OnRemoteRequest(uint32_t code, MessageP
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
if (code == UserAuthInterface::USER_AUTH_GET_EX_PROP) {
|
||||
if (code == static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_EX_PROP)) {
|
||||
return OnGetExecutorPropertyResultStub(data, reply);
|
||||
}
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
@ -133,7 +133,7 @@ int32_t SetExecutorPropertyCallbackStub::OnRemoteRequest(uint32_t code, MessageP
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
if (code == UserAuthInterface::USER_AUTH_SET_EX_PROP) {
|
||||
if (code == static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_EX_PROP)) {
|
||||
return OnSetExecutorPropertyResultStub(data, reply);
|
||||
}
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -56,7 +56,7 @@ int32_t UserAuthProxy::GetAvailableStatus(int32_t apiVersion, AuthType authType,
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_GET_AVAILABLE_STATUS, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_AVAILABLE_STATUS), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
@ -109,7 +109,7 @@ void UserAuthProxy::GetProperty(int32_t userId, AuthType authType,
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_GET_PROPERTY, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_PROPERTY), data, reply);
|
||||
if (!ret) {
|
||||
Attributes attr;
|
||||
callback->OnGetExecutorPropertyResult(GENERAL_ERROR, attr);
|
||||
@ -148,7 +148,7 @@ void UserAuthProxy::SetProperty(int32_t userId, AuthType authType, const Attribu
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_SET_PROPERTY, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_PROPERTY), data, reply);
|
||||
if (!ret) {
|
||||
callback->OnSetExecutorPropertyResult(GENERAL_ERROR);
|
||||
}
|
||||
@ -198,7 +198,7 @@ uint64_t UserAuthProxy::Auth(int32_t apiVersion, const std::vector<uint8_t> &cha
|
||||
IAM_LOGE("failed to write apiVersion");
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_AUTH, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH), data, reply);
|
||||
if (!ret) {
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
@ -232,7 +232,7 @@ uint64_t UserAuthProxy::AuthUser(int32_t userId, const std::vector<uint8_t> &cha
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_AUTH_USER, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH_USER), data, reply);
|
||||
if (!ret) {
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
@ -270,7 +270,7 @@ uint64_t UserAuthProxy::Identify(const std::vector<uint8_t> &challenge, AuthType
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_IDENTIFY, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_IDENTIFY), data, reply);
|
||||
if (!ret) {
|
||||
return BAD_CONTEXT_ID;
|
||||
}
|
||||
@ -295,7 +295,7 @@ int32_t UserAuthProxy::CancelAuthOrIdentify(uint64_t contextId)
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_CANCEL_AUTH, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_CANCEL_AUTH), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
@ -317,7 +317,7 @@ int32_t UserAuthProxy::GetVersion(int32_t &version)
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserAuthInterface::USER_AUTH_GET_VERSION, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_VERSION), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
@ -40,23 +40,23 @@ int32_t UserAuthStub::OnRemoteRequest(uint32_t code, MessageParcel &data, Messag
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
switch (code) {
|
||||
case UserAuthInterface::USER_AUTH_GET_AVAILABLE_STATUS:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_AVAILABLE_STATUS):
|
||||
return GetAvailableStatusStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_GET_PROPERTY:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_PROPERTY):
|
||||
return GetPropertyStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_SET_PROPERTY:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_PROPERTY):
|
||||
return SetPropertyStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_AUTH:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH):
|
||||
return AuthStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_AUTH_USER:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH_USER):
|
||||
return AuthUserStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_CANCEL_AUTH:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_CANCEL_AUTH):
|
||||
return CancelAuthOrIdentifyStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_IDENTIFY:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_IDENTIFY):
|
||||
return IdentifyStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_CANCEL_IDENTIFY:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_CANCEL_IDENTIFY):
|
||||
return CancelAuthOrIdentifyStub(data, reply);
|
||||
case UserAuthInterface::USER_AUTH_GET_VERSION:
|
||||
case static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_VERSION):
|
||||
return GetVersionStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -45,7 +45,7 @@ void IdmCallbackProxy::OnResult(int32_t result, const Attributes &extraInfo)
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(IDM_CALLBACK_ON_RESULT, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_RESULT), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
}
|
||||
@ -76,7 +76,7 @@ void IdmCallbackProxy::OnAcquireInfo(int32_t module, int32_t acquireInfo, const
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(IDM_CALLBACK_ON_ACQUIRE_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_ACQUIRE_INFO), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
}
|
||||
@ -135,7 +135,7 @@ void IdmGetCredentialInfoProxy::OnCredentialInfos(const std::vector<CredentialIn
|
||||
}
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ON_GET_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(IdmGetCredInfoCallbackInterfaceCode::ON_GET_INFO), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
}
|
||||
@ -202,7 +202,7 @@ void IdmGetSecureUserInfoProxy::OnSecureUserInfo(const SecUserInfo &secUserInfo)
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(ON_GET_SEC_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(IdmGetSecureUserInfoCallbackInterfaceCode::ON_GET_SEC_INFO), data, reply);
|
||||
if (!ret) {
|
||||
IAM_LOGE("failed to send request");
|
||||
}
|
||||
|
@ -38,9 +38,9 @@ int32_t IdmCallbackStub::OnRemoteRequest(uint32_t code, MessageParcel &data, Mes
|
||||
}
|
||||
|
||||
switch (code) {
|
||||
case IdmCallbackInterface::IDM_CALLBACK_ON_RESULT:
|
||||
case static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_RESULT):
|
||||
return OnResultStub(data, reply);
|
||||
case IdmCallbackInterface::IDM_CALLBACK_ON_ACQUIRE_INFO:
|
||||
case static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_ACQUIRE_INFO):
|
||||
return OnAcquireInfoStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
@ -101,7 +101,7 @@ int32_t IdmGetCredInfoCallbackStub::OnRemoteRequest(uint32_t code, MessageParcel
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
if (code == IdmGetCredInfoCallbackInterface::ON_GET_INFO) {
|
||||
if (code == static_cast<uint32_t>(IdmGetCredInfoCallbackInterfaceCode::ON_GET_INFO)) {
|
||||
return OnCredentialInfosStub(data, reply);
|
||||
}
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
@ -169,7 +169,7 @@ int32_t IdmGetSecureUserInfoCallbackStub::OnRemoteRequest(uint32_t code, Message
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
|
||||
if (code == IdmGetSecureUserInfoCallbackInterface::ON_GET_SEC_INFO) {
|
||||
if (code == static_cast<uint32_t>(IdmGetSecureUserInfoCallbackInterfaceCode::ON_GET_SEC_INFO)) {
|
||||
return OnSecureUserInfoStub(data, reply);
|
||||
}
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -42,7 +42,7 @@ int32_t UserIdmProxy::OpenSession(int32_t userId, std::vector<uint8_t> &challeng
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_OPEN_SESSION, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_OPEN_SESSION), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
@ -67,7 +67,7 @@ void UserIdmProxy::CloseSession(int32_t userId)
|
||||
return;
|
||||
}
|
||||
|
||||
SendRequest(UserIdmInterface::USER_IDM_CLOSE_SESSION, data, reply);
|
||||
SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CLOSE_SESSION), data, reply);
|
||||
}
|
||||
|
||||
int32_t UserIdmProxy::GetCredentialInfo(int32_t userId, AuthType authType,
|
||||
@ -97,7 +97,7 @@ int32_t UserIdmProxy::GetCredentialInfo(int32_t userId, AuthType authType,
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_GET_CRED_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_CRED_INFO), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
@ -130,7 +130,7 @@ int32_t UserIdmProxy::GetSecInfo(int32_t userId, const sptr<IdmGetSecureUserInfo
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_GET_SEC_INFO, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_SEC_INFO), data, reply);
|
||||
if (!ret) {
|
||||
SecUserInfo secUserInfo = {};
|
||||
callback->OnSecureUserInfo(secUserInfo);
|
||||
@ -178,7 +178,7 @@ void UserIdmProxy::AddCredential(int32_t userId, const CredentialPara &credPara,
|
||||
return;
|
||||
}
|
||||
|
||||
SendRequest(UserIdmInterface::USER_IDM_ADD_CREDENTIAL, data, reply);
|
||||
SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ADD_CREDENTIAL), data, reply);
|
||||
}
|
||||
|
||||
void UserIdmProxy::UpdateCredential(int32_t userId, const CredentialPara &credPara,
|
||||
@ -216,7 +216,7 @@ void UserIdmProxy::UpdateCredential(int32_t userId, const CredentialPara &credPa
|
||||
return;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_UPDATE_CREDENTIAL, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_UPDATE_CREDENTIAL), data, reply);
|
||||
if (!ret) {
|
||||
Attributes extraInfo;
|
||||
callback->OnResult(GENERAL_ERROR, extraInfo);
|
||||
@ -237,7 +237,7 @@ int32_t UserIdmProxy::Cancel(int32_t userId)
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_CANCEL, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CANCEL), data, reply);
|
||||
if (!ret) {
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
@ -270,7 +270,7 @@ int32_t UserIdmProxy::EnforceDelUser(int32_t userId, const sptr<IdmCallbackInter
|
||||
return WRITE_PARCEL_ERROR;
|
||||
}
|
||||
|
||||
bool ret = SendRequest(UserIdmInterface::USER_IDM_ENFORCE_DEL_USER, data, reply);
|
||||
bool ret = SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ENFORCE_DEL_USER), data, reply);
|
||||
if (!ret) {
|
||||
Attributes attr;
|
||||
callback->OnResult(GENERAL_ERROR, attr);
|
||||
@ -310,7 +310,7 @@ void UserIdmProxy::DelUser(int32_t userId, const std::vector<uint8_t> authToken,
|
||||
return;
|
||||
}
|
||||
|
||||
SendRequest(UserIdmInterface::USER_IDM_DEL_USER, data, reply);
|
||||
SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_USER), data, reply);
|
||||
}
|
||||
|
||||
void UserIdmProxy::DelCredential(int32_t userId, uint64_t credentialId,
|
||||
@ -344,7 +344,7 @@ void UserIdmProxy::DelCredential(int32_t userId, uint64_t credentialId,
|
||||
return;
|
||||
}
|
||||
|
||||
SendRequest(UserIdmInterface::USER_IDM_DEL_CRED, data, reply);
|
||||
SendRequest(static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_CRED), data, reply);
|
||||
}
|
||||
|
||||
bool UserIdmProxy::SendRequest(uint32_t code, MessageParcel &data, MessageParcel &reply)
|
||||
|
@ -36,25 +36,25 @@ int32_t UserIdmStub::OnRemoteRequest(uint32_t code, MessageParcel &data, Message
|
||||
}
|
||||
|
||||
switch (code) {
|
||||
case USER_IDM_OPEN_SESSION:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_OPEN_SESSION):
|
||||
return OpenSessionStub(data, reply);
|
||||
case USER_IDM_CLOSE_SESSION:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CLOSE_SESSION):
|
||||
return CloseSessionStub(data, reply);
|
||||
case USER_IDM_GET_CRED_INFO:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_CRED_INFO):
|
||||
return GetCredentialInfoStub(data, reply);
|
||||
case USER_IDM_GET_SEC_INFO:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_SEC_INFO):
|
||||
return GetSecInfoStub(data, reply);
|
||||
case USER_IDM_ADD_CREDENTIAL:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ADD_CREDENTIAL):
|
||||
return AddCredentialStub(data, reply);
|
||||
case USER_IDM_UPDATE_CREDENTIAL:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_UPDATE_CREDENTIAL):
|
||||
return UpdateCredentialStub(data, reply);
|
||||
case USER_IDM_CANCEL:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CANCEL):
|
||||
return CancelStub(data, reply);
|
||||
case USER_IDM_ENFORCE_DEL_USER:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ENFORCE_DEL_USER):
|
||||
return EnforceDelUserStub(data, reply);
|
||||
case USER_IDM_DEL_USER:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_USER):
|
||||
return DelUserStub(data, reply);
|
||||
case USER_IDM_DEL_CRED:
|
||||
case static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_CRED):
|
||||
return DelCredentialStub(data, reply);
|
||||
default:
|
||||
return IPCObjectStub::OnRemoteRequest(code, data, reply, option);
|
||||
|
@ -63,7 +63,7 @@ HWTEST_F(ExecutorCallbackProxyTest, TestOnMessengerReady_002, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_MESSENGER_READY);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_MESSENGER_READY));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
@ -85,7 +85,7 @@ HWTEST_F(ExecutorCallbackProxyTest, TestOnBeginExecute_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_BEGIN_EXECUTE);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_BEGIN_EXECUTE));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
@ -108,7 +108,7 @@ HWTEST_F(ExecutorCallbackProxyTest, TestOnEndExecute_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_END_EXECUTE);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_END_EXECUTE));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
@ -129,7 +129,7 @@ HWTEST_F(ExecutorCallbackProxyTest, TestOnSetProperty_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_SET_PROPERTY);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_SET_PROPERTY));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
@ -150,14 +150,14 @@ HWTEST_F(ExecutorCallbackProxyTest, TestOnGetProperty_001, TestSize.Level0)
|
||||
.Times(2)
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_GET_PROPERTY);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_GET_PROPERTY));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
)
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorCallbackInterface::ON_GET_PROPERTY);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_GET_PROPERTY));
|
||||
return GENERAL_ERROR;
|
||||
}
|
||||
);
|
||||
|
@ -53,7 +53,7 @@ HWTEST_F(ExecutorCallbackStubTest, TestOnMessengerReadyStub_001, TestSize.Level0
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorCallbackInterface::ON_MESSENGER_READY;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_MESSENGER_READY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteRemoteObject(messenger->AsObject()));
|
||||
@ -76,7 +76,7 @@ HWTEST_F(ExecutorCallbackStubTest, TestOnBeginExecuteStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorCallbackInterface::ON_BEGIN_EXECUTE;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_BEGIN_EXECUTE);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(scheduleId));
|
||||
@ -98,7 +98,7 @@ HWTEST_F(ExecutorCallbackStubTest, TestOnEndExecuteStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorCallbackInterface::ON_END_EXECUTE;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_END_EXECUTE);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(scheduleId));
|
||||
@ -118,7 +118,7 @@ HWTEST_F(ExecutorCallbackStubTest, TestOnSetPropertyStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorCallbackInterface::ON_SET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_SET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUInt8Vector(properties));
|
||||
@ -137,7 +137,7 @@ HWTEST_F(ExecutorCallbackStubTest, TestOnGetPropertyStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorCallbackInterface::ON_GET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorCallbackInterfaceCode::ON_GET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUInt8Vector(condition));
|
||||
|
@ -48,7 +48,7 @@ HWTEST_F(ExecutorMessengerProxyTest, TestSendData_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorMessengerInterface::CO_AUTH_SEND_DATA);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_SEND_DATA));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
@ -86,7 +86,7 @@ HWTEST_F(ExecutorMessengerProxyTest, TestFinish_002, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, ExecutorMessengerInterface::CO_AUTH_FINISH);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_FINISH));
|
||||
EXPECT_TRUE(reply.WriteInt32(SUCCESS));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
|
@ -53,7 +53,7 @@ HWTEST_F(ExecutorMessengerStubTest, TestSendDataStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorMessengerInterface::CO_AUTH_SEND_DATA;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_SEND_DATA);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorMessengerInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(scheduleId));
|
||||
@ -79,7 +79,7 @@ HWTEST_F(ExecutorMessengerStubTest, TestFinishStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = ExecutorMessengerInterface::CO_AUTH_FINISH;
|
||||
uint32_t code = static_cast<uint32_t>(ExecutorMessengerInterfaceCode::CO_AUTH_FINISH);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(ExecutorMessengerInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(scheduleId));
|
||||
|
@ -49,7 +49,7 @@ HWTEST_F(UserAuthCallbackProxyTest, TestOnResult_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, UserAuthInterface::USER_AUTH_ON_RESULT);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ON_RESULT));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
@ -69,7 +69,7 @@ HWTEST_F(UserAuthCallbackProxyTest, TestOnAcquireInfo_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, UserAuthInterface::USER_AUTH_ACQUIRE_INFO);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ACQUIRE_INFO));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
@ -90,7 +90,7 @@ HWTEST_F(UserAuthCallbackProxyTest, TestOnGetExecutorPropertyResult_001, TestSiz
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, UserAuthInterface::USER_AUTH_GET_EX_PROP);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_EX_PROP));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
@ -110,7 +110,7 @@ HWTEST_F(UserAuthCallbackProxyTest, TestOnSetExecutorPropertyResult_001, TestSiz
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, UserAuthInterface::USER_AUTH_SET_EX_PROP);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_EX_PROP));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
|
@ -51,7 +51,7 @@ HWTEST_F(UserAuthCallbackStubTest, TestOnResultStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_ON_RESULT;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ON_RESULT);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(result));
|
||||
@ -73,7 +73,7 @@ HWTEST_F(UserAuthCallbackStubTest, TestOnAcquireInfoStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_ACQUIRE_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_ACQUIRE_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(module));
|
||||
@ -95,7 +95,7 @@ HWTEST_F(UserAuthCallbackStubTest, TestOnGetExecutorPropertyResultStub_001, Test
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_EX_PROP;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_EX_PROP);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(GetExecutorPropertyCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(result));
|
||||
@ -115,7 +115,7 @@ HWTEST_F(UserAuthCallbackStubTest, TestOnSetExecutorPropertyResultStub_001, Test
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_SET_EX_PROP;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_EX_PROP);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(SetExecutorPropertyCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(result));
|
||||
|
@ -49,7 +49,7 @@ HWTEST_F(UserIdmCallbackProxyTest, TestOnResult_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, IdmCallbackInterface::IDM_CALLBACK_ON_RESULT);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_RESULT));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
@ -69,7 +69,7 @@ HWTEST_F(UserIdmCallbackProxyTest, TestOnAcquireInfo_001, TestSize.Level0)
|
||||
EXPECT_CALL(*obj, SendRequest(_, _, _, _))
|
||||
.WillOnce(
|
||||
[](uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) {
|
||||
EXPECT_EQ(code, IdmCallbackInterface::IDM_CALLBACK_ON_ACQUIRE_INFO);
|
||||
EXPECT_EQ(code, static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_ACQUIRE_INFO));
|
||||
return OHOS::NO_ERROR;
|
||||
}
|
||||
);
|
||||
|
@ -50,7 +50,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnResultStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmCallbackInterface::IDM_CALLBACK_ON_RESULT;
|
||||
uint32_t code = static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_RESULT);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(result));
|
||||
@ -72,7 +72,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnAcquireInfoStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmCallbackInterface::IDM_CALLBACK_ON_ACQUIRE_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(IdmCallbackInterfaceCode::IDM_CALLBACK_ON_ACQUIRE_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(module));
|
||||
@ -91,7 +91,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnCredentialInfosStub_001, TestSize.Level0
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmGetCredInfoCallbackInterface::ON_GET_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(IdmGetCredInfoCallbackInterfaceCode::ON_GET_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmGetCredInfoCallbackInterface::GetDescriptor()));
|
||||
|
||||
@ -112,7 +112,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnCredentialInfosStub_002, TestSize.Level0
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmGetCredInfoCallbackInterface::ON_GET_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(IdmGetCredInfoCallbackInterfaceCode::ON_GET_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmGetCredInfoCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint32(1000));
|
||||
@ -134,7 +134,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnSecureUserInfoStub_001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmGetSecureUserInfoCallbackInterface::ON_GET_SEC_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(IdmGetSecureUserInfoCallbackInterfaceCode::ON_GET_SEC_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmGetSecureUserInfoCallbackInterface::GetDescriptor()));
|
||||
auto service = Common::MakeShared<MockIdmGetSecureUserInfoCallbackService>();
|
||||
@ -155,7 +155,7 @@ HWTEST_F(UserIdmCallbackStubTest, TestOnSecureUserInfoStub_002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = IdmGetSecureUserInfoCallbackInterface::ON_GET_SEC_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(IdmGetSecureUserInfoCallbackInterfaceCode::ON_GET_SEC_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(IdmGetSecureUserInfoCallbackInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(20));
|
||||
|
@ -82,7 +82,7 @@ HWTEST_F(CoAuthStubTest, CoAuthStubTestExecutorRegister001, TestSize.Level0)
|
||||
EXPECT_TRUE(data.WriteUInt8Vector(testInfo.publicKey));
|
||||
EXPECT_NE(callback->AsObject(), nullptr);
|
||||
EXPECT_TRUE(data.WriteRemoteObject(callback->AsObject()));
|
||||
uint32_t code = CoAuthInterface::CO_AUTH_EXECUTOR_REGISTER;
|
||||
uint32_t code = static_cast<uint32_t>(CoAuthInterfaceCode::CO_AUTH_EXECUTOR_REGISTER);
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
|
||||
EXPECT_EQ(SUCCESS, service.OnRemoteRequest(code, data, reply, option));
|
||||
@ -96,7 +96,7 @@ HWTEST_F(CoAuthStubTest, CoAuthStubTestExecutorRegister002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
|
||||
uint32_t code = CoAuthInterface::CO_AUTH_EXECUTOR_REGISTER;
|
||||
uint32_t code = static_cast<uint32_t>(CoAuthInterfaceCode::CO_AUTH_EXECUTOR_REGISTER);
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
|
||||
MockCoAuthService service;
|
||||
@ -109,7 +109,7 @@ HWTEST_F(CoAuthStubTest, CoAuthStubTestExecutorRegister003, TestSize.Level0)
|
||||
MessageParcel reply;
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(CoAuthInterface::GetDescriptor()));
|
||||
uint32_t code = CoAuthInterface::CO_AUTH_EXECUTOR_REGISTER;
|
||||
uint32_t code = static_cast<uint32_t>(CoAuthInterfaceCode::CO_AUTH_EXECUTOR_REGISTER);
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
|
||||
MockCoAuthService service;
|
||||
|
@ -46,7 +46,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubGetAvailableStatusStub001, TestSize.Level
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_AVAILABLE_STATUS;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_AVAILABLE_STATUS);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -75,7 +75,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubGetAvailableStatusStub002, TestSize.Level
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_AVAILABLE_STATUS;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_AVAILABLE_STATUS);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testAuthType));
|
||||
@ -93,7 +93,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubGetPropertyStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -134,7 +134,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubGetPropertyStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -151,7 +151,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubSetPropertyStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_SET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -191,7 +191,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubSetPropertyStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_SET_PROPERTY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_SET_PROPERTY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -208,7 +208,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubAuthStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_AUTH;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -249,7 +249,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubAuthStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_AUTH;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUInt8Vector(testChallenge));
|
||||
@ -270,7 +270,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubAuthUserStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_AUTH_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -311,7 +311,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubAuthUserStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_AUTH_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_AUTH_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -332,7 +332,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubIdentifyStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_IDENTIFY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_IDENTIFY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -368,7 +368,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubIdentifyStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_IDENTIFY;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_IDENTIFY);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUInt8Vector(testChallenge));
|
||||
@ -387,7 +387,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubCancelAuthOrIdentifyStub001, TestSize.Lev
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_CANCEL_AUTH;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_CANCEL_AUTH);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
@ -412,7 +412,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubCancelAuthOrIdentifyStub002, TestSize.Lev
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_CANCEL_AUTH;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_CANCEL_AUTH);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteUint64(testContextId));
|
||||
@ -440,7 +440,7 @@ HWTEST_F(UserAuthStubTest, UserAuthStubGetVersionStub, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserAuthInterface::USER_AUTH_GET_VERSION;
|
||||
uint32_t code = static_cast<uint32_t>(UserAuthInterfaceCode::USER_AUTH_GET_VERSION);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserAuthInterface::GetDescriptor()));
|
||||
|
||||
|
@ -52,7 +52,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubOpenSessionStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_OPEN_SESSION;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_OPEN_SESSION);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -79,7 +79,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubOpenSessionStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_OPEN_SESSION;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_OPEN_SESSION);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -96,7 +96,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubCloseSessionStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_CLOSE_SESSION;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CLOSE_SESSION);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -121,7 +121,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubCloseSessionStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_CLOSE_SESSION;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CLOSE_SESSION);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -134,7 +134,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubGetCredentialInfoStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_GET_CRED_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_CRED_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -169,7 +169,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubGetCredentialInfoStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_GET_CRED_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_CRED_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -189,7 +189,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubGetSecInfoStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_GET_SEC_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_SEC_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -221,7 +221,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubGetSecInfoStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_GET_SEC_INFO;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_GET_SEC_INFO);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -240,7 +240,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubAddCredentialStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_ADD_CREDENTIAL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ADD_CREDENTIAL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -279,7 +279,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubAddCredentialStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_ADD_CREDENTIAL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ADD_CREDENTIAL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -297,7 +297,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubUpdateCredentialStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_UPDATE_CREDENTIAL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_UPDATE_CREDENTIAL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -336,7 +336,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubUpdateCredentialStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_UPDATE_CREDENTIAL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_UPDATE_CREDENTIAL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -354,7 +354,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubCancelStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_CANCEL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CANCEL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -379,7 +379,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubCancelStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_CANCEL;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_CANCEL);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -396,7 +396,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubEnforceDelUserStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_ENFORCE_DEL_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ENFORCE_DEL_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -428,7 +428,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubEnforceDelUserStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_ENFORCE_DEL_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_ENFORCE_DEL_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -447,7 +447,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubDelUserStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_DEL_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -481,7 +481,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubDelUserStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_DEL_USER;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_USER);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
@ -497,7 +497,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubDelCredentialStub001, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_DEL_CRED;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_CRED);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
|
||||
@ -533,7 +533,7 @@ HWTEST_F(UserIdmStubTest, UserIdmStubDelCredentialStub002, TestSize.Level0)
|
||||
MessageParcel data;
|
||||
MessageParcel reply;
|
||||
MessageOption option(MessageOption::TF_SYNC);
|
||||
uint32_t code = UserIdmInterface::USER_IDM_DEL_CRED;
|
||||
uint32_t code = static_cast<uint32_t>(UserIdmInterfaceCode::USER_IDM_DEL_CRED);
|
||||
|
||||
EXPECT_TRUE(data.WriteInterfaceToken(UserIdmInterface::GetDescriptor()));
|
||||
EXPECT_TRUE(data.WriteInt32(testUserId));
|
||||
|
Loading…
Reference in New Issue
Block a user