diff options
Diffstat (limited to 'src/lib/libcrypto/asn1/asn1.h')
-rw-r--r-- | src/lib/libcrypto/asn1/asn1.h | 770 |
1 files changed, 361 insertions, 409 deletions
diff --git a/src/lib/libcrypto/asn1/asn1.h b/src/lib/libcrypto/asn1/asn1.h index 6f956b1963..0d1713f8dd 100644 --- a/src/lib/libcrypto/asn1/asn1.h +++ b/src/lib/libcrypto/asn1/asn1.h | |||
@@ -60,15 +60,24 @@ | |||
60 | #define HEADER_ASN1_H | 60 | #define HEADER_ASN1_H |
61 | 61 | ||
62 | #include <time.h> | 62 | #include <time.h> |
63 | #ifndef NO_BIO | 63 | #ifndef OPENSSL_NO_BIO |
64 | #include <openssl/bio.h> | 64 | #include <openssl/bio.h> |
65 | #endif | 65 | #endif |
66 | #include <openssl/e_os2.h> | ||
66 | #include <openssl/bn.h> | 67 | #include <openssl/bn.h> |
67 | #include <openssl/stack.h> | 68 | #include <openssl/stack.h> |
68 | #include <openssl/safestack.h> | 69 | #include <openssl/safestack.h> |
69 | 70 | ||
70 | #include <openssl/symhacks.h> | 71 | #include <openssl/symhacks.h> |
71 | 72 | ||
73 | #include <openssl/e_os2.h> | ||
74 | #include <openssl/ossl_typ.h> | ||
75 | |||
76 | #ifdef OPENSSL_BUILD_SHLIBCRYPTO | ||
77 | # undef OPENSSL_EXTERN | ||
78 | # define OPENSSL_EXTERN OPENSSL_EXPORT | ||
79 | #endif | ||
80 | |||
72 | #ifdef __cplusplus | 81 | #ifdef __cplusplus |
73 | extern "C" { | 82 | extern "C" { |
74 | #endif | 83 | #endif |
@@ -84,6 +93,7 @@ extern "C" { | |||
84 | 93 | ||
85 | #define V_ASN1_APP_CHOOSE -2 /* let the recipient choose */ | 94 | #define V_ASN1_APP_CHOOSE -2 /* let the recipient choose */ |
86 | #define V_ASN1_OTHER -3 /* used in ASN1_TYPE */ | 95 | #define V_ASN1_OTHER -3 /* used in ASN1_TYPE */ |
96 | #define V_ASN1_ANY -4 /* used in ASN1 template code */ | ||
87 | 97 | ||
88 | #define V_ASN1_NEG 0x100 /* negative flag */ | 98 | #define V_ASN1_NEG 0x100 /* negative flag */ |
89 | 99 | ||
@@ -136,6 +146,8 @@ extern "C" { | |||
136 | #define B_ASN1_BMPSTRING 0x0800 | 146 | #define B_ASN1_BMPSTRING 0x0800 |
137 | #define B_ASN1_UNKNOWN 0x1000 | 147 | #define B_ASN1_UNKNOWN 0x1000 |
138 | #define B_ASN1_UTF8STRING 0x2000 | 148 | #define B_ASN1_UTF8STRING 0x2000 |
149 | #define B_ASN1_UTCTIME 0x4000 | ||
150 | #define B_ASN1_GENERALIZEDTIME 0x8000 | ||
139 | 151 | ||
140 | /* For use with ASN1_mbstring_copy() */ | 152 | /* For use with ASN1_mbstring_copy() */ |
141 | #define MBSTRING_FLAG 0x1000 | 153 | #define MBSTRING_FLAG 0x1000 |
@@ -193,6 +205,21 @@ typedef struct asn1_string_st | |||
193 | long flags; | 205 | long flags; |
194 | } ASN1_STRING; | 206 | } ASN1_STRING; |
195 | 207 | ||
208 | /* ASN1_ENCODING structure: this is used to save the received | ||
209 | * encoding of an ASN1 type. This is useful to get round | ||
210 | * problems with invalid encodings which can break signatures. | ||
211 | */ | ||
212 | |||
213 | typedef struct ASN1_ENCODING_st | ||
214 | { | ||
215 | unsigned char *enc; /* DER encoding */ | ||
216 | long len; /* Length of encoding */ | ||
217 | int modified; /* set to 1 if 'enc' is invalid */ | ||
218 | } ASN1_ENCODING; | ||
219 | |||
220 | /* Used with ASN1 LONG type: if a long is set to this it is omitted */ | ||
221 | #define ASN1_LONG_UNDEF 0x7fffffffL | ||
222 | |||
196 | #define STABLE_FLAGS_MALLOC 0x01 | 223 | #define STABLE_FLAGS_MALLOC 0x01 |
197 | #define STABLE_NO_MASK 0x02 | 224 | #define STABLE_NO_MASK 0x02 |
198 | #define DIRSTRING_TYPE \ | 225 | #define DIRSTRING_TYPE \ |
@@ -220,43 +247,116 @@ DECLARE_STACK_OF(ASN1_STRING_TABLE) | |||
220 | #define ub_title 64 | 247 | #define ub_title 64 |
221 | #define ub_email_address 128 | 248 | #define ub_email_address 128 |
222 | 249 | ||
223 | #ifdef NO_ASN1_TYPEDEFS | 250 | /* Declarations for template structures: for full definitions |
224 | #define ASN1_INTEGER ASN1_STRING | 251 | * see asn1t.h |
225 | #define ASN1_ENUMERATED ASN1_STRING | 252 | */ |
226 | #define ASN1_BIT_STRING ASN1_STRING | 253 | typedef struct ASN1_TEMPLATE_st ASN1_TEMPLATE; |
227 | #define ASN1_OCTET_STRING ASN1_STRING | 254 | typedef struct ASN1_ITEM_st ASN1_ITEM; |
228 | #define ASN1_PRINTABLESTRING ASN1_STRING | 255 | typedef struct ASN1_TLC_st ASN1_TLC; |
229 | #define ASN1_T61STRING ASN1_STRING | 256 | /* This is just an opaque pointer */ |
230 | #define ASN1_IA5STRING ASN1_STRING | 257 | typedef struct ASN1_VALUE_st ASN1_VALUE; |
231 | #define ASN1_UTCTIME ASN1_STRING | 258 | |
232 | #define ASN1_GENERALIZEDTIME ASN1_STRING | 259 | /* Declare ASN1 functions: the implement macro in in asn1t.h */ |
233 | #define ASN1_TIME ASN1_STRING | 260 | |
234 | #define ASN1_GENERALSTRING ASN1_STRING | 261 | #define DECLARE_ASN1_FUNCTIONS(type) DECLARE_ASN1_FUNCTIONS_name(type, type) |
235 | #define ASN1_UNIVERSALSTRING ASN1_STRING | 262 | |
236 | #define ASN1_BMPSTRING ASN1_STRING | 263 | #define DECLARE_ASN1_FUNCTIONS_name(type, name) \ |
237 | #define ASN1_VISIBLESTRING ASN1_STRING | 264 | type *name##_new(void); \ |
238 | #define ASN1_UTF8STRING ASN1_STRING | 265 | void name##_free(type *a); \ |
239 | #define ASN1_BOOLEAN int | 266 | DECLARE_ASN1_ENCODE_FUNCTIONS(type, name, name) |
267 | |||
268 | #define DECLARE_ASN1_FUNCTIONS_fname(type, itname, name) \ | ||
269 | type *name##_new(void); \ | ||
270 | void name##_free(type *a); \ | ||
271 | DECLARE_ASN1_ENCODE_FUNCTIONS(type, itname, name) | ||
272 | |||
273 | #define DECLARE_ASN1_ENCODE_FUNCTIONS(type, itname, name) \ | ||
274 | type *d2i_##name(type **a, unsigned char **in, long len); \ | ||
275 | int i2d_##name(type *a, unsigned char **out); \ | ||
276 | DECLARE_ASN1_ITEM(itname) | ||
277 | |||
278 | #define DECLARE_ASN1_ENCODE_FUNCTIONS_const(type, name) \ | ||
279 | type *d2i_##name(type **a, const unsigned char **in, long len); \ | ||
280 | int i2d_##name(const type *a, unsigned char **out); \ | ||
281 | DECLARE_ASN1_ITEM(name) | ||
282 | |||
283 | #define DECLARE_ASN1_FUNCTIONS_const(name) \ | ||
284 | name *name##_new(void); \ | ||
285 | void name##_free(name *a); | ||
286 | |||
287 | |||
288 | /* The following macros and typedefs allow an ASN1_ITEM | ||
289 | * to be embedded in a structure and referenced. Since | ||
290 | * the ASN1_ITEM pointers need to be globally accessible | ||
291 | * (possibly from shared libraries) they may exist in | ||
292 | * different forms. On platforms that support it the | ||
293 | * ASN1_ITEM structure itself will be globally exported. | ||
294 | * Other platforms will export a function that returns | ||
295 | * an ASN1_ITEM pointer. | ||
296 | * | ||
297 | * To handle both cases transparently the macros below | ||
298 | * should be used instead of hard coding an ASN1_ITEM | ||
299 | * pointer in a structure. | ||
300 | * | ||
301 | * The structure will look like this: | ||
302 | * | ||
303 | * typedef struct SOMETHING_st { | ||
304 | * ... | ||
305 | * ASN1_ITEM_EXP *iptr; | ||
306 | * ... | ||
307 | * } SOMETHING; | ||
308 | * | ||
309 | * It would be initialised as e.g.: | ||
310 | * | ||
311 | * SOMETHING somevar = {...,ASN1_ITEM_ref(X509),...}; | ||
312 | * | ||
313 | * and the actual pointer extracted with: | ||
314 | * | ||
315 | * const ASN1_ITEM *it = ASN1_ITEM_ptr(somevar.iptr); | ||
316 | * | ||
317 | * Finally an ASN1_ITEM pointer can be extracted from an | ||
318 | * appropriate reference with: ASN1_ITEM_rptr(X509). This | ||
319 | * would be used when a function takes an ASN1_ITEM * argument. | ||
320 | * | ||
321 | */ | ||
322 | |||
323 | #ifndef OPENSSL_EXPORT_VAR_AS_FUNCTION | ||
324 | |||
325 | /* ASN1_ITEM pointer exported type */ | ||
326 | typedef const ASN1_ITEM ASN1_ITEM_EXP; | ||
327 | |||
328 | /* Macro to obtain ASN1_ITEM pointer from exported type */ | ||
329 | #define ASN1_ITEM_ptr(iptr) (iptr) | ||
330 | |||
331 | /* Macro to include ASN1_ITEM pointer from base type */ | ||
332 | #define ASN1_ITEM_ref(iptr) (&(iptr##_it)) | ||
333 | |||
334 | #define ASN1_ITEM_rptr(ref) (&(ref##_it)) | ||
335 | |||
336 | #define DECLARE_ASN1_ITEM(name) \ | ||
337 | OPENSSL_EXTERN const ASN1_ITEM name##_it; | ||
338 | |||
240 | #else | 339 | #else |
241 | typedef struct asn1_string_st ASN1_INTEGER; | ||
242 | typedef struct asn1_string_st ASN1_ENUMERATED; | ||
243 | typedef struct asn1_string_st ASN1_BIT_STRING; | ||
244 | typedef struct asn1_string_st ASN1_OCTET_STRING; | ||
245 | typedef struct asn1_string_st ASN1_PRINTABLESTRING; | ||
246 | typedef struct asn1_string_st ASN1_T61STRING; | ||
247 | typedef struct asn1_string_st ASN1_IA5STRING; | ||
248 | typedef struct asn1_string_st ASN1_GENERALSTRING; | ||
249 | typedef struct asn1_string_st ASN1_UNIVERSALSTRING; | ||
250 | typedef struct asn1_string_st ASN1_BMPSTRING; | ||
251 | typedef struct asn1_string_st ASN1_UTCTIME; | ||
252 | typedef struct asn1_string_st ASN1_TIME; | ||
253 | typedef struct asn1_string_st ASN1_GENERALIZEDTIME; | ||
254 | typedef struct asn1_string_st ASN1_VISIBLESTRING; | ||
255 | typedef struct asn1_string_st ASN1_UTF8STRING; | ||
256 | typedef int ASN1_BOOLEAN; | ||
257 | #endif | ||
258 | 340 | ||
259 | typedef int ASN1_NULL; | 341 | /* Platforms that can't easily handle shared global variables are declared |
342 | * as functions returning ASN1_ITEM pointers. | ||
343 | */ | ||
344 | |||
345 | /* ASN1_ITEM pointer exported type */ | ||
346 | typedef const ASN1_ITEM * ASN1_ITEM_EXP(void); | ||
347 | |||
348 | /* Macro to obtain ASN1_ITEM pointer from exported type */ | ||
349 | #define ASN1_ITEM_ptr(iptr) (iptr()) | ||
350 | |||
351 | /* Macro to include ASN1_ITEM pointer from base type */ | ||
352 | #define ASN1_ITEM_ref(iptr) (iptr##_it) | ||
353 | |||
354 | #define ASN1_ITEM_rptr(ref) (ref##_it()) | ||
355 | |||
356 | #define DECLARE_ASN1_ITEM(name) \ | ||
357 | const ASN1_ITEM * name##_it(void); | ||
358 | |||
359 | #endif | ||
260 | 360 | ||
261 | /* Parameters used by ASN1_STRING_print_ex() */ | 361 | /* Parameters used by ASN1_STRING_print_ex() */ |
262 | 362 | ||
@@ -340,6 +440,8 @@ typedef int ASN1_NULL; | |||
340 | DECLARE_STACK_OF(ASN1_INTEGER) | 440 | DECLARE_STACK_OF(ASN1_INTEGER) |
341 | DECLARE_ASN1_SET_OF(ASN1_INTEGER) | 441 | DECLARE_ASN1_SET_OF(ASN1_INTEGER) |
342 | 442 | ||
443 | DECLARE_STACK_OF(ASN1_GENERALSTRING) | ||
444 | |||
343 | typedef struct asn1_type_st | 445 | typedef struct asn1_type_st |
344 | { | 446 | { |
345 | int type; | 447 | int type; |
@@ -438,12 +540,11 @@ typedef struct BIT_STRING_BITNAME_st { | |||
438 | i2d_ASN1_bytes((ASN1_STRING *)a,pp,V_ASN1_OCTET_STRING,\ | 540 | i2d_ASN1_bytes((ASN1_STRING *)a,pp,V_ASN1_OCTET_STRING,\ |
439 | V_ASN1_UNIVERSAL) | 541 | V_ASN1_UNIVERSAL) |
440 | 542 | ||
441 | #define M_ASN1_PRINTABLE_new() ASN1_STRING_type_new(V_ASN1_T61STRING) | 543 | #define B_ASN1_TIME \ |
442 | #define M_ASN1_PRINTABLE_free(a) ASN1_STRING_free((ASN1_STRING *)a) | 544 | B_ASN1_UTCTIME | \ |
443 | #define M_i2d_ASN1_PRINTABLE(a,pp) i2d_ASN1_bytes((ASN1_STRING *)a,\ | 545 | B_ASN1_GENERALIZEDTIME |
444 | pp,a->type,V_ASN1_UNIVERSAL) | 546 | |
445 | #define M_d2i_ASN1_PRINTABLE(a,pp,l) \ | 547 | #define B_ASN1_PRINTABLE \ |
446 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ | ||
447 | B_ASN1_PRINTABLESTRING| \ | 548 | B_ASN1_PRINTABLESTRING| \ |
448 | B_ASN1_T61STRING| \ | 549 | B_ASN1_T61STRING| \ |
449 | B_ASN1_IA5STRING| \ | 550 | B_ASN1_IA5STRING| \ |
@@ -451,7 +552,28 @@ typedef struct BIT_STRING_BITNAME_st { | |||
451 | B_ASN1_UNIVERSALSTRING|\ | 552 | B_ASN1_UNIVERSALSTRING|\ |
452 | B_ASN1_BMPSTRING|\ | 553 | B_ASN1_BMPSTRING|\ |
453 | B_ASN1_UTF8STRING|\ | 554 | B_ASN1_UTF8STRING|\ |
454 | B_ASN1_UNKNOWN) | 555 | B_ASN1_UNKNOWN |
556 | |||
557 | #define B_ASN1_DIRECTORYSTRING \ | ||
558 | B_ASN1_PRINTABLESTRING| \ | ||
559 | B_ASN1_TELETEXSTRING|\ | ||
560 | B_ASN1_BMPSTRING|\ | ||
561 | B_ASN1_UNIVERSALSTRING|\ | ||
562 | B_ASN1_UTF8STRING | ||
563 | |||
564 | #define B_ASN1_DISPLAYTEXT \ | ||
565 | B_ASN1_IA5STRING| \ | ||
566 | B_ASN1_VISIBLESTRING| \ | ||
567 | B_ASN1_BMPSTRING|\ | ||
568 | B_ASN1_UTF8STRING | ||
569 | |||
570 | #define M_ASN1_PRINTABLE_new() ASN1_STRING_type_new(V_ASN1_T61STRING) | ||
571 | #define M_ASN1_PRINTABLE_free(a) ASN1_STRING_free((ASN1_STRING *)a) | ||
572 | #define M_i2d_ASN1_PRINTABLE(a,pp) i2d_ASN1_bytes((ASN1_STRING *)a,\ | ||
573 | pp,a->type,V_ASN1_UNIVERSAL) | ||
574 | #define M_d2i_ASN1_PRINTABLE(a,pp,l) \ | ||
575 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ | ||
576 | B_ASN1_PRINTABLE) | ||
455 | 577 | ||
456 | #define M_DIRECTORYSTRING_new() ASN1_STRING_type_new(V_ASN1_PRINTABLESTRING) | 578 | #define M_DIRECTORYSTRING_new() ASN1_STRING_type_new(V_ASN1_PRINTABLESTRING) |
457 | #define M_DIRECTORYSTRING_free(a) ASN1_STRING_free((ASN1_STRING *)a) | 579 | #define M_DIRECTORYSTRING_free(a) ASN1_STRING_free((ASN1_STRING *)a) |
@@ -459,11 +581,7 @@ typedef struct BIT_STRING_BITNAME_st { | |||
459 | pp,a->type,V_ASN1_UNIVERSAL) | 581 | pp,a->type,V_ASN1_UNIVERSAL) |
460 | #define M_d2i_DIRECTORYSTRING(a,pp,l) \ | 582 | #define M_d2i_DIRECTORYSTRING(a,pp,l) \ |
461 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ | 583 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ |
462 | B_ASN1_PRINTABLESTRING| \ | 584 | B_ASN1_DIRECTORYSTRING) |
463 | B_ASN1_TELETEXSTRING|\ | ||
464 | B_ASN1_BMPSTRING|\ | ||
465 | B_ASN1_UNIVERSALSTRING|\ | ||
466 | B_ASN1_UTF8STRING) | ||
467 | 585 | ||
468 | #define M_DISPLAYTEXT_new() ASN1_STRING_type_new(V_ASN1_VISIBLESTRING) | 586 | #define M_DISPLAYTEXT_new() ASN1_STRING_type_new(V_ASN1_VISIBLESTRING) |
469 | #define M_DISPLAYTEXT_free(a) ASN1_STRING_free((ASN1_STRING *)a) | 587 | #define M_DISPLAYTEXT_free(a) ASN1_STRING_free((ASN1_STRING *)a) |
@@ -471,9 +589,7 @@ typedef struct BIT_STRING_BITNAME_st { | |||
471 | pp,a->type,V_ASN1_UNIVERSAL) | 589 | pp,a->type,V_ASN1_UNIVERSAL) |
472 | #define M_d2i_DISPLAYTEXT(a,pp,l) \ | 590 | #define M_d2i_DISPLAYTEXT(a,pp,l) \ |
473 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ | 591 | d2i_ASN1_type_bytes((ASN1_STRING **)a,pp,l, \ |
474 | B_ASN1_VISIBLESTRING| \ | 592 | B_ASN1_DISPLAYTEXT) |
475 | B_ASN1_BMPSTRING|\ | ||
476 | B_ASN1_UTF8STRING) | ||
477 | 593 | ||
478 | #define M_ASN1_PRINTABLESTRING_new() (ASN1_PRINTABLESTRING *)\ | 594 | #define M_ASN1_PRINTABLESTRING_new() (ASN1_PRINTABLESTRING *)\ |
479 | ASN1_STRING_type_new(V_ASN1_PRINTABLESTRING) | 595 | ASN1_STRING_type_new(V_ASN1_PRINTABLESTRING) |
@@ -577,10 +693,8 @@ typedef struct BIT_STRING_BITNAME_st { | |||
577 | #define IS_SEQUENCE 0 | 693 | #define IS_SEQUENCE 0 |
578 | #define IS_SET 1 | 694 | #define IS_SET 1 |
579 | 695 | ||
580 | ASN1_TYPE * ASN1_TYPE_new(void ); | 696 | DECLARE_ASN1_FUNCTIONS_fname(ASN1_TYPE, ASN1_ANY, ASN1_TYPE) |
581 | void ASN1_TYPE_free(ASN1_TYPE *a); | 697 | |
582 | int i2d_ASN1_TYPE(ASN1_TYPE *a,unsigned char **pp); | ||
583 | ASN1_TYPE * d2i_ASN1_TYPE(ASN1_TYPE **a,unsigned char **pp,long length); | ||
584 | int ASN1_TYPE_get(ASN1_TYPE *a); | 698 | int ASN1_TYPE_get(ASN1_TYPE *a); |
585 | void ASN1_TYPE_set(ASN1_TYPE *a, int type, void *value); | 699 | void ASN1_TYPE_set(ASN1_TYPE *a, int type, void *value); |
586 | 700 | ||
@@ -592,6 +706,8 @@ ASN1_OBJECT * c2i_ASN1_OBJECT(ASN1_OBJECT **a,unsigned char **pp, | |||
592 | ASN1_OBJECT * d2i_ASN1_OBJECT(ASN1_OBJECT **a,unsigned char **pp, | 706 | ASN1_OBJECT * d2i_ASN1_OBJECT(ASN1_OBJECT **a,unsigned char **pp, |
593 | long length); | 707 | long length); |
594 | 708 | ||
709 | DECLARE_ASN1_ITEM(ASN1_OBJECT) | ||
710 | |||
595 | DECLARE_STACK_OF(ASN1_OBJECT) | 711 | DECLARE_STACK_OF(ASN1_OBJECT) |
596 | DECLARE_ASN1_SET_OF(ASN1_OBJECT) | 712 | DECLARE_ASN1_SET_OF(ASN1_OBJECT) |
597 | 713 | ||
@@ -608,12 +724,8 @@ void ASN1_STRING_length_set(ASN1_STRING *x, int n); | |||
608 | int ASN1_STRING_type(ASN1_STRING *x); | 724 | int ASN1_STRING_type(ASN1_STRING *x); |
609 | unsigned char * ASN1_STRING_data(ASN1_STRING *x); | 725 | unsigned char * ASN1_STRING_data(ASN1_STRING *x); |
610 | 726 | ||
611 | ASN1_BIT_STRING * ASN1_BIT_STRING_new(void); | 727 | DECLARE_ASN1_FUNCTIONS(ASN1_BIT_STRING) |
612 | void ASN1_BIT_STRING_free(ASN1_BIT_STRING *a); | ||
613 | int i2d_ASN1_BIT_STRING(ASN1_BIT_STRING *a,unsigned char **pp); | ||
614 | int i2c_ASN1_BIT_STRING(ASN1_BIT_STRING *a,unsigned char **pp); | 728 | int i2c_ASN1_BIT_STRING(ASN1_BIT_STRING *a,unsigned char **pp); |
615 | ASN1_BIT_STRING *d2i_ASN1_BIT_STRING(ASN1_BIT_STRING **a,unsigned char **pp, | ||
616 | long length); | ||
617 | ASN1_BIT_STRING *c2i_ASN1_BIT_STRING(ASN1_BIT_STRING **a,unsigned char **pp, | 729 | ASN1_BIT_STRING *c2i_ASN1_BIT_STRING(ASN1_BIT_STRING **a,unsigned char **pp, |
618 | long length); | 730 | long length); |
619 | int ASN1_BIT_STRING_set(ASN1_BIT_STRING *a, unsigned char *d, | 731 | int ASN1_BIT_STRING_set(ASN1_BIT_STRING *a, unsigned char *d, |
@@ -621,7 +733,7 @@ int ASN1_BIT_STRING_set(ASN1_BIT_STRING *a, unsigned char *d, | |||
621 | int ASN1_BIT_STRING_set_bit(ASN1_BIT_STRING *a, int n, int value); | 733 | int ASN1_BIT_STRING_set_bit(ASN1_BIT_STRING *a, int n, int value); |
622 | int ASN1_BIT_STRING_get_bit(ASN1_BIT_STRING *a, int n); | 734 | int ASN1_BIT_STRING_get_bit(ASN1_BIT_STRING *a, int n); |
623 | 735 | ||
624 | #ifndef NO_BIO | 736 | #ifndef OPENSSL_NO_BIO |
625 | int ASN1_BIT_STRING_name_print(BIO *out, ASN1_BIT_STRING *bs, | 737 | int ASN1_BIT_STRING_name_print(BIO *out, ASN1_BIT_STRING *bs, |
626 | BIT_STRING_BITNAME *tbl, int indent); | 738 | BIT_STRING_BITNAME *tbl, int indent); |
627 | #endif | 739 | #endif |
@@ -632,12 +744,8 @@ int ASN1_BIT_STRING_set_asc(ASN1_BIT_STRING *bs, char *name, int value, | |||
632 | int i2d_ASN1_BOOLEAN(int a,unsigned char **pp); | 744 | int i2d_ASN1_BOOLEAN(int a,unsigned char **pp); |
633 | int d2i_ASN1_BOOLEAN(int *a,unsigned char **pp,long length); | 745 | int d2i_ASN1_BOOLEAN(int *a,unsigned char **pp,long length); |
634 | 746 | ||
635 | ASN1_INTEGER * ASN1_INTEGER_new(void); | 747 | DECLARE_ASN1_FUNCTIONS(ASN1_INTEGER) |
636 | void ASN1_INTEGER_free(ASN1_INTEGER *a); | ||
637 | int i2d_ASN1_INTEGER(ASN1_INTEGER *a,unsigned char **pp); | ||
638 | int i2c_ASN1_INTEGER(ASN1_INTEGER *a,unsigned char **pp); | 748 | int i2c_ASN1_INTEGER(ASN1_INTEGER *a,unsigned char **pp); |
639 | ASN1_INTEGER *d2i_ASN1_INTEGER(ASN1_INTEGER **a,unsigned char **pp, | ||
640 | long length); | ||
641 | ASN1_INTEGER *c2i_ASN1_INTEGER(ASN1_INTEGER **a,unsigned char **pp, | 749 | ASN1_INTEGER *c2i_ASN1_INTEGER(ASN1_INTEGER **a,unsigned char **pp, |
642 | long length); | 750 | long length); |
643 | ASN1_INTEGER *d2i_ASN1_UINTEGER(ASN1_INTEGER **a,unsigned char **pp, | 751 | ASN1_INTEGER *d2i_ASN1_UINTEGER(ASN1_INTEGER **a,unsigned char **pp, |
@@ -645,11 +753,7 @@ ASN1_INTEGER *d2i_ASN1_UINTEGER(ASN1_INTEGER **a,unsigned char **pp, | |||
645 | ASN1_INTEGER * ASN1_INTEGER_dup(ASN1_INTEGER *x); | 753 | ASN1_INTEGER * ASN1_INTEGER_dup(ASN1_INTEGER *x); |
646 | int ASN1_INTEGER_cmp(ASN1_INTEGER *x, ASN1_INTEGER *y); | 754 | int ASN1_INTEGER_cmp(ASN1_INTEGER *x, ASN1_INTEGER *y); |
647 | 755 | ||
648 | ASN1_ENUMERATED * ASN1_ENUMERATED_new(void); | 756 | DECLARE_ASN1_FUNCTIONS(ASN1_ENUMERATED) |
649 | void ASN1_ENUMERATED_free(ASN1_ENUMERATED *a); | ||
650 | int i2d_ASN1_ENUMERATED(ASN1_ENUMERATED *a,unsigned char **pp); | ||
651 | ASN1_ENUMERATED *d2i_ASN1_ENUMERATED(ASN1_ENUMERATED **a,unsigned char **pp, | ||
652 | long length); | ||
653 | 757 | ||
654 | int ASN1_UTCTIME_check(ASN1_UTCTIME *a); | 758 | int ASN1_UTCTIME_check(ASN1_UTCTIME *a); |
655 | ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s,time_t t); | 759 | ASN1_UTCTIME *ASN1_UTCTIME_set(ASN1_UTCTIME *s,time_t t); |
@@ -663,91 +767,34 @@ int ASN1_GENERALIZEDTIME_check(ASN1_GENERALIZEDTIME *a); | |||
663 | ASN1_GENERALIZEDTIME *ASN1_GENERALIZEDTIME_set(ASN1_GENERALIZEDTIME *s,time_t t); | 767 | ASN1_GENERALIZEDTIME *ASN1_GENERALIZEDTIME_set(ASN1_GENERALIZEDTIME *s,time_t t); |
664 | int ASN1_GENERALIZEDTIME_set_string(ASN1_GENERALIZEDTIME *s, char *str); | 768 | int ASN1_GENERALIZEDTIME_set_string(ASN1_GENERALIZEDTIME *s, char *str); |
665 | 769 | ||
666 | ASN1_OCTET_STRING * ASN1_OCTET_STRING_new(void); | 770 | DECLARE_ASN1_FUNCTIONS(ASN1_OCTET_STRING) |
667 | void ASN1_OCTET_STRING_free(ASN1_OCTET_STRING *a); | ||
668 | int i2d_ASN1_OCTET_STRING(ASN1_OCTET_STRING *a,unsigned char **pp); | ||
669 | ASN1_OCTET_STRING *d2i_ASN1_OCTET_STRING(ASN1_OCTET_STRING **a, | ||
670 | unsigned char **pp,long length); | ||
671 | ASN1_OCTET_STRING * ASN1_OCTET_STRING_dup(ASN1_OCTET_STRING *a); | 771 | ASN1_OCTET_STRING * ASN1_OCTET_STRING_dup(ASN1_OCTET_STRING *a); |
672 | int ASN1_OCTET_STRING_cmp(ASN1_OCTET_STRING *a, ASN1_OCTET_STRING *b); | 772 | int ASN1_OCTET_STRING_cmp(ASN1_OCTET_STRING *a, ASN1_OCTET_STRING *b); |
673 | int ASN1_OCTET_STRING_set(ASN1_OCTET_STRING *str, unsigned char *data, int len); | 773 | int ASN1_OCTET_STRING_set(ASN1_OCTET_STRING *str, unsigned char *data, int len); |
674 | 774 | ||
675 | ASN1_VISIBLESTRING * ASN1_VISIBLESTRING_new(void); | 775 | DECLARE_ASN1_FUNCTIONS(ASN1_VISIBLESTRING) |
676 | void ASN1_VISIBLESTRING_free(ASN1_VISIBLESTRING *a); | 776 | DECLARE_ASN1_FUNCTIONS(ASN1_UTF8STRING) |
677 | int i2d_ASN1_VISIBLESTRING(ASN1_VISIBLESTRING *a,unsigned char **pp); | 777 | DECLARE_ASN1_FUNCTIONS(ASN1_NULL) |
678 | ASN1_VISIBLESTRING *d2i_ASN1_VISIBLESTRING(ASN1_VISIBLESTRING **a, | 778 | DECLARE_ASN1_FUNCTIONS(ASN1_BMPSTRING) |
679 | unsigned char **pp,long length); | ||
680 | |||
681 | ASN1_UTF8STRING * ASN1_UTF8STRING_new(void); | ||
682 | void ASN1_UTF8STRING_free(ASN1_UTF8STRING *a); | ||
683 | int i2d_ASN1_UTF8STRING(ASN1_UTF8STRING *a,unsigned char **pp); | ||
684 | ASN1_UTF8STRING *d2i_ASN1_UTF8STRING(ASN1_UTF8STRING **a, | ||
685 | unsigned char **pp,long length); | ||
686 | |||
687 | ASN1_NULL * ASN1_NULL_new(void); | ||
688 | void ASN1_NULL_free(ASN1_NULL *a); | ||
689 | int i2d_ASN1_NULL(ASN1_NULL *a,unsigned char **pp); | ||
690 | ASN1_NULL *d2i_ASN1_NULL(ASN1_NULL **a, unsigned char **pp,long length); | ||
691 | |||
692 | ASN1_BMPSTRING * ASN1_BMPSTRING_new(void); | ||
693 | void ASN1_BMPSTRING_free(ASN1_BMPSTRING *a); | ||
694 | int i2d_ASN1_BMPSTRING(ASN1_BMPSTRING *a, unsigned char **pp); | ||
695 | ASN1_BMPSTRING *d2i_ASN1_BMPSTRING(ASN1_BMPSTRING **a, unsigned char **pp, | ||
696 | long length); | ||
697 | |||
698 | 779 | ||
699 | int UTF8_getc(const unsigned char *str, int len, unsigned long *val); | 780 | int UTF8_getc(const unsigned char *str, int len, unsigned long *val); |
700 | int UTF8_putc(unsigned char *str, int len, unsigned long value); | 781 | int UTF8_putc(unsigned char *str, int len, unsigned long value); |
701 | 782 | ||
702 | int i2d_ASN1_PRINTABLE(ASN1_STRING *a,unsigned char **pp); | 783 | DECLARE_ASN1_FUNCTIONS_name(ASN1_STRING, ASN1_PRINTABLE) |
703 | ASN1_STRING *d2i_ASN1_PRINTABLE(ASN1_STRING **a, | ||
704 | unsigned char **pp, long l); | ||
705 | |||
706 | ASN1_PRINTABLESTRING * ASN1_PRINTABLESTRING_new(void); | ||
707 | void ASN1_PRINTABLESTRING_free(ASN1_PRINTABLESTRING *a); | ||
708 | ASN1_PRINTABLESTRING *d2i_ASN1_PRINTABLESTRING(ASN1_PRINTABLESTRING **a, | ||
709 | unsigned char **pp, long l); | ||
710 | int i2d_ASN1_PRINTABLESTRING(ASN1_PRINTABLESTRING *a, unsigned char **pp); | ||
711 | |||
712 | ASN1_STRING * DIRECTORYSTRING_new(void); | ||
713 | void DIRECTORYSTRING_free(ASN1_STRING *a); | ||
714 | int i2d_DIRECTORYSTRING(ASN1_STRING *a,unsigned char **pp); | ||
715 | ASN1_STRING *d2i_DIRECTORYSTRING(ASN1_STRING **a, unsigned char **pp, | ||
716 | long length); | ||
717 | |||
718 | ASN1_STRING * DISPLAYTEXT_new(void); | ||
719 | void DISPLAYTEXT_free(ASN1_STRING *a); | ||
720 | int i2d_DISPLAYTEXT(ASN1_STRING *a,unsigned char **pp); | ||
721 | ASN1_STRING *d2i_DISPLAYTEXT(ASN1_STRING **a, unsigned char **pp, long length); | ||
722 | |||
723 | ASN1_T61STRING * ASN1_T61STRING_new(void); | ||
724 | void ASN1_T61STRING_free(ASN1_IA5STRING *a); | ||
725 | ASN1_T61STRING *d2i_ASN1_T61STRING(ASN1_T61STRING **a, | ||
726 | unsigned char **pp, long l); | ||
727 | |||
728 | ASN1_IA5STRING * ASN1_IA5STRING_new(void); | ||
729 | void ASN1_IA5STRING_free(ASN1_IA5STRING *a); | ||
730 | int i2d_ASN1_IA5STRING(ASN1_IA5STRING *a,unsigned char **pp); | ||
731 | ASN1_IA5STRING *d2i_ASN1_IA5STRING(ASN1_IA5STRING **a, | ||
732 | unsigned char **pp, long l); | ||
733 | |||
734 | ASN1_UTCTIME * ASN1_UTCTIME_new(void); | ||
735 | void ASN1_UTCTIME_free(ASN1_UTCTIME *a); | ||
736 | int i2d_ASN1_UTCTIME(ASN1_UTCTIME *a,unsigned char **pp); | ||
737 | ASN1_UTCTIME * d2i_ASN1_UTCTIME(ASN1_UTCTIME **a,unsigned char **pp, | ||
738 | long length); | ||
739 | 784 | ||
740 | ASN1_GENERALIZEDTIME * ASN1_GENERALIZEDTIME_new(void); | 785 | DECLARE_ASN1_FUNCTIONS_name(ASN1_STRING, DIRECTORYSTRING) |
741 | void ASN1_GENERALIZEDTIME_free(ASN1_GENERALIZEDTIME *a); | 786 | DECLARE_ASN1_FUNCTIONS_name(ASN1_STRING, DISPLAYTEXT) |
742 | int i2d_ASN1_GENERALIZEDTIME(ASN1_GENERALIZEDTIME *a,unsigned char **pp); | 787 | DECLARE_ASN1_FUNCTIONS(ASN1_PRINTABLESTRING) |
743 | ASN1_GENERALIZEDTIME * d2i_ASN1_GENERALIZEDTIME(ASN1_GENERALIZEDTIME **a,unsigned char **pp, | 788 | DECLARE_ASN1_FUNCTIONS(ASN1_T61STRING) |
744 | long length); | 789 | DECLARE_ASN1_FUNCTIONS(ASN1_IA5STRING) |
790 | DECLARE_ASN1_FUNCTIONS(ASN1_GENERALSTRING) | ||
791 | DECLARE_ASN1_FUNCTIONS(ASN1_UTCTIME) | ||
792 | DECLARE_ASN1_FUNCTIONS(ASN1_GENERALIZEDTIME) | ||
793 | DECLARE_ASN1_FUNCTIONS(ASN1_TIME) | ||
745 | 794 | ||
746 | ASN1_TIME * ASN1_TIME_new(void); | ||
747 | void ASN1_TIME_free(ASN1_TIME *a); | ||
748 | int i2d_ASN1_TIME(ASN1_TIME *a,unsigned char **pp); | ||
749 | ASN1_TIME * d2i_ASN1_TIME(ASN1_TIME **a,unsigned char **pp, long length); | ||
750 | ASN1_TIME *ASN1_TIME_set(ASN1_TIME *s,time_t t); | 795 | ASN1_TIME *ASN1_TIME_set(ASN1_TIME *s,time_t t); |
796 | int ASN1_TIME_check(ASN1_TIME *t); | ||
797 | ASN1_GENERALIZEDTIME *ASN1_TIME_to_generalizedtime(ASN1_TIME *t, ASN1_GENERALIZEDTIME **out); | ||
751 | 798 | ||
752 | int i2d_ASN1_SET(STACK *a, unsigned char **pp, | 799 | int i2d_ASN1_SET(STACK *a, unsigned char **pp, |
753 | int (*func)(), int ex_tag, int ex_class, int is_set); | 800 | int (*func)(), int ex_tag, int ex_class, int is_set); |
@@ -755,7 +802,7 @@ STACK * d2i_ASN1_SET(STACK **a, unsigned char **pp, long length, | |||
755 | char *(*func)(), void (*free_func)(void *), | 802 | char *(*func)(), void (*free_func)(void *), |
756 | int ex_tag, int ex_class); | 803 | int ex_tag, int ex_class); |
757 | 804 | ||
758 | #ifndef NO_BIO | 805 | #ifndef OPENSSL_NO_BIO |
759 | int i2a_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *a); | 806 | int i2a_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *a); |
760 | int a2i_ASN1_INTEGER(BIO *bp,ASN1_INTEGER *bs,char *buf,int size); | 807 | int a2i_ASN1_INTEGER(BIO *bp,ASN1_INTEGER *bs,char *buf,int size); |
761 | int i2a_ASN1_ENUMERATED(BIO *bp, ASN1_ENUMERATED *a); | 808 | int i2a_ASN1_ENUMERATED(BIO *bp, ASN1_ENUMERATED *a); |
@@ -768,7 +815,7 @@ int i2t_ASN1_OBJECT(char *buf,int buf_len,ASN1_OBJECT *a); | |||
768 | 815 | ||
769 | int a2d_ASN1_OBJECT(unsigned char *out,int olen, const char *buf, int num); | 816 | int a2d_ASN1_OBJECT(unsigned char *out,int olen, const char *buf, int num); |
770 | ASN1_OBJECT *ASN1_OBJECT_create(int nid, unsigned char *data,int len, | 817 | ASN1_OBJECT *ASN1_OBJECT_create(int nid, unsigned char *data,int len, |
771 | char *sn, char *ln); | 818 | const char *sn, const char *ln); |
772 | 819 | ||
773 | int ASN1_INTEGER_set(ASN1_INTEGER *a, long v); | 820 | int ASN1_INTEGER_set(ASN1_INTEGER *a, long v); |
774 | long ASN1_INTEGER_get(ASN1_INTEGER *a); | 821 | long ASN1_INTEGER_get(ASN1_INTEGER *a); |
@@ -787,6 +834,7 @@ int ASN1_PRINTABLE_type(unsigned char *s, int max); | |||
787 | int i2d_ASN1_bytes(ASN1_STRING *a, unsigned char **pp, int tag, int xclass); | 834 | int i2d_ASN1_bytes(ASN1_STRING *a, unsigned char **pp, int tag, int xclass); |
788 | ASN1_STRING *d2i_ASN1_bytes(ASN1_STRING **a, unsigned char **pp, | 835 | ASN1_STRING *d2i_ASN1_bytes(ASN1_STRING **a, unsigned char **pp, |
789 | long length, int Ptag, int Pclass); | 836 | long length, int Ptag, int Pclass); |
837 | unsigned long ASN1_tag2bit(int tag); | ||
790 | /* type is one or more of the B_ASN1_ values. */ | 838 | /* type is one or more of the B_ASN1_ values. */ |
791 | ASN1_STRING *d2i_ASN1_type_bytes(ASN1_STRING **a,unsigned char **pp, | 839 | ASN1_STRING *d2i_ASN1_type_bytes(ASN1_STRING **a,unsigned char **pp, |
792 | long length,int type); | 840 | long length,int type); |
@@ -805,17 +853,23 @@ int ASN1_object_size(int constructed, int length, int tag); | |||
805 | /* Used to implement other functions */ | 853 | /* Used to implement other functions */ |
806 | char *ASN1_dup(int (*i2d)(),char *(*d2i)(),char *x); | 854 | char *ASN1_dup(int (*i2d)(),char *(*d2i)(),char *x); |
807 | 855 | ||
808 | #ifndef NO_FP_API | 856 | void *ASN1_item_dup(const ASN1_ITEM *it, void *x); |
857 | |||
858 | #ifndef OPENSSL_NO_FP_API | ||
809 | char *ASN1_d2i_fp(char *(*xnew)(),char *(*d2i)(),FILE *fp,unsigned char **x); | 859 | char *ASN1_d2i_fp(char *(*xnew)(),char *(*d2i)(),FILE *fp,unsigned char **x); |
860 | void *ASN1_item_d2i_fp(const ASN1_ITEM *it, FILE *in, void *x); | ||
810 | int ASN1_i2d_fp(int (*i2d)(),FILE *out,unsigned char *x); | 861 | int ASN1_i2d_fp(int (*i2d)(),FILE *out,unsigned char *x); |
862 | int ASN1_item_i2d_fp(const ASN1_ITEM *it, FILE *out, void *x); | ||
811 | int ASN1_STRING_print_ex_fp(FILE *fp, ASN1_STRING *str, unsigned long flags); | 863 | int ASN1_STRING_print_ex_fp(FILE *fp, ASN1_STRING *str, unsigned long flags); |
812 | #endif | 864 | #endif |
813 | 865 | ||
814 | int ASN1_STRING_to_UTF8(unsigned char **out, ASN1_STRING *in); | 866 | int ASN1_STRING_to_UTF8(unsigned char **out, ASN1_STRING *in); |
815 | 867 | ||
816 | #ifndef NO_BIO | 868 | #ifndef OPENSSL_NO_BIO |
817 | char *ASN1_d2i_bio(char *(*xnew)(),char *(*d2i)(),BIO *bp,unsigned char **x); | 869 | char *ASN1_d2i_bio(char *(*xnew)(),char *(*d2i)(),BIO *bp,unsigned char **x); |
870 | void *ASN1_item_d2i_bio(const ASN1_ITEM *it, BIO *in, void *x); | ||
818 | int ASN1_i2d_bio(int (*i2d)(),BIO *out,unsigned char *x); | 871 | int ASN1_i2d_bio(int (*i2d)(),BIO *out,unsigned char *x); |
872 | int ASN1_item_i2d_bio(const ASN1_ITEM *it, BIO *out, void *x); | ||
819 | int ASN1_UTCTIME_print(BIO *fp,ASN1_UTCTIME *a); | 873 | int ASN1_UTCTIME_print(BIO *fp,ASN1_UTCTIME *a); |
820 | int ASN1_GENERALIZEDTIME_print(BIO *fp,ASN1_GENERALIZEDTIME *a); | 874 | int ASN1_GENERALIZEDTIME_print(BIO *fp,ASN1_GENERALIZEDTIME *a); |
821 | int ASN1_TIME_print(BIO *fp,ASN1_TIME *a); | 875 | int ASN1_TIME_print(BIO *fp,ASN1_TIME *a); |
@@ -834,8 +888,6 @@ void ASN1_HEADER_free(ASN1_HEADER *a); | |||
834 | 888 | ||
835 | int ASN1_UNIVERSALSTRING_to_string(ASN1_UNIVERSALSTRING *s); | 889 | int ASN1_UNIVERSALSTRING_to_string(ASN1_UNIVERSALSTRING *s); |
836 | 890 | ||
837 | void ERR_load_ASN1_strings(void); | ||
838 | |||
839 | /* Not used that much at this point, except for the first two */ | 891 | /* Not used that much at this point, except for the first two */ |
840 | ASN1_METHOD *X509_asn1_meth(void); | 892 | ASN1_METHOD *X509_asn1_meth(void); |
841 | ASN1_METHOD *RSAPrivateKey_asn1_meth(void); | 893 | ASN1_METHOD *RSAPrivateKey_asn1_meth(void); |
@@ -856,7 +908,9 @@ STACK *ASN1_seq_unpack(unsigned char *buf, int len, char *(*d2i)(), | |||
856 | unsigned char *ASN1_seq_pack(STACK *safes, int (*i2d)(), unsigned char **buf, | 908 | unsigned char *ASN1_seq_pack(STACK *safes, int (*i2d)(), unsigned char **buf, |
857 | int *len ); | 909 | int *len ); |
858 | void *ASN1_unpack_string(ASN1_STRING *oct, char *(*d2i)()); | 910 | void *ASN1_unpack_string(ASN1_STRING *oct, char *(*d2i)()); |
911 | void *ASN1_item_unpack(ASN1_STRING *oct, const ASN1_ITEM *it); | ||
859 | ASN1_STRING *ASN1_pack_string(void *obj, int (*i2d)(), ASN1_OCTET_STRING **oct); | 912 | ASN1_STRING *ASN1_pack_string(void *obj, int (*i2d)(), ASN1_OCTET_STRING **oct); |
913 | ASN1_STRING *ASN1_item_pack(void *obj, const ASN1_ITEM *it, ASN1_OCTET_STRING **oct); | ||
860 | 914 | ||
861 | void ASN1_STRING_set_default_mask(unsigned long mask); | 915 | void ASN1_STRING_set_default_mask(unsigned long mask); |
862 | int ASN1_STRING_set_default_mask_asc(char *p); | 916 | int ASN1_STRING_set_default_mask_asc(char *p); |
@@ -873,279 +927,177 @@ ASN1_STRING_TABLE *ASN1_STRING_TABLE_get(int nid); | |||
873 | int ASN1_STRING_TABLE_add(int, long, long, unsigned long, unsigned long); | 927 | int ASN1_STRING_TABLE_add(int, long, long, unsigned long, unsigned long); |
874 | void ASN1_STRING_TABLE_cleanup(void); | 928 | void ASN1_STRING_TABLE_cleanup(void); |
875 | 929 | ||
930 | /* ASN1 template functions */ | ||
931 | |||
932 | /* Old API compatible functions */ | ||
933 | ASN1_VALUE *ASN1_item_new(const ASN1_ITEM *it); | ||
934 | void ASN1_item_free(ASN1_VALUE *val, const ASN1_ITEM *it); | ||
935 | ASN1_VALUE * ASN1_item_d2i(ASN1_VALUE **val, unsigned char **in, long len, const ASN1_ITEM *it); | ||
936 | int ASN1_item_i2d(ASN1_VALUE *val, unsigned char **out, const ASN1_ITEM *it); | ||
937 | |||
938 | void ASN1_add_oid_module(void); | ||
939 | |||
876 | /* BEGIN ERROR CODES */ | 940 | /* BEGIN ERROR CODES */ |
877 | /* The following lines are auto generated by the script mkerr.pl. Any changes | 941 | /* The following lines are auto generated by the script mkerr.pl. Any changes |
878 | * made after this point may be overwritten when the script is next run. | 942 | * made after this point may be overwritten when the script is next run. |
879 | */ | 943 | */ |
944 | void ERR_load_ASN1_strings(void); | ||
880 | 945 | ||
881 | /* Error codes for the ASN1 functions. */ | 946 | /* Error codes for the ASN1 functions. */ |
882 | 947 | ||
883 | /* Function codes. */ | 948 | /* Function codes. */ |
884 | #define ASN1_F_A2D_ASN1_OBJECT 100 | 949 | #define ASN1_F_A2D_ASN1_OBJECT 100 |
885 | #define ASN1_F_A2I_ASN1_ENUMERATED 236 | 950 | #define ASN1_F_A2I_ASN1_ENUMERATED 101 |
886 | #define ASN1_F_A2I_ASN1_INTEGER 101 | 951 | #define ASN1_F_A2I_ASN1_INTEGER 102 |
887 | #define ASN1_F_A2I_ASN1_STRING 102 | 952 | #define ASN1_F_A2I_ASN1_STRING 103 |
888 | #define ASN1_F_ACCESS_DESCRIPTION_NEW 291 | 953 | #define ASN1_F_ASN1_CHECK_TLEN 104 |
889 | #define ASN1_F_ASN1_COLLATE_PRIMITIVE 103 | 954 | #define ASN1_F_ASN1_COLLATE_PRIMITIVE 105 |
890 | #define ASN1_F_ASN1_D2I_BIO 104 | 955 | #define ASN1_F_ASN1_COLLECT 106 |
891 | #define ASN1_F_ASN1_D2I_FP 105 | 956 | #define ASN1_F_ASN1_D2I_BIO 107 |
892 | #define ASN1_F_ASN1_DUP 106 | 957 | #define ASN1_F_ASN1_D2I_EX_PRIMITIVE 108 |
893 | #define ASN1_F_ASN1_ENUMERATED_SET 232 | 958 | #define ASN1_F_ASN1_D2I_FP 109 |
894 | #define ASN1_F_ASN1_ENUMERATED_TO_BN 233 | 959 | #define ASN1_F_ASN1_DO_ADB 110 |
895 | #define ASN1_F_ASN1_GENERALIZEDTIME_NEW 222 | 960 | #define ASN1_F_ASN1_DUP 111 |
896 | #define ASN1_F_ASN1_GET_OBJECT 107 | 961 | #define ASN1_F_ASN1_ENUMERATED_SET 112 |
897 | #define ASN1_F_ASN1_HEADER_NEW 108 | 962 | #define ASN1_F_ASN1_ENUMERATED_TO_BN 113 |
898 | #define ASN1_F_ASN1_I2D_BIO 109 | 963 | #define ASN1_F_ASN1_GET_OBJECT 114 |
899 | #define ASN1_F_ASN1_I2D_FP 110 | 964 | #define ASN1_F_ASN1_HEADER_NEW 115 |
900 | #define ASN1_F_ASN1_INTEGER_SET 111 | 965 | #define ASN1_F_ASN1_I2D_BIO 116 |
901 | #define ASN1_F_ASN1_INTEGER_TO_BN 112 | 966 | #define ASN1_F_ASN1_I2D_FP 117 |
902 | #define ASN1_F_ASN1_MBSTRING_COPY 282 | 967 | #define ASN1_F_ASN1_INTEGER_SET 118 |
903 | #define ASN1_F_ASN1_OBJECT_NEW 113 | 968 | #define ASN1_F_ASN1_INTEGER_TO_BN 119 |
904 | #define ASN1_F_ASN1_PACK_STRING 245 | 969 | #define ASN1_F_ASN1_ITEM_EX_D2I 120 |
905 | #define ASN1_F_ASN1_PBE_SET 253 | 970 | #define ASN1_F_ASN1_ITEM_NEW 121 |
906 | #define ASN1_F_ASN1_SEQ_PACK 246 | 971 | #define ASN1_F_ASN1_MBSTRING_COPY 122 |
907 | #define ASN1_F_ASN1_SEQ_UNPACK 247 | 972 | #define ASN1_F_ASN1_OBJECT_NEW 123 |
908 | #define ASN1_F_ASN1_SIGN 114 | 973 | #define ASN1_F_ASN1_PACK_STRING 124 |
909 | #define ASN1_F_ASN1_STRING_NEW 115 | 974 | #define ASN1_F_ASN1_PBE_SET 125 |
910 | #define ASN1_F_ASN1_STRING_TABLE_ADD 283 | 975 | #define ASN1_F_ASN1_SEQ_PACK 126 |
911 | #define ASN1_F_ASN1_STRING_TYPE_NEW 116 | 976 | #define ASN1_F_ASN1_SEQ_UNPACK 127 |
912 | #define ASN1_F_ASN1_TYPE_GET_INT_OCTETSTRING 117 | 977 | #define ASN1_F_ASN1_SIGN 128 |
913 | #define ASN1_F_ASN1_TYPE_GET_OCTETSTRING 118 | 978 | #define ASN1_F_ASN1_STRING_TABLE_ADD 129 |
914 | #define ASN1_F_ASN1_TYPE_NEW 119 | 979 | #define ASN1_F_ASN1_STRING_TYPE_NEW 130 |
915 | #define ASN1_F_ASN1_UNPACK_STRING 248 | 980 | #define ASN1_F_ASN1_TEMPLATE_D2I 131 |
916 | #define ASN1_F_ASN1_UTCTIME_NEW 120 | 981 | #define ASN1_F_ASN1_TEMPLATE_EX_D2I 132 |
917 | #define ASN1_F_ASN1_VERIFY 121 | 982 | #define ASN1_F_ASN1_TEMPLATE_NEW 133 |
918 | #define ASN1_F_AUTHORITY_KEYID_NEW 237 | 983 | #define ASN1_F_ASN1_TYPE_GET_INT_OCTETSTRING 134 |
919 | #define ASN1_F_BASIC_CONSTRAINTS_NEW 226 | 984 | #define ASN1_F_ASN1_TYPE_GET_OCTETSTRING 135 |
920 | #define ASN1_F_BN_TO_ASN1_ENUMERATED 234 | 985 | #define ASN1_F_ASN1_UNPACK_STRING 136 |
921 | #define ASN1_F_BN_TO_ASN1_INTEGER 122 | 986 | #define ASN1_F_ASN1_VERIFY 137 |
922 | #define ASN1_F_D2I_ACCESS_DESCRIPTION 284 | 987 | #define ASN1_F_BN_TO_ASN1_ENUMERATED 138 |
923 | #define ASN1_F_D2I_ASN1_BIT_STRING 123 | 988 | #define ASN1_F_BN_TO_ASN1_INTEGER 139 |
924 | #define ASN1_F_D2I_ASN1_BMPSTRING 124 | 989 | #define ASN1_F_COLLECT_DATA 140 |
925 | #define ASN1_F_D2I_ASN1_BOOLEAN 125 | 990 | #define ASN1_F_D2I_ASN1_BIT_STRING 141 |
926 | #define ASN1_F_D2I_ASN1_BYTES 126 | 991 | #define ASN1_F_D2I_ASN1_BOOLEAN 142 |
927 | #define ASN1_F_D2I_ASN1_ENUMERATED 235 | 992 | #define ASN1_F_D2I_ASN1_BYTES 143 |
928 | #define ASN1_F_D2I_ASN1_GENERALIZEDTIME 223 | 993 | #define ASN1_F_D2I_ASN1_GENERALIZEDTIME 144 |
929 | #define ASN1_F_D2I_ASN1_HEADER 127 | 994 | #define ASN1_F_D2I_ASN1_HEADER 145 |
930 | #define ASN1_F_D2I_ASN1_INTEGER 128 | 995 | #define ASN1_F_D2I_ASN1_INTEGER 146 |
931 | #define ASN1_F_D2I_ASN1_NULL 292 | 996 | #define ASN1_F_D2I_ASN1_OBJECT 147 |
932 | #define ASN1_F_D2I_ASN1_OBJECT 129 | 997 | #define ASN1_F_D2I_ASN1_SET 148 |
933 | #define ASN1_F_D2I_ASN1_OCTET_STRING 130 | 998 | #define ASN1_F_D2I_ASN1_TYPE_BYTES 149 |
934 | #define ASN1_F_D2I_ASN1_PRINT_TYPE 131 | 999 | #define ASN1_F_D2I_ASN1_UINTEGER 150 |
935 | #define ASN1_F_D2I_ASN1_SET 132 | 1000 | #define ASN1_F_D2I_ASN1_UTCTIME 151 |
936 | #define ASN1_F_D2I_ASN1_TIME 224 | 1001 | #define ASN1_F_D2I_NETSCAPE_RSA 152 |
937 | #define ASN1_F_D2I_ASN1_TYPE 133 | 1002 | #define ASN1_F_D2I_NETSCAPE_RSA_2 153 |
938 | #define ASN1_F_D2I_ASN1_TYPE_BYTES 134 | 1003 | #define ASN1_F_D2I_PRIVATEKEY 154 |
939 | #define ASN1_F_D2I_ASN1_UINTEGER 280 | 1004 | #define ASN1_F_D2I_PUBLICKEY 155 |
940 | #define ASN1_F_D2I_ASN1_UTCTIME 135 | 1005 | #define ASN1_F_D2I_X509 156 |
941 | #define ASN1_F_D2I_ASN1_UTF8STRING 266 | 1006 | #define ASN1_F_D2I_X509_CINF 157 |
942 | #define ASN1_F_D2I_ASN1_VISIBLESTRING 267 | 1007 | #define ASN1_F_D2I_X509_NAME 158 |
943 | #define ASN1_F_D2I_AUTHORITY_KEYID 238 | 1008 | #define ASN1_F_D2I_X509_PKEY 159 |
944 | #define ASN1_F_D2I_BASIC_CONSTRAINTS 227 | 1009 | #define ASN1_F_I2D_ASN1_TIME 160 |
945 | #define ASN1_F_D2I_DHPARAMS 136 | 1010 | #define ASN1_F_I2D_DSA_PUBKEY 161 |
946 | #define ASN1_F_D2I_DIST_POINT 276 | 1011 | #define ASN1_F_I2D_NETSCAPE_RSA 162 |
947 | #define ASN1_F_D2I_DIST_POINT_NAME 277 | 1012 | #define ASN1_F_I2D_PRIVATEKEY 163 |
948 | #define ASN1_F_D2I_DSAPARAMS 137 | 1013 | #define ASN1_F_I2D_PUBLICKEY 164 |
949 | #define ASN1_F_D2I_DSAPRIVATEKEY 138 | 1014 | #define ASN1_F_I2D_RSA_PUBKEY 165 |
950 | #define ASN1_F_D2I_DSAPUBLICKEY 139 | 1015 | #define ASN1_F_LONG_C2I 166 |
951 | #define ASN1_F_D2I_GENERAL_NAME 230 | 1016 | #define ASN1_F_OID_MODULE_INIT 174 |
952 | #define ASN1_F_D2I_NETSCAPE_CERT_SEQUENCE 228 | 1017 | #define ASN1_F_PKCS5_PBE2_SET 167 |
953 | #define ASN1_F_D2I_NETSCAPE_PKEY 140 | 1018 | #define ASN1_F_X509_CINF_NEW 168 |
954 | #define ASN1_F_D2I_NETSCAPE_RSA 141 | 1019 | #define ASN1_F_X509_CRL_ADD0_REVOKED 169 |
955 | #define ASN1_F_D2I_NETSCAPE_RSA_2 142 | 1020 | #define ASN1_F_X509_INFO_NEW 170 |
956 | #define ASN1_F_D2I_NETSCAPE_SPKAC 143 | 1021 | #define ASN1_F_X509_NAME_NEW 171 |
957 | #define ASN1_F_D2I_NETSCAPE_SPKI 144 | 1022 | #define ASN1_F_X509_NEW 172 |
958 | #define ASN1_F_D2I_NOTICEREF 268 | 1023 | #define ASN1_F_X509_PKEY_NEW 173 |
959 | #define ASN1_F_D2I_OTHERNAME 287 | ||
960 | #define ASN1_F_D2I_PBE2PARAM 262 | ||
961 | #define ASN1_F_D2I_PBEPARAM 249 | ||
962 | #define ASN1_F_D2I_PBKDF2PARAM 263 | ||
963 | #define ASN1_F_D2I_PKCS12 254 | ||
964 | #define ASN1_F_D2I_PKCS12_BAGS 255 | ||
965 | #define ASN1_F_D2I_PKCS12_MAC_DATA 256 | ||
966 | #define ASN1_F_D2I_PKCS12_SAFEBAG 257 | ||
967 | #define ASN1_F_D2I_PKCS7 145 | ||
968 | #define ASN1_F_D2I_PKCS7_DIGEST 146 | ||
969 | #define ASN1_F_D2I_PKCS7_ENCRYPT 147 | ||
970 | #define ASN1_F_D2I_PKCS7_ENC_CONTENT 148 | ||
971 | #define ASN1_F_D2I_PKCS7_ENVELOPE 149 | ||
972 | #define ASN1_F_D2I_PKCS7_ISSUER_AND_SERIAL 150 | ||
973 | #define ASN1_F_D2I_PKCS7_RECIP_INFO 151 | ||
974 | #define ASN1_F_D2I_PKCS7_SIGNED 152 | ||
975 | #define ASN1_F_D2I_PKCS7_SIGNER_INFO 153 | ||
976 | #define ASN1_F_D2I_PKCS7_SIGN_ENVELOPE 154 | ||
977 | #define ASN1_F_D2I_PKCS8_PRIV_KEY_INFO 250 | ||
978 | #define ASN1_F_D2I_PKEY_USAGE_PERIOD 239 | ||
979 | #define ASN1_F_D2I_POLICYINFO 269 | ||
980 | #define ASN1_F_D2I_POLICYQUALINFO 270 | ||
981 | #define ASN1_F_D2I_PRIVATEKEY 155 | ||
982 | #define ASN1_F_D2I_PUBLICKEY 156 | ||
983 | #define ASN1_F_D2I_RSAPRIVATEKEY 157 | ||
984 | #define ASN1_F_D2I_RSAPUBLICKEY 158 | ||
985 | #define ASN1_F_D2I_SXNET 241 | ||
986 | #define ASN1_F_D2I_SXNETID 243 | ||
987 | #define ASN1_F_D2I_USERNOTICE 271 | ||
988 | #define ASN1_F_D2I_X509 159 | ||
989 | #define ASN1_F_D2I_X509_ALGOR 160 | ||
990 | #define ASN1_F_D2I_X509_ATTRIBUTE 161 | ||
991 | #define ASN1_F_D2I_X509_CERT_AUX 285 | ||
992 | #define ASN1_F_D2I_X509_CINF 162 | ||
993 | #define ASN1_F_D2I_X509_CRL 163 | ||
994 | #define ASN1_F_D2I_X509_CRL_INFO 164 | ||
995 | #define ASN1_F_D2I_X509_EXTENSION 165 | ||
996 | #define ASN1_F_D2I_X509_KEY 166 | ||
997 | #define ASN1_F_D2I_X509_NAME 167 | ||
998 | #define ASN1_F_D2I_X509_NAME_ENTRY 168 | ||
999 | #define ASN1_F_D2I_X509_PKEY 169 | ||
1000 | #define ASN1_F_D2I_X509_PUBKEY 170 | ||
1001 | #define ASN1_F_D2I_X509_REQ 171 | ||
1002 | #define ASN1_F_D2I_X509_REQ_INFO 172 | ||
1003 | #define ASN1_F_D2I_X509_REVOKED 173 | ||
1004 | #define ASN1_F_D2I_X509_SIG 174 | ||
1005 | #define ASN1_F_D2I_X509_VAL 175 | ||
1006 | #define ASN1_F_DIST_POINT_NAME_NEW 278 | ||
1007 | #define ASN1_F_DIST_POINT_NEW 279 | ||
1008 | #define ASN1_F_GENERAL_NAME_NEW 231 | ||
1009 | #define ASN1_F_I2D_ASN1_HEADER 176 | ||
1010 | #define ASN1_F_I2D_ASN1_TIME 225 | ||
1011 | #define ASN1_F_I2D_DHPARAMS 177 | ||
1012 | #define ASN1_F_I2D_DSAPARAMS 178 | ||
1013 | #define ASN1_F_I2D_DSAPRIVATEKEY 179 | ||
1014 | #define ASN1_F_I2D_DSAPUBLICKEY 180 | ||
1015 | #define ASN1_F_I2D_DSA_PUBKEY 290 | ||
1016 | #define ASN1_F_I2D_NETSCAPE_RSA 181 | ||
1017 | #define ASN1_F_I2D_PKCS7 182 | ||
1018 | #define ASN1_F_I2D_PRIVATEKEY 183 | ||
1019 | #define ASN1_F_I2D_PUBLICKEY 184 | ||
1020 | #define ASN1_F_I2D_RSAPRIVATEKEY 185 | ||
1021 | #define ASN1_F_I2D_RSAPUBLICKEY 186 | ||
1022 | #define ASN1_F_I2D_RSA_PUBKEY 289 | ||
1023 | #define ASN1_F_I2D_X509_ATTRIBUTE 187 | ||
1024 | #define ASN1_F_I2T_ASN1_OBJECT 188 | ||
1025 | #define ASN1_F_NETSCAPE_CERT_SEQUENCE_NEW 229 | ||
1026 | #define ASN1_F_NETSCAPE_PKEY_NEW 189 | ||
1027 | #define ASN1_F_NETSCAPE_SPKAC_NEW 190 | ||
1028 | #define ASN1_F_NETSCAPE_SPKI_NEW 191 | ||
1029 | #define ASN1_F_NOTICEREF_NEW 272 | ||
1030 | #define ASN1_F_OTHERNAME_NEW 288 | ||
1031 | #define ASN1_F_PBE2PARAM_NEW 264 | ||
1032 | #define ASN1_F_PBEPARAM_NEW 251 | ||
1033 | #define ASN1_F_PBKDF2PARAM_NEW 265 | ||
1034 | #define ASN1_F_PKCS12_BAGS_NEW 258 | ||
1035 | #define ASN1_F_PKCS12_MAC_DATA_NEW 259 | ||
1036 | #define ASN1_F_PKCS12_NEW 260 | ||
1037 | #define ASN1_F_PKCS12_SAFEBAG_NEW 261 | ||
1038 | #define ASN1_F_PKCS5_PBE2_SET 281 | ||
1039 | #define ASN1_F_PKCS7_DIGEST_NEW 192 | ||
1040 | #define ASN1_F_PKCS7_ENCRYPT_NEW 193 | ||
1041 | #define ASN1_F_PKCS7_ENC_CONTENT_NEW 194 | ||
1042 | #define ASN1_F_PKCS7_ENVELOPE_NEW 195 | ||
1043 | #define ASN1_F_PKCS7_ISSUER_AND_SERIAL_NEW 196 | ||
1044 | #define ASN1_F_PKCS7_NEW 197 | ||
1045 | #define ASN1_F_PKCS7_RECIP_INFO_NEW 198 | ||
1046 | #define ASN1_F_PKCS7_SIGNED_NEW 199 | ||
1047 | #define ASN1_F_PKCS7_SIGNER_INFO_NEW 200 | ||
1048 | #define ASN1_F_PKCS7_SIGN_ENVELOPE_NEW 201 | ||
1049 | #define ASN1_F_PKCS8_PRIV_KEY_INFO_NEW 252 | ||
1050 | #define ASN1_F_PKEY_USAGE_PERIOD_NEW 240 | ||
1051 | #define ASN1_F_POLICYINFO_NEW 273 | ||
1052 | #define ASN1_F_POLICYQUALINFO_NEW 274 | ||
1053 | #define ASN1_F_SXNETID_NEW 244 | ||
1054 | #define ASN1_F_SXNET_NEW 242 | ||
1055 | #define ASN1_F_USERNOTICE_NEW 275 | ||
1056 | #define ASN1_F_X509_ALGOR_NEW 202 | ||
1057 | #define ASN1_F_X509_ATTRIBUTE_NEW 203 | ||
1058 | #define ASN1_F_X509_CERT_AUX_NEW 286 | ||
1059 | #define ASN1_F_X509_CINF_NEW 204 | ||
1060 | #define ASN1_F_X509_CRL_INFO_NEW 205 | ||
1061 | #define ASN1_F_X509_CRL_NEW 206 | ||
1062 | #define ASN1_F_X509_DHPARAMS_NEW 207 | ||
1063 | #define ASN1_F_X509_EXTENSION_NEW 208 | ||
1064 | #define ASN1_F_X509_INFO_NEW 209 | ||
1065 | #define ASN1_F_X509_KEY_NEW 210 | ||
1066 | #define ASN1_F_X509_NAME_ENTRY_NEW 211 | ||
1067 | #define ASN1_F_X509_NAME_NEW 212 | ||
1068 | #define ASN1_F_X509_NEW 213 | ||
1069 | #define ASN1_F_X509_PKEY_NEW 214 | ||
1070 | #define ASN1_F_X509_PUBKEY_NEW 215 | ||
1071 | #define ASN1_F_X509_REQ_INFO_NEW 216 | ||
1072 | #define ASN1_F_X509_REQ_NEW 217 | ||
1073 | #define ASN1_F_X509_REVOKED_NEW 218 | ||
1074 | #define ASN1_F_X509_SIG_NEW 219 | ||
1075 | #define ASN1_F_X509_VAL_FREE 220 | ||
1076 | #define ASN1_F_X509_VAL_NEW 221 | ||
1077 | 1024 | ||
1078 | /* Reason codes. */ | 1025 | /* Reason codes. */ |
1079 | #define ASN1_R_BAD_CLASS 100 | 1026 | #define ASN1_R_ADDING_OBJECT 171 |
1080 | #define ASN1_R_BAD_OBJECT_HEADER 101 | 1027 | #define ASN1_R_AUX_ERROR 100 |
1081 | #define ASN1_R_BAD_PASSWORD_READ 102 | 1028 | #define ASN1_R_BAD_CLASS 101 |
1082 | #define ASN1_R_BAD_PKCS7_CONTENT 103 | 1029 | #define ASN1_R_BAD_OBJECT_HEADER 102 |
1083 | #define ASN1_R_BAD_PKCS7_TYPE 104 | 1030 | #define ASN1_R_BAD_PASSWORD_READ 103 |
1084 | #define ASN1_R_BAD_TAG 105 | 1031 | #define ASN1_R_BAD_TAG 104 |
1085 | #define ASN1_R_BAD_TYPE 106 | 1032 | #define ASN1_R_BN_LIB 105 |
1086 | #define ASN1_R_BN_LIB 107 | 1033 | #define ASN1_R_BOOLEAN_IS_WRONG_LENGTH 106 |
1087 | #define ASN1_R_BOOLEAN_IS_WRONG_LENGTH 108 | 1034 | #define ASN1_R_BUFFER_TOO_SMALL 107 |
1088 | #define ASN1_R_BUFFER_TOO_SMALL 109 | 1035 | #define ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER 108 |
1089 | #define ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER 166 | 1036 | #define ASN1_R_DATA_IS_WRONG 109 |
1090 | #define ASN1_R_DATA_IS_WRONG 110 | 1037 | #define ASN1_R_DECODE_ERROR 110 |
1091 | #define ASN1_R_DECODE_ERROR 155 | ||
1092 | #define ASN1_R_DECODING_ERROR 111 | 1038 | #define ASN1_R_DECODING_ERROR 111 |
1093 | #define ASN1_R_ENCODE_ERROR 156 | 1039 | #define ASN1_R_ENCODE_ERROR 112 |
1094 | #define ASN1_R_ERROR_PARSING_SET_ELEMENT 112 | 1040 | #define ASN1_R_ERROR_LOADING_SECTION 172 |
1095 | #define ASN1_R_ERROR_SETTING_CIPHER_PARAMS 157 | 1041 | #define ASN1_R_ERROR_PARSING_SET_ELEMENT 113 |
1096 | #define ASN1_R_EXPECTING_AN_ENUMERATED 154 | 1042 | #define ASN1_R_ERROR_SETTING_CIPHER_PARAMS 114 |
1097 | #define ASN1_R_EXPECTING_AN_INTEGER 113 | 1043 | #define ASN1_R_EXPECTING_AN_INTEGER 115 |
1098 | #define ASN1_R_EXPECTING_AN_OBJECT 114 | 1044 | #define ASN1_R_EXPECTING_AN_OBJECT 116 |
1099 | #define ASN1_R_EXPECTING_AN_OCTET_STRING 115 | ||
1100 | #define ASN1_R_EXPECTING_A_BIT_STRING 116 | ||
1101 | #define ASN1_R_EXPECTING_A_BOOLEAN 117 | 1045 | #define ASN1_R_EXPECTING_A_BOOLEAN 117 |
1102 | #define ASN1_R_EXPECTING_A_GENERALIZEDTIME 151 | 1046 | #define ASN1_R_EXPECTING_A_TIME 118 |
1103 | #define ASN1_R_EXPECTING_A_NULL 164 | 1047 | #define ASN1_R_EXPLICIT_LENGTH_MISMATCH 119 |
1104 | #define ASN1_R_EXPECTING_A_TIME 152 | 1048 | #define ASN1_R_EXPLICIT_TAG_NOT_CONSTRUCTED 120 |
1105 | #define ASN1_R_EXPECTING_A_UTCTIME 118 | 1049 | #define ASN1_R_FIELD_MISSING 121 |
1106 | #define ASN1_R_FIRST_NUM_TOO_LARGE 119 | 1050 | #define ASN1_R_FIRST_NUM_TOO_LARGE 122 |
1107 | #define ASN1_R_GENERALIZEDTIME_TOO_LONG 153 | 1051 | #define ASN1_R_HEADER_TOO_LONG 123 |
1108 | #define ASN1_R_HEADER_TOO_LONG 120 | 1052 | #define ASN1_R_ILLEGAL_CHARACTERS 124 |
1109 | #define ASN1_R_ILLEGAL_CHARACTERS 158 | 1053 | #define ASN1_R_ILLEGAL_NULL 125 |
1110 | #define ASN1_R_INVALID_BMPSTRING_LENGTH 159 | 1054 | #define ASN1_R_ILLEGAL_OPTIONAL_ANY 126 |
1111 | #define ASN1_R_INVALID_DIGIT 121 | 1055 | #define ASN1_R_ILLEGAL_OPTIONS_ON_ITEM_TEMPLATE 170 |
1112 | #define ASN1_R_INVALID_SEPARATOR 122 | 1056 | #define ASN1_R_ILLEGAL_TAGGED_ANY 127 |
1113 | #define ASN1_R_INVALID_TIME_FORMAT 123 | 1057 | #define ASN1_R_INTEGER_TOO_LARGE_FOR_LONG 128 |
1114 | #define ASN1_R_INVALID_UNIVERSALSTRING_LENGTH 160 | 1058 | #define ASN1_R_INVALID_BMPSTRING_LENGTH 129 |
1115 | #define ASN1_R_INVALID_UTF8STRING 161 | 1059 | #define ASN1_R_INVALID_DIGIT 130 |
1116 | #define ASN1_R_IV_TOO_LARGE 124 | 1060 | #define ASN1_R_INVALID_SEPARATOR 131 |
1117 | #define ASN1_R_LENGTH_ERROR 125 | 1061 | #define ASN1_R_INVALID_TIME_FORMAT 132 |
1118 | #define ASN1_R_MISSING_SECOND_NUMBER 126 | 1062 | #define ASN1_R_INVALID_UNIVERSALSTRING_LENGTH 133 |
1119 | #define ASN1_R_NON_HEX_CHARACTERS 127 | 1063 | #define ASN1_R_INVALID_UTF8STRING 134 |
1120 | #define ASN1_R_NOT_ENOUGH_DATA 128 | 1064 | #define ASN1_R_IV_TOO_LARGE 135 |
1121 | #define ASN1_R_NULL_IS_WRONG_LENGTH 165 | 1065 | #define ASN1_R_LENGTH_ERROR 136 |
1122 | #define ASN1_R_ODD_NUMBER_OF_CHARS 129 | 1066 | #define ASN1_R_MISSING_EOC 137 |
1123 | #define ASN1_R_PARSING 130 | 1067 | #define ASN1_R_MISSING_SECOND_NUMBER 138 |
1124 | #define ASN1_R_PRIVATE_KEY_HEADER_MISSING 131 | 1068 | #define ASN1_R_MSTRING_NOT_UNIVERSAL 139 |
1125 | #define ASN1_R_SECOND_NUMBER_TOO_LARGE 132 | 1069 | #define ASN1_R_MSTRING_WRONG_TAG 140 |
1126 | #define ASN1_R_SHORT_LINE 133 | 1070 | #define ASN1_R_NON_HEX_CHARACTERS 141 |
1127 | #define ASN1_R_STRING_TOO_LONG 163 | 1071 | #define ASN1_R_NOT_ENOUGH_DATA 142 |
1128 | #define ASN1_R_STRING_TOO_SHORT 134 | 1072 | #define ASN1_R_NO_MATCHING_CHOICE_TYPE 143 |
1129 | #define ASN1_R_TAG_VALUE_TOO_HIGH 135 | 1073 | #define ASN1_R_NULL_IS_WRONG_LENGTH 144 |
1130 | #define ASN1_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD 136 | 1074 | #define ASN1_R_ODD_NUMBER_OF_CHARS 145 |
1131 | #define ASN1_R_TOO_LONG 137 | 1075 | #define ASN1_R_PRIVATE_KEY_HEADER_MISSING 146 |
1132 | #define ASN1_R_UNABLE_TO_DECODE_RSA_KEY 138 | 1076 | #define ASN1_R_SECOND_NUMBER_TOO_LARGE 147 |
1133 | #define ASN1_R_UNABLE_TO_DECODE_RSA_PRIVATE_KEY 139 | 1077 | #define ASN1_R_SEQUENCE_LENGTH_MISMATCH 148 |
1134 | #define ASN1_R_UNKNOWN_ATTRIBUTE_TYPE 140 | 1078 | #define ASN1_R_SEQUENCE_NOT_CONSTRUCTED 149 |
1135 | #define ASN1_R_UNKNOWN_FORMAT 162 | 1079 | #define ASN1_R_SHORT_LINE 150 |
1136 | #define ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM 141 | 1080 | #define ASN1_R_STRING_TOO_LONG 151 |
1137 | #define ASN1_R_UNKNOWN_OBJECT_TYPE 142 | 1081 | #define ASN1_R_STRING_TOO_SHORT 152 |
1138 | #define ASN1_R_UNKNOWN_PUBLIC_KEY_TYPE 143 | 1082 | #define ASN1_R_TAG_VALUE_TOO_HIGH 153 |
1139 | #define ASN1_R_UNSUPPORTED_CIPHER 144 | 1083 | #define ASN1_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD 154 |
1140 | #define ASN1_R_UNSUPPORTED_ENCRYPTION_ALGORITHM 145 | 1084 | #define ASN1_R_TOO_LONG 155 |
1141 | #define ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE 146 | 1085 | #define ASN1_R_TYPE_NOT_CONSTRUCTED 156 |
1142 | #define ASN1_R_UTCTIME_TOO_LONG 147 | 1086 | #define ASN1_R_UNABLE_TO_DECODE_RSA_KEY 157 |
1143 | #define ASN1_R_WRONG_PRINTABLE_TYPE 148 | 1087 | #define ASN1_R_UNABLE_TO_DECODE_RSA_PRIVATE_KEY 158 |
1144 | #define ASN1_R_WRONG_TAG 149 | 1088 | #define ASN1_R_UNEXPECTED_EOC 159 |
1145 | #define ASN1_R_WRONG_TYPE 150 | 1089 | #define ASN1_R_UNKNOWN_FORMAT 160 |
1090 | #define ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM 161 | ||
1091 | #define ASN1_R_UNKNOWN_OBJECT_TYPE 162 | ||
1092 | #define ASN1_R_UNKNOWN_PUBLIC_KEY_TYPE 163 | ||
1093 | #define ASN1_R_UNSUPPORTED_ANY_DEFINED_BY_TYPE 164 | ||
1094 | #define ASN1_R_UNSUPPORTED_CIPHER 165 | ||
1095 | #define ASN1_R_UNSUPPORTED_ENCRYPTION_ALGORITHM 166 | ||
1096 | #define ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE 167 | ||
1097 | #define ASN1_R_WRONG_TAG 168 | ||
1098 | #define ASN1_R_WRONG_TYPE 169 | ||
1146 | 1099 | ||
1147 | #ifdef __cplusplus | 1100 | #ifdef __cplusplus |
1148 | } | 1101 | } |
1149 | #endif | 1102 | #endif |
1150 | #endif | 1103 | #endif |
1151 | |||