• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2022-2023 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 /**
17  * @addtogroup Privacy
18  * @{
19  *
20  * @brief Provides sensitive data access management.
21  *
22  * @since 8.0
23  * @version 8.0
24  */
25 
26 /**
27  * @file privacy_error.h
28  *
29  * @brief Declares error codes.
30  *
31  * @since 8.0
32  * @version 8.0
33  */
34 
35 #ifndef INTERFACES_INNERKITS_PRIVACY_ERROR_H
36 #define INTERFACES_INNERKITS_PRIVACY_ERROR_H
37 namespace OHOS {
38 namespace Security {
39 namespace AccessToken {
40 /**
41  * @brief Error code values
42  */
43 enum PrivacyError {
44     ERR_PARAM_INVALID = 1,
45     ERR_SERVICE_ABNORMAL,
46     ERR_READ_PARCEL_FAILED,
47     ERR_WRITE_PARCEL_FAILED,
48     ERR_IPC_PARCEL_FAILED,
49     ERR_MALLOC_FAILED,
50     ERR_TOKENID_NOT_EXIST,
51     ERR_PERMISSION_NOT_EXIST,
52     ERR_CALLBACK_ALREADY_EXIST,
53     ERR_CALLBACK_NOT_EXIST,
54     ERR_CALLBACKS_EXCEED_LIMITATION,
55     ERR_PERMISSION_ALREADY_START_USING,
56     ERR_PERMISSION_NOT_START_USING,
57     ERR_PERMISSION_DENIED,
58     ERR_OVERSIZE,
59 #ifdef SECURITY_COMPONENT_ENHANCE_ENABLE
60     ERR_CALLBACK_REGIST_REDIRECT,
61 #endif
62     ERR_NOT_SYSTEM_APP = 202,
63 };
64 } // namespace AccessToken
65 } // namespace Security
66 } // namespace OHOS
67 #endif
68