security/nss/lib/libpkix/pkix/checker/pkix_revocationmethod.h

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 /* This Source Code Form is subject to the terms of the Mozilla Public
     2  * License, v. 2.0. If a copy of the MPL was not distributed with this
     3  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     4 /*
     5  * pkix_revocationmethod.h
     6  *
     7  * RevocationMethod Object
     8  *
     9  */
    11 #ifndef _PKIX_REVOCATIONMETHOD_H
    12 #define _PKIX_REVOCATIONMETHOD_H
    14 #include "pkixt.h"
    15 #include "pkix_revocationchecker.h"
    17 #ifdef __cplusplus
    18 extern "C" {
    19 #endif
    21 typedef struct pkix_RevocationMethodStruct pkix_RevocationMethod;
    23 /* Local revocation check function prototype definition.
    24  * Revocation methods capable of checking revocation though local
    25  * means(cache) should implement this prototype. */
    26 typedef PKIX_Error *
    27 pkix_LocalRevocationCheckFn(PKIX_PL_Cert *cert, PKIX_PL_Cert *issuer,
    28                             PKIX_PL_Date *date, 
    29                             pkix_RevocationMethod *checkerObject,
    30                             PKIX_ProcessingParams *procParams,
    31                             PKIX_UInt32 methodFlags,
    32                             PKIX_Boolean chainVerificationState,
    33                             PKIX_RevocationStatus *pRevStatus,
    34                             PKIX_UInt32 *reasonCode,
    35                             void *plContext);
    37 /* External revocation check function prototype definition.
    38  * Revocation methods that required external communications(crldp
    39  * ocsp) shoult implement this prototype. */
    40 typedef PKIX_Error *
    41 pkix_ExternalRevocationCheckFn(PKIX_PL_Cert *cert, PKIX_PL_Cert *issuer,
    42                                PKIX_PL_Date *date,
    43                                pkix_RevocationMethod *checkerObject,
    44                                PKIX_ProcessingParams *procParams,
    45                                PKIX_UInt32 methodFlags,
    46                                PKIX_RevocationStatus *pRevStatus,
    47                                PKIX_UInt32 *reasonCode,
    48                                void **pNBIOContext, void *plContext);
    50 /* Revocation method structure assosiates revocation types with
    51  * a set of flags on the method, a priority of the method, and
    52  * method local/external checker functions. */
    53 struct pkix_RevocationMethodStruct {
    54     PKIX_RevocationMethodType methodType;
    55     PKIX_UInt32 flags;
    56     PKIX_UInt32 priority;
    57     pkix_LocalRevocationCheckFn (*localRevChecker);
    58     pkix_ExternalRevocationCheckFn (*externalRevChecker);
    59 };
    61 PKIX_Error *
    62 pkix_RevocationMethod_Duplicate(PKIX_PL_Object *object,
    63                                 PKIX_PL_Object *newObject,
    64                                 void *plContext);
    66 PKIX_Error *
    67 pkix_RevocationMethod_Init(pkix_RevocationMethod *method,
    68                            PKIX_RevocationMethodType methodType,
    69                            PKIX_UInt32 flags,
    70                            PKIX_UInt32 priority,
    71                            pkix_LocalRevocationCheckFn localRevChecker,
    72                            pkix_ExternalRevocationCheckFn externalRevChecker,
    73                            void *plContext);
    76 #ifdef __cplusplus
    77 }
    78 #endif
    80 #endif /* _PKIX_REVOCATIONMETHOD_H */

mercurial