tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

testutil_nss.h (2457B)


      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 * testutil_nss.h
      6 *
      7 * NSS-specific utility functions for handling test errors
      8 *
      9 */
     10 
     11 #ifndef _TESTUTIL_NSS_H
     12 #define _TESTUTIL_NSS_H
     13 
     14 #include "pkix_tools.h"
     15 #include "plstr.h"
     16 #include "prprf.h"
     17 #include "prlong.h"
     18 #include "secutil.h"
     19 #include <stdio.h>
     20 #include <ctype.h>
     21 
     22 #ifdef __cplusplus
     23 extern "C" {
     24 #endif
     25 
     26 #include "pkix_pl_generalname.h"
     27 
     28 /* see source file for function documentation */
     29 
     30 PKIX_PL_Cert *
     31 createCert(
     32    char *dirName,
     33    char *certFile,
     34    void *plContext);
     35 
     36 PKIX_PL_CRL *
     37 createCRL(
     38    char *dirName,
     39    char *crlFileName,
     40    void *plContext);
     41 
     42 PKIX_TrustAnchor *
     43 createTrustAnchor(
     44    char *dirName,
     45    char *taFileName,
     46    PKIX_Boolean useCert,
     47    void *plContext);
     48 
     49 PKIX_List *
     50 createCertChain(
     51    char *dirName,
     52    char *firstCertFileName,
     53    char *secondCertFileName,
     54    void *plContext);
     55 
     56 PKIX_List *
     57 createCertChainPlus(
     58    char *dirName,
     59    char *certNames[],
     60    PKIX_PL_Cert *certs[],
     61    PKIX_UInt32 numCerts,
     62    void *plContext);
     63 
     64 PKIX_PL_Date *
     65 createDate(
     66    char *asciiDate,
     67    void *plContext);
     68 
     69 PKIX_ProcessingParams *
     70 createProcessingParams(
     71    char *dirName,
     72    char *firstAnchorFileName,
     73    char *secondAnchorFileName,
     74    char *dateAscii,
     75    PKIX_List *initialPolicies, /* List of PKIX_PL_OID */
     76    PKIX_Boolean isCrlEnabled,
     77    void *plContext);
     78 
     79 PKIX_ValidateParams *
     80 createValidateParams(
     81    char *dirName,
     82    char *firstAnchorFileName,
     83    char *secondAnchorFileName,
     84    char *dateAscii,
     85    PKIX_List *initialPolicies, /* List of PKIX_PL_OID */
     86    PKIX_Boolean initialPolicyMappingInhibit,
     87    PKIX_Boolean initialAnyPolicyInhibit,
     88    PKIX_Boolean initialExplicitPolicy,
     89    PKIX_Boolean isCrlEnabled,
     90    PKIX_List *chain,
     91    void *plContext);
     92 
     93 PKIX_ValidateResult *
     94 createValidateResult(
     95    char *dirName,
     96    char *anchorFileName,
     97    char *pubKeyCertFileName,
     98    void *plContext);
     99 
    100 PKIX_BuildResult *
    101 createBuildResult(
    102    char *dirName,
    103    char *anchorFileName,
    104    char *pubKeyCertFileName,
    105    char *firstChainCertFileName,
    106    char *secondChainCertFileName,
    107    void *plContext);
    108 
    109 PKIX_PL_GeneralName *
    110 createGeneralName(
    111    PKIX_UInt32 nameType,
    112    char *asciiName,
    113    void *plContext);
    114 
    115 #ifdef __cplusplus
    116 }
    117 #endif
    118 
    119 #endif /* TESTUTIL_NSS_H */