From f4476ff9927b479f47693c6e34d008647ca618f4 Mon Sep 17 00:00:00 2001 From: wangyongzhong2 Date: Thu, 8 Aug 2024 15:57:56 +0800 Subject: [PATCH 1/2] add ndk Signed-off-by: wangyongzhong2 --- DataProtectionKit/BUILD.gn | 28 +++ DataProtectionKit/dlp_permission_api.h | 229 +++++++++++++++++++++ DataProtectionKit/libdlpperission.ndk.json | 30 +++ 3 files changed, 287 insertions(+) create mode 100644 DataProtectionKit/BUILD.gn create mode 100644 DataProtectionKit/dlp_permission_api.h create mode 100644 DataProtectionKit/libdlpperission.ndk.json diff --git a/DataProtectionKit/BUILD.gn b/DataProtectionKit/BUILD.gn new file mode 100644 index 000000000..e19b22195 --- /dev/null +++ b/DataProtectionKit/BUILD.gn @@ -0,0 +1,28 @@ +# Copyright (C) 2024 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. + +import("//build/ohos.gni") +import("//build/ohos/ndk/ndk.gni") + +ohos_ndk_headers("dlppermission_capi_header") { + dest_dir = "$ndk_headers_out_dir/DataProtectionKit" + sources = [ "./dlp_permission_api.h" ] +} + +ohos_ndk_library("libohdlp_permission") { + output_name = "ohdlp_permission" + output_extension = "so" + ndk_description_file = "./libdlppermission.ndk.json" + system_capability = "SystemCapability.Security.DataLossPrevention" + system_capability_headers = [ "DataProtectionKit/dlp_permission_api.h" ] +} \ No newline at end of file diff --git a/DataProtectionKit/dlp_permission_api.h b/DataProtectionKit/dlp_permission_api.h new file mode 100644 index 000000000..845bcf550 --- /dev/null +++ b/DataProtectionKit/dlp_permission_api.h @@ -0,0 +1,229 @@ +/* + * Copyright (c) 2024 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. + */ + +/** + * @addtogroup DlpPermissionApi + * @{ + * + * @brief Provides the capability to access the data loss prevention (DLP) files. + * + * @since 12 + */ + +/** + * @file dlp_permission_api.h + * + * @brief Declares the APIs for accessing the data loss prevention (DLP) files. + * + * @library libohdlp_permission.so + * @kit DataProtectionKit + * @syscap SystemCapability.Security.DataLossPrevention + * @since 12 + */ + +#ifndef DLP_PERMISSION_API_H +#define DLP_PERMISSION_API_H + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @brief Enumerates the error codes. + * + * @since 12 + */ +typedef enum { + /** The operation is successful. */ + ERR_OH_SUCCESS = 0, + /** Invalid parameter value. */ + ERR_OH_INVALID_PARAMETER = 19100001, + /** No permission to call this API, which is available only for DLP sandbox applications. */ + ERR_OH_API_ONLY_FOR_SANDBOX_ERROR = 19100006, + /** No permission to call this API, which is available only for non-DLP sandbox applications. */ + ERR_OH_API_NOT_FOR_SANDBOX_ERROR = 19100007, + /** The system ability works abnormally. */ + ERR_OH_SYSTEM_SERVICE_EXCEPTION = 19100011, + /** Indicates the memory error. */ + ERR_OH_OUT_OF_MEMORY = 19100012, + /** DisplayName missing in want. */ + ERR_OH_APPLICATION_NOT_AUTHORIZED = 19100018 +} OH_DLPPermission_ErrCode; + +/** + * @brief Enumerates the access permissions for a DLP file. + * + * @since 12 + */ +typedef enum { + /** No permission. */ + NO_PERMISSION = 0, + /** Read-only. */ + READ_ONLY = 1, + /** Edit. */ + CONTENT_EDIT = 2, + /** Full control. */ + FULL_CONTROL = 3 +} OH_DLPFileAccess; + +/** + * @brief Enumerates the actions allowed for the DLP file. + * + * @since 12 + */ +typedef enum { + /** Invalid. */ + ACTION_INVALID = 0, + /** View. */ + ACTION_VIEW = 1, + /** Save. */ + ACTION_SAVE = 1 << 1, + /** Save as. */ + ACTION_SAVE_AS = 1 << 2, + /** Edit. */ + ACTION_EDIT = 1 << 3, + /** Screen capture. */ + ACTION_SCREEN_CAPTURE = 1 << 4, + /** Screen share. */ + ACTION_SCREEN_SHARE = 1 << 5, + /** Screen record. */ + ACTION_SCREEN_RECORD = 1 << 6, + /** Copy. */ + ACTION_COPY = 1 << 7, + /** Print. */ + ACTION_PRINT = 1 << 8, + /** Export. */ + ACTION_EXPORT = 1 << 9, + /** Permission change. */ + ACTION_PERMISSION_CHANGE = 1 << 10 +} OH_ActionFlags; + +/** + * @brief Represents the permission info of a DLP file. + * + * @since 12 + */ +typedef struct { + /** + * Access permission for the DLP file. + */ + OH_DLPFileAccess dlpFileAccess; + /** + * Actions allowed for the DLP file. + */ + OH_ActionFlags flags; +} OH_DLPPermissionInfo; + +/** + * @brief Obtains the permission info of this DLP file. + * + * @param info - Indicates output parameter about {@link OH_DLPPermissionInfo}. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. + * {@link OH_DLPPermission_ErrCode#ERR_OH_API_ONLY_FOR_SANDBOX_ERROR} 19100006 - If No permission to + * call this API, which is available only for DLP sandbox applications. + * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * works abnormally. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_GetDLPPermissionInfo(OH_DLPPermissionInfo *info); + +/** + * @brief Obtains the original file name from a DLP file name. + * This method removes the DLP file name extension from the DLP file name. + * + * @param fileName - Indicates the DLP file name. + * @param originalFileName - Indicates the original file name obtained. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMS} 19100001 - If the parameter value is invalid. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_GetOriginalFileName(const char *fileName, char *originalFileName); + +/** + * @brief Obtains the original file name from a DLP file name. + * This method removes the DLP file name extension from the DLP file name. + * + * @param fileName - Indicates the DLP file name. + * @param suffixFileName - Indicates the suffix file name obtained. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_GetDLPSuffix(char *suffixFileName); + +/** + * @brief Checks whether current application is in the DLP sandbox. This method uses a promise to return the result. + * + * @param isInSandbox - Indicates output parameter; + {@code true} if current application is in a DLP sandbox, {@code false} otherwise. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * works abnormally. + * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_IsInSandbox(bool *isInSandbox); + +/** + * @brief Sets sandbox application configuration. This method uses a promise to return the result. + * + * @param configInfo - Configuration of the sandbox application. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. + * {@link OH_DLPPermission_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to + * call this API, which is available only for non-DLP sandbox applications. + * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * works abnormally. + * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_SetSandboxAppConfig(const char *configInfo); + +/** + * @brief Obtains sandbox application configuration. This method uses a promise to return the result. + * + * @param configInfo - Configuration of the sandbox application. + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * works abnormally. + * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_GetSandboxAppConfig(char *configInfo); + +/** + * @brief Cleans sandbox application configuration. This method uses a promise to return the result. + * + * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link OH_DLPPermission_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to + * call this API, which is available only for non-DLP sandbox applications. + * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * works abnormally. + * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * @since 12 + */ +OH_DLPPermission_ErrCode OH_DLPPermission_CleanSandboxAppConfig(); + +#ifdef __cplusplus +} +#endif + +/** @} */ +#endif /* DLP_PERMISSION_API_H */ \ No newline at end of file diff --git a/DataProtectionKit/libdlpperission.ndk.json b/DataProtectionKit/libdlpperission.ndk.json new file mode 100644 index 000000000..f978d457c --- /dev/null +++ b/DataProtectionKit/libdlpperission.ndk.json @@ -0,0 +1,30 @@ +[ + { + "first_introduced": "12", + "name": "OH_DLPPermission_GetDLPPermissionInfo" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_GetOriginalFileName" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_GetDLPSuffix" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_IsInSandbox" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_SetSandboxAppConfig" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_GetSandboxAppConfig" + }, + { + "first_introduced": "12", + "name": "OH_DLPPermission_CleanSandboxAppConfig" + } +] \ No newline at end of file -- Gitee From df94a3f80c642462910b149cf73e87e595063e2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E6=B0=B8=E5=BF=A0?= Date: Sat, 10 Aug 2024 06:53:59 +0000 Subject: [PATCH 2/2] add MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 王永忠 --- DataProtectionKit/dlp_permission_api.h | 106 +++++++-------------- DataProtectionKit/libdlpperission.ndk.json | 14 +-- 2 files changed, 44 insertions(+), 76 deletions(-) diff --git a/DataProtectionKit/dlp_permission_api.h b/DataProtectionKit/dlp_permission_api.h index 845bcf550..88eca0441 100644 --- a/DataProtectionKit/dlp_permission_api.h +++ b/DataProtectionKit/dlp_permission_api.h @@ -63,7 +63,7 @@ typedef enum { ERR_OH_OUT_OF_MEMORY = 19100012, /** DisplayName missing in want. */ ERR_OH_APPLICATION_NOT_AUTHORIZED = 19100018 -} OH_DLPPermission_ErrCode; +} DLP_ErrCode; /** * @brief Enumerates the access permissions for a DLP file. @@ -79,39 +79,7 @@ typedef enum { CONTENT_EDIT = 2, /** Full control. */ FULL_CONTROL = 3 -} OH_DLPFileAccess; - -/** - * @brief Enumerates the actions allowed for the DLP file. - * - * @since 12 - */ -typedef enum { - /** Invalid. */ - ACTION_INVALID = 0, - /** View. */ - ACTION_VIEW = 1, - /** Save. */ - ACTION_SAVE = 1 << 1, - /** Save as. */ - ACTION_SAVE_AS = 1 << 2, - /** Edit. */ - ACTION_EDIT = 1 << 3, - /** Screen capture. */ - ACTION_SCREEN_CAPTURE = 1 << 4, - /** Screen share. */ - ACTION_SCREEN_SHARE = 1 << 5, - /** Screen record. */ - ACTION_SCREEN_RECORD = 1 << 6, - /** Copy. */ - ACTION_COPY = 1 << 7, - /** Print. */ - ACTION_PRINT = 1 << 8, - /** Export. */ - ACTION_EXPORT = 1 << 9, - /** Permission change. */ - ACTION_PERMISSION_CHANGE = 1 << 10 -} OH_ActionFlags; +} DLP_FileAccess; /** * @brief Represents the permission info of a DLP file. @@ -122,26 +90,26 @@ typedef struct { /** * Access permission for the DLP file. */ - OH_DLPFileAccess dlpFileAccess; + DLP_FileAccess dlpFileAccess; /** * Actions allowed for the DLP file. */ - OH_ActionFlags flags; -} OH_DLPPermissionInfo; + uint32_t flags; +} DLP_PermissionInfo; /** * @brief Obtains the permission info of this DLP file. * - * @param info - Indicates output parameter about {@link OH_DLPPermissionInfo}. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. - * {@link OH_DLPPermission_ErrCode#ERR_OH_API_ONLY_FOR_SANDBOX_ERROR} 19100006 - If No permission to + * @param info - Indicates output parameter about {@link DLP_PermissionInfo}. + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. + * {@link DLP_ErrCode#ERR_OH_API_ONLY_FOR_SANDBOX_ERROR} 19100006 - If No permission to * call this API, which is available only for DLP sandbox applications. - * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * {@link DLP_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability * works abnormally. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_GetDLPPermissionInfo(OH_DLPPermissionInfo *info); +DLP_ErrCode OH_DLP_GetDLPPermissionInfo(DLP_PermissionInfo *info); /** * @brief Obtains the original file name from a DLP file name. @@ -149,11 +117,11 @@ OH_DLPPermission_ErrCode OH_DLPPermission_GetDLPPermissionInfo(OH_DLPPermissionI * * @param fileName - Indicates the DLP file name. * @param originalFileName - Indicates the original file name obtained. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMS} 19100001 - If the parameter value is invalid. + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_INVALID_PARAMS} 19100001 - If the parameter value is invalid. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_GetOriginalFileName(const char *fileName, char *originalFileName); +DLP_ErrCode OH_DLP_GetOriginalFileName(const char *fileName, char *originalFileName); /** * @brief Obtains the original file name from a DLP file name. @@ -161,65 +129,65 @@ OH_DLPPermission_ErrCode OH_DLPPermission_GetOriginalFileName(const char *fileNa * * @param fileName - Indicates the DLP file name. * @param suffixFileName - Indicates the suffix file name obtained. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_GetDLPSuffix(char *suffixFileName); +DLP_ErrCode OH_DLP_GetDLPSuffix(char *suffixFileName); /** * @brief Checks whether current application is in the DLP sandbox. This method uses a promise to return the result. * * @param isInSandbox - Indicates output parameter; {@code true} if current application is in a DLP sandbox, {@code false} otherwise. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability * works abnormally. - * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * {@link DLP_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_IsInSandbox(bool *isInSandbox); +DLP_ErrCode OH_DLP_IsInSandbox(bool *isInSandbox); /** * @brief Sets sandbox application configuration. This method uses a promise to return the result. * * @param configInfo - Configuration of the sandbox application. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. - * {@link OH_DLPPermission_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_INVALID_PARAMETER} 19100001 - If the parameter value is invalid. + * {@link DLP_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to * call this API, which is available only for non-DLP sandbox applications. - * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * {@link DLP_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability * works abnormally. - * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * {@link DLP_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_SetSandboxAppConfig(const char *configInfo); +DLP_ErrCode OH_DLP_SetSandboxAppConfig(const char *configInfo); /** * @brief Obtains sandbox application configuration. This method uses a promise to return the result. * * @param configInfo - Configuration of the sandbox application. - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability * works abnormally. - * {@link OH_DLPPermission_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. - * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * {@link DLP_ErrCode#ERR_OH_OUT_OF_MEMORY} 19100012 - If the memory error. + * {@link DLP_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_GetSandboxAppConfig(char *configInfo); +DLP_ErrCode OH_DLP_GetSandboxAppConfig(char *configInfo); /** * @brief Cleans sandbox application configuration. This method uses a promise to return the result. * - * @return {@link OH_DLPPermission_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. - * {@link OH_DLPPermission_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to + * @return {@link DLP_ErrCode#ERR_OH_SUCCESS} 0 - If the operation is successful. + * {@link DLP_ErrCode#ERR_OH_API_NOT_FOR_SANDBOX_ERROR} 19100007 - If No permission to * call this API, which is available only for non-DLP sandbox applications. - * {@link OH_DLPPermission_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability + * {@link DLP_ErrCode#ERR_OH_SYSTEM_SERVICE_EXCEPTION} 19100011 - If the system ability * works abnormally. - * {@link OH_DLPPermission_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. + * {@link DLP_ErrCode#ERR_OH_APPLICATION_NOT_AUTHORIZED} 19100018 - Not authorized application. * @since 12 */ -OH_DLPPermission_ErrCode OH_DLPPermission_CleanSandboxAppConfig(); +DLP_ErrCode OH_DLP_CleanSandboxAppConfig(); #ifdef __cplusplus } diff --git a/DataProtectionKit/libdlpperission.ndk.json b/DataProtectionKit/libdlpperission.ndk.json index f978d457c..91e747026 100644 --- a/DataProtectionKit/libdlpperission.ndk.json +++ b/DataProtectionKit/libdlpperission.ndk.json @@ -1,30 +1,30 @@ [ { "first_introduced": "12", - "name": "OH_DLPPermission_GetDLPPermissionInfo" + "name": "OH_DLP_GetDLPPermissionInfo" }, { "first_introduced": "12", - "name": "OH_DLPPermission_GetOriginalFileName" + "name": "OH_DLP_GetOriginalFileName" }, { "first_introduced": "12", - "name": "OH_DLPPermission_GetDLPSuffix" + "name": "OH_DLP_GetDLPSuffix" }, { "first_introduced": "12", - "name": "OH_DLPPermission_IsInSandbox" + "name": "OH_DLP_IsInSandbox" }, { "first_introduced": "12", - "name": "OH_DLPPermission_SetSandboxAppConfig" + "name": "OH_DLP_SetSandboxAppConfig" }, { "first_introduced": "12", - "name": "OH_DLPPermission_GetSandboxAppConfig" + "name": "OH_DLP_GetSandboxAppConfig" }, { "first_introduced": "12", - "name": "OH_DLPPermission_CleanSandboxAppConfig" + "name": "OH_DLP_CleanSandboxAppConfig" } ] \ No newline at end of file -- Gitee