RSA Security logo

RSA BSAFE Cert-C
API Reference

pkicrmsg.h

Go to the documentation of this file.
00001 /*  
00002 ** Copyright (c) 1999-2002, RSA Security Inc.
00003 **
00004 ** This file is used to demonstrate how to interface to an RSA
00005 ** Security licensed development product.  You have a
00006 ** royalty-free right to use, modify, reproduce and distribute this
00007 ** demonstration file (including any modified version), provided that
00008 ** you agree that RSA Security has no warranty, implied or
00009 ** otherwise, or liability for this demonstration file or any modified
00010 ** version.
00011 **
00012 */
00013 
00019 #ifndef PKI_CERT_REQUEST_H
00020 #define PKI_CERT_REQUEST_H
00021 
00022 #include "basetype.h"
00023 #include "bsafe.h"
00024 #include "certext.h"
00025 #include "certapi.h"
00026 #include "certalg.h"
00027 #include "pkistinf.h"
00028 #include "pkimsg.h"
00029 #include "pkictmsg.h"
00030 
00031 #ifdef __cplusplus
00032 extern "C" {
00033 #endif
00034 
00075 typedef POINTER PKI_CERT_REQ_OBJ;  /* handle to PKI certificate request object */
00117 typedef POINTER PKI_CERT_RESP_OBJ; /* handle to PKI certificate response object */
00118 
00131 int C_CreatePKICertReqObject ( 
00132   CERTC_CTX         ctx,              /* (in) Cert-C context */
00133   PKI_CERT_REQ_OBJ  *pPKICertReqObj); /* (mod) cert request Object */
00134 
00143 void C_DestroyPKICertReqObject ( 
00144   PKI_CERT_REQ_OBJ  *pPKICertReqObj); /* (mod) cert request Object */
00145 
00159 int C_SetPKICertReqID (
00160   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (mod) cert request object */
00161   ITEM              *pCertReqID);     /* (in) cert request Id */
00162 
00177 int C_GetPKICertReqID (
00178   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (in) cert request object */
00179   ITEM              *pCertReqID);     /* (out) cert request Id */
00180 
00194 int C_SetPKICertReqControls (
00195   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (mod) cert request object */                           
00196   ATTRIBUTES_OBJ    controls);        /* (in) attributes affecting issurance */
00197 
00211 int C_GetPKICertReqControls (
00212   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (in) cert request object */                              
00213   ATTRIBUTES_OBJ    *pControls);      /* (out) attributes affecting issuance */
00214 
00228 int C_SetPKICertReqPOPType (
00229   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (mod) cert request object */
00230   unsigned int      popType);         /* (in) proof-of-possession (one of PKI_POP_*) */
00231 
00245 int C_GetPKICertReqPOPType (
00246   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (in) cert request object */
00247   unsigned int      *pPopType);       /* (out) proof-of-possession (one of PKI_POP_*) */
00248 
00262 int C_SetPKICertReqRegInfo (
00263   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (mod) cert request object */
00264   ATTRIBUTES_OBJ    regInfo);         /* (in) supplementary information */
00265 
00279 int C_GetPKICertReqRegInfo (
00280   PKI_CERT_REQ_OBJ  PKICertReqObj,    /* (in) cert request object */
00281   ATTRIBUTES_OBJ    *pRegInfo);       /* (out) supplementary information */
00282 
00296 int C_SetPKICertReqCertTemplate (
00297   PKI_CERT_REQ_OBJ      PKICertReqObj, /* (mod) cert request object */
00298   PKI_CERT_TEMPLATE_OBJ certTmplObj);  /* (in) cert template object */
00299 
00313 int C_GetPKICertReqCertTemplate (
00314   PKI_CERT_REQ_OBJ      PKICertReqObj,  /* (in) cert request object */
00315   PKI_CERT_TEMPLATE_OBJ *pCertTmplObj); /* (out) cert template object */
00316 
00329 int C_CreatePKICertRespObject ( 
00330   CERTC_CTX         ctx,                /* (in) Cert-C context */
00331   PKI_CERT_RESP_OBJ *pPKICertRespObj);  /* (mod) cert response Object */
00332 
00341 void C_DestroyPKICertRespObject ( 
00342   PKI_CERT_RESP_OBJ *pPKICertRespObj);  /* (mod) cert response Object */
00343 
00357 int C_SetPKICertRespStatus(
00358   PKI_CERT_RESP_OBJ   PKICertRespObj,     /* (mod) cert response Object */
00359   PKI_STATUS_INFO_OBJ PKIStatusInfoObj);  /* (in) pki status info object */
00360 
00374 int C_GetPKICertRespStatus(
00375   PKI_CERT_RESP_OBJ   PKICertRespObj,     /* (in) cert response Object */
00376   PKI_STATUS_INFO_OBJ *pPKIStatusInfoObj);/* (out) pki status info object */
00377 
00391 int C_SetPKICertRespCertReqID(
00392   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (mod) cert response Object */
00393   ITEM              *pCertReqID);       /* (in) cert request ID */
00394 
00408 int C_GetPKICertRespCertReqID(
00409   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (in) cert response Object */
00410   ITEM              *pCertReqID);       /* (out) cert request ID */
00411 
00425 int C_SetPKICertRespRequestedCert(
00426   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (mod) cert response Object */
00427   CERT_OBJ          certObj);           /* (in) requested certificate */
00428 
00442 int C_GetPKICertRespRequestedCert(
00443   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (in) cert response Object */
00444   CERT_OBJ          *pCertObj);         /* (out) requested certificate */
00445 
00459 int C_SetPKICertRespRequestedPrivateKey(
00460   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (mod) cert response Object */
00461   B_KEY_OBJ         privateKey);        /* (in) requested private key */
00462 
00476 int C_GetPKICertRespRequestedPrivateKey(
00477   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (in) cert response Object */
00478   B_KEY_OBJ         *pPrivateKey);      /* (out) requested private key */
00479 
00493 int C_SetPKICertRespRegInfo(
00494   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (mod) cert response Object */
00495   ATTRIBUTES_OBJ    regInfo);           /* (in) supplementary information */
00496 
00510 int C_GetPKICertRespRegInfo(
00511   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (in) cert response Object */
00512   ATTRIBUTES_OBJ    *pRegInfo);         /* (out) supplementary information */
00513 
00527 int C_SetPKICertRespCACerts(
00528   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (mod) cert response Object */
00529   LIST_OBJ          CACertList);        /* (in) a list of CA Certificates */
00530 
00544 int C_GetPKICertRespCACerts(
00545   PKI_CERT_RESP_OBJ PKICertRespObj,     /* (in) cert response Object */
00546   LIST_OBJ          *pCACertList);      /* (out) a list of CA Certificates */
00547 
00548 #ifdef __cplusplus
00549 }
00550 #endif
00551 
00552 #endif /* PKI_CERT_REQUEST_H */



RSA BSAFE® Cert-C 2.7 API Reference