5 * "AuthenticationFramework" ASN.1 module encode/decode/extracting/matching/free C src.
6 * This file was generated by modified eSMACC compiler Sun Dec 5 19:16:59 2004
7 * The generated files are strongly encouraged to be
8 * compiled as a module for OpenLDAP Software
11 #ifndef _certificate_h_
12 #define _certificate_h_
21 #pragma warning( disable : 4101 )
23 #include "component.h"
24 typedef enum AuthenticationFrameworkAnyId
28 printableStringOid_ANY_ID = 2} AuthenticationFrameworkAnyId;
31 void InitAnyAuthenticationFramework();
38 typedef ComponentInt ComponentVersion; /* INTEGER { V1 (0), V2 (1), V3 (2) } */
40 #define MatchingComponentVersion MatchingComponentInt
42 #define ExtractingComponentVersion ExtractingComponentInt
44 #define BDecComponentVersion BDecComponentInt
46 #define GDecComponentVersion GDecComponentInt
49 typedef ComponentInt ComponentCertificateSerialNumber; /* INTEGER */
51 #define MatchingComponentCertificateSerialNumber MatchingComponentInt
53 #define ExtractingComponentCertificateSerialNumber ExtractingComponentInt
55 #define BDecComponentCertificateSerialNumber BDecComponentInt
57 #define GDecComponentCertificateSerialNumber GDecComponentInt
60 typedef ComponentOid ComponentAttributeType; /* OBJECT IDENTIFIER */
62 #define MatchingComponentAttributeType MatchingComponentOid
64 #define ExtractingComponentAttributeType ExtractingComponentOid
66 #define BDecComponentAttributeType BDecComponentOid
68 #define GDecComponentAttributeType GDecComponentOid
71 typedef ComponentBits ComponentUniqueIdentifier; /* BIT STRING */
73 #define MatchingComponentUniqueIdentifier MatchingComponentBits
75 #define ExtractingComponentUniqueIdentifier ExtractingComponentBits
77 #define BDecComponentUniqueIdentifier BDecComponentBits
79 #define GDecComponentUniqueIdentifier GDecComponentBits
82 typedef struct AlgorithmIdentifier /* SEQUENCE */
85 ComponentDesc* comp_desc;
86 struct berval identifier;
87 char id_buf[MAX_IDENTIFIER_LEN];
88 ComponentOid algorithm; /* OBJECT IDENTIFIER */
89 ComponentAnyDefinedBy parameters; /* ANY DEFINED BY algorithm OPTIONAL */
90 } ComponentAlgorithmIdentifier;
92 int MatchingComponentAlgorithmIdentifier PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
95 void* ExtractingComponentAlgorithmIdentifier PROTO (( void* mem_op, ComponentReference *cr, ComponentAlgorithmIdentifier *comp ));
98 int BDecComponentAlgorithmIdentifier PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentAlgorithmIdentifier **v, AsnLen *bytesDecoded, int mode));
101 int GDecComponentAlgorithmIdentifier PROTO (( void* mem_op, GenBuf * b, ComponentAlgorithmIdentifier **v, AsnLen *bytesDecoded, int mode));
105 typedef struct Time /* CHOICE */
108 ComponentDesc* comp_desc;
109 struct berval identifier;
110 char id_buf[MAX_IDENTIFIER_LEN];
116 union TimeChoiceUnion
118 ComponentUTCTime* utcTime; /* < unknown type id ?! > */
119 ComponentGeneralizedTime* generalizedTime; /* < unknown type id ?! > */
123 int MatchingComponentTime PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
126 void* ExtractingComponentTime PROTO (( void* mem_op, ComponentReference *cr, ComponentTime *comp ));
129 int BDecComponentTime PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentTime **v, AsnLen *bytesDecoded, int mode));
132 int GDecComponentTime PROTO (( void* mem_op, GenBuf * b, ComponentTime **v, AsnLen *bytesDecoded, int mode));
136 typedef struct Extension /* SEQUENCE */
139 ComponentDesc* comp_desc;
140 struct berval identifier;
141 char id_buf[MAX_IDENTIFIER_LEN];
142 ComponentOid extnID; /* OBJECT IDENTIFIER */
143 ComponentOcts extnValue; /* OCTET STRING */
144 } ComponentExtension;
146 int MatchingComponentExtension PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
149 void* ExtractingComponentExtension PROTO (( void* mem_op, ComponentReference *cr, ComponentExtension *comp ));
152 int BDecComponentExtension PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentExtension **v, AsnLen *bytesDecoded, int mode));
155 int GDecComponentExtension PROTO (( void* mem_op, GenBuf * b, ComponentExtension **v, AsnLen *bytesDecoded, int mode));
159 typedef struct AttributeTypeAndValue /* SEQUENCE */
162 ComponentDesc* comp_desc;
163 struct berval identifier;
164 char id_buf[MAX_IDENTIFIER_LEN];
165 ComponentAttributeType type; /* AttributeType */
166 ComponentAnyDefinedBy value; /* ANY DEFINED BY type */
167 } ComponentAttributeTypeAndValue;
169 int MatchingComponentAttributeTypeAndValue PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
172 void* ExtractingComponentAttributeTypeAndValue PROTO (( void* mem_op, ComponentReference *cr, ComponentAttributeTypeAndValue *comp ));
175 int BDecComponentAttributeTypeAndValue PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentAttributeTypeAndValue **v, AsnLen *bytesDecoded, int mode));
178 int GDecComponentAttributeTypeAndValue PROTO (( void* mem_op, GenBuf * b, ComponentAttributeTypeAndValue **v, AsnLen *bytesDecoded, int mode));
182 typedef struct Validity /* SEQUENCE */
185 ComponentDesc* comp_desc;
186 struct berval identifier;
187 char id_buf[MAX_IDENTIFIER_LEN];
188 ComponentTime* notBefore; /* Time */
189 ComponentTime* notAfter; /* Time */
192 int MatchingComponentValidity PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
195 void* ExtractingComponentValidity PROTO (( void* mem_op, ComponentReference *cr, ComponentValidity *comp ));
198 int BDecComponentValidity PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentValidity **v, AsnLen *bytesDecoded, int mode));
201 int GDecComponentValidity PROTO (( void* mem_op, GenBuf * b, ComponentValidity **v, AsnLen *bytesDecoded, int mode));
205 typedef struct SubjectPublicKeyInfo /* SEQUENCE */
208 ComponentDesc* comp_desc;
209 struct berval identifier;
210 char id_buf[MAX_IDENTIFIER_LEN];
211 ComponentAlgorithmIdentifier* algorithm; /* AlgorithmIdentifier */
212 ComponentBits subjectPublicKey; /* BIT STRING */
213 } ComponentSubjectPublicKeyInfo;
215 int MatchingComponentSubjectPublicKeyInfo PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
218 void* ExtractingComponentSubjectPublicKeyInfo PROTO (( void* mem_op, ComponentReference *cr, ComponentSubjectPublicKeyInfo *comp ));
221 int BDecComponentSubjectPublicKeyInfo PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentSubjectPublicKeyInfo **v, AsnLen *bytesDecoded, int mode));
224 int GDecComponentSubjectPublicKeyInfo PROTO (( void* mem_op, GenBuf * b, ComponentSubjectPublicKeyInfo **v, AsnLen *bytesDecoded, int mode));
228 typedef ComponentList ComponentExtensions; /* SEQUENCE SIZE 1..MAX OF Extension */
230 int MatchingComponentExtensions PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
233 void* ExtractingComponentExtensions PROTO (( void* mem_op, ComponentReference *cr, ComponentExtensions *comp ));
236 int BDecComponentExtensions PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentExtensions **v, AsnLen *bytesDecoded, int mode));
239 int GDecComponentExtensions PROTO (( void* mem_op, GenBuf * b, ComponentExtensions **v, AsnLen *bytesDecoded, int mode));
243 typedef ComponentList ComponentRelativeDistinguishedName; /* SET OF AttributeTypeAndValue */
245 int MatchingComponentRelativeDistinguishedName PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
248 void* ExtractingComponentRelativeDistinguishedName PROTO (( void* mem_op, ComponentReference *cr, ComponentRelativeDistinguishedName *comp ));
251 int BDecComponentRelativeDistinguishedName PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentRelativeDistinguishedName **v, AsnLen *bytesDecoded, int mode));
254 int GDecComponentRelativeDistinguishedName PROTO (( void* mem_op, GenBuf * b, ComponentRelativeDistinguishedName **v, AsnLen *bytesDecoded, int mode));
258 typedef ComponentList ComponentRDNSequence; /* SEQUENCE OF RelativeDistinguishedName */
260 int MatchingComponentRDNSequence PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
263 void* ExtractingComponentRDNSequence PROTO (( void* mem_op, ComponentReference *cr, ComponentRDNSequence *comp ));
266 int BDecComponentRDNSequence PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentRDNSequence **v, AsnLen *bytesDecoded, int mode));
269 int GDecComponentRDNSequence PROTO (( void* mem_op, GenBuf * b, ComponentRDNSequence **v, AsnLen *bytesDecoded, int mode));
273 typedef struct Name /* CHOICE */
276 ComponentDesc* comp_desc;
277 struct berval identifier;
278 char id_buf[MAX_IDENTIFIER_LEN];
283 union NameChoiceUnion
285 ComponentRDNSequence* rdnSequence; /* RDNSequence */
289 int MatchingComponentName PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
292 void* ExtractingComponentName PROTO (( void* mem_op, ComponentReference *cr, ComponentName *comp ));
295 int BDecComponentName PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentName **v, AsnLen *bytesDecoded, int mode));
298 int GDecComponentName PROTO (( void* mem_op, GenBuf * b, ComponentName **v, AsnLen *bytesDecoded, int mode));
302 typedef struct TBSCertificate /* SEQUENCE */
305 ComponentDesc* comp_desc;
306 struct berval identifier;
307 char id_buf[MAX_IDENTIFIER_LEN];
308 ComponentVersion* version; /* [0] Version DEFAULT v1 */
309 ComponentCertificateSerialNumber serialNumber; /* CertificateSerialNumber */
310 ComponentAlgorithmIdentifier* signature; /* AlgorithmIdentifier */
311 ComponentName* issuer; /* Name */
312 ComponentValidity* validity; /* Validity */
313 ComponentName* subject; /* Name */
314 ComponentSubjectPublicKeyInfo* subjectPublicKeyInfo; /* SubjectPublicKeyInfo */
315 ComponentUniqueIdentifier issuerUniqueIdentifier; /* [1] IMPLICIT UniqueIdentifier OPTIONAL */
316 ComponentUniqueIdentifier subjectUniqueIdentifier; /* [2] IMPLICIT UniqueIdentifier OPTIONAL */
317 ComponentExtensions* extensions; /* [3] Extensions OPTIONAL */
318 } ComponentTBSCertificate;
320 int MatchingComponentTBSCertificate PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
323 void* ExtractingComponentTBSCertificate PROTO (( void* mem_op, ComponentReference *cr, ComponentTBSCertificate *comp ));
326 int BDecComponentTBSCertificate PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentTBSCertificate **v, AsnLen *bytesDecoded, int mode));
329 int GDecComponentTBSCertificate PROTO (( void* mem_op, GenBuf * b, ComponentTBSCertificate **v, AsnLen *bytesDecoded, int mode));
333 typedef struct Certificate /* SEQUENCE */
336 ComponentDesc* comp_desc;
337 struct berval identifier;
338 char id_buf[MAX_IDENTIFIER_LEN];
339 ComponentTBSCertificate* tbsCertificate; /* TBSCertificate */
340 ComponentAlgorithmIdentifier* signatureAlgorithm; /* AlgorithmIdentifier */
341 ComponentBits signature; /* BIT STRING */
342 } ComponentCertificate;
344 int MatchingComponentCertificate PROTO (( char *oid, ComponentSyntaxInfo *, ComponentSyntaxInfo *v2 ));
347 void* ExtractingComponentCertificate PROTO (( void* mem_op, ComponentReference *cr, ComponentCertificate *comp ));
350 int BDecComponentCertificate PROTO ((void* mem_op, GenBuf * b, AsnTag tagId0, AsnLen elmtLen0, ComponentCertificate **v, AsnLen *bytesDecoded, int mode));
353 int GDecComponentCertificate PROTO (( void* mem_op, GenBuf * b, ComponentCertificate **v, AsnLen *bytesDecoded, int mode));
357 /* ========== Object Declarations ========== */
360 /* ========== Object Set Declarations ========== */
365 #endif /* conditional include of certificate.h */