16#ifndef HITLS_X509_VERIFY_H
17#define HITLS_X509_VERIFY_H
19#include "hitls_build.h"
20#ifdef HITLS_PKI_X509_VFY
22#include "bsl_asn1_internal.h"
24#include "hitls_pki_x509.h"
25#include "sal_atomic.h"
32 HITLS_X509_VFY_FLAG_SECBITS = 0x100000000,
33 HITLS_X509_VFY_FLAG_TIME = 0x200000000,
34} HITLS_X509_IN_VerifyFlag;
36typedef struct _HITLS_X509_VerifyParam {
38 uint32_t securityBits;
42#ifdef HITLS_CRYPTO_SM2
45} HITLS_X509_VerifyParam;
47struct _HITLS_X509_StoreCtx {
48 HITLS_X509_List *store;
50 BSL_SAL_RefCount references;
51 HITLS_X509_VerifyParam verifyParam;
52 CRYPT_EAL_LibCtx *libCtx;
54 HITLS_X509_List *certChain;
55#ifdef HITLS_PKI_X509_VFY_LOCATION
58#ifdef HITLS_PKI_X509_VFY_CB
61 HITLS_X509_Cert *curCert;
68int32_t HITLS_X509_VerifyParamAndExt(HITLS_X509_StoreCtx *storeCtx, HITLS_X509_List *chain);
74int32_t HITLS_X509_VerifyCrl(HITLS_X509_StoreCtx *storeCtx, HITLS_X509_List *chain);
76int32_t HITLS_X509_CertCmp(HITLS_X509_Cert *certOri, HITLS_X509_Cert *cert);
78int32_t HITLS_X509_CrlCmp(HITLS_X509_Crl *crlOri, HITLS_X509_Crl *crl);
80int32_t HITLS_X509_GetIssuerFromStore(HITLS_X509_StoreCtx *storeCtx, HITLS_X509_Cert *cert, HITLS_X509_Cert **issuer);
int32_t(* X509_STORECTX_VerifyCb)(int32_t, HITLS_X509_StoreCtx *)
Certificate chain build function.
定义 hitls_pki_x509.h:39