11bd4fe43Sopenharmony_ci/** 21bd4fe43Sopenharmony_ci * @file hks_device_provision.h 31bd4fe43Sopenharmony_ci * 41bd4fe43Sopenharmony_ci * Copyright (c) 2020 Huawei Device Co., Ltd. 51bd4fe43Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 61bd4fe43Sopenharmony_ci * you may not use this file except in compliance with the License. 71bd4fe43Sopenharmony_ci * You may obtain a copy of the License at 81bd4fe43Sopenharmony_ci * 91bd4fe43Sopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 101bd4fe43Sopenharmony_ci * 111bd4fe43Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software 121bd4fe43Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 131bd4fe43Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 141bd4fe43Sopenharmony_ci * See the License for the specific language governing permissions and 151bd4fe43Sopenharmony_ci * limitations under the License. 161bd4fe43Sopenharmony_ci */ 171bd4fe43Sopenharmony_ci 181bd4fe43Sopenharmony_ci/** 191bd4fe43Sopenharmony_ci * Description: device pki provision, verify; efuse write, verify function \n 201bd4fe43Sopenharmony_ci * Author: Huawei \n 211bd4fe43Sopenharmony_ci * Create: 2020-03-26 221bd4fe43Sopenharmony_ci */ 231bd4fe43Sopenharmony_ci 241bd4fe43Sopenharmony_ci /** 251bd4fe43Sopenharmony_ci * @defgroup iot_hks 261bd4fe43Sopenharmony_ci * @ingroup hks 271bd4fe43Sopenharmony_ci */ 281bd4fe43Sopenharmony_ci 291bd4fe43Sopenharmony_ci#ifndef HKS_DEVICE_PROVISION_H 301bd4fe43Sopenharmony_ci#define HKS_DEVICE_PROVISION_H 311bd4fe43Sopenharmony_ci 321bd4fe43Sopenharmony_ci#include "hks_types.h" 331bd4fe43Sopenharmony_ci 341bd4fe43Sopenharmony_ci#ifdef __cplusplus 351bd4fe43Sopenharmony_ciextern "C" { 361bd4fe43Sopenharmony_ci#endif 371bd4fe43Sopenharmony_ci 381bd4fe43Sopenharmony_ci/** 391bd4fe43Sopenharmony_ci* @ingroup iot_hks 401bd4fe43Sopenharmony_ci* @brief Production write efuse and certificate import verification function. 411bd4fe43Sopenharmony_ci CNcomment:产线写入efuse和证书导入验证功能。CNend 421bd4fe43Sopenharmony_ci* 431bd4fe43Sopenharmony_ci* @par 描述: 441bd4fe43Sopenharmony_ci* Production write efuse and certificate import verification function. 451bd4fe43Sopenharmony_ci CNcomment:产线写入efuse和证书导入验证功能。CNend 461bd4fe43Sopenharmony_ci* 471bd4fe43Sopenharmony_ci* @attention None 481bd4fe43Sopenharmony_ci* @param cmd [IN] type #uint32_t,Command word id. CNcomment: 命令字id。CNend 491bd4fe43Sopenharmony_ci* @param input [IN] type #const struct hks_blob *,keybox data for pki provision function; 501bd4fe43Sopenharmony_ci common name information for certificate. 511bd4fe43Sopenharmony_ci CNcomment:证书导入keybox数据或者为证书common name信息。CNend 521bd4fe43Sopenharmony_ci* @param output [OUT] type #struct hks_blob *,reserved parameters, not used. CNcomment:保留参数,暂不使用。CNend 531bd4fe43Sopenharmony_ci* @retval #0 Success. 541bd4fe43Sopenharmony_ci* @retval #Other Failure. 551bd4fe43Sopenharmony_ci* @par 依赖: 561bd4fe43Sopenharmony_ci* @li hks_types.h:describes hks_types SDK interfaces.CNcomment:描述hks_types SDK的接口。CNend 571bd4fe43Sopenharmony_ci* @see hks_pki_provision 581bd4fe43Sopenharmony_ci*/ 591bd4fe43Sopenharmony_ciHKS_DLL_API_PUBLIC int32_t hks_pki_provision(uint32_t cmd, const struct hks_blob *input, struct hks_blob *output); 601bd4fe43Sopenharmony_ci 611bd4fe43Sopenharmony_ci#ifdef __cplusplus 621bd4fe43Sopenharmony_ci} 631bd4fe43Sopenharmony_ci#endif 641bd4fe43Sopenharmony_ci 651bd4fe43Sopenharmony_ci#endif /* HKS_DEVICE_PROVISION_H */ 66