monotone

monotone Mtn Source Tree

Root/botan/enums.h

1/*************************************************
2* Enumerations Header File *
3* (C) 1999-2007 The Botan Project *
4*************************************************/
5
6#ifndef BOTAN_ENUMS_H__
7#define BOTAN_ENUMS_H__
8
9namespace Botan {
10
11/*************************************************
12* ASN.1 Type and Class Tags *
13*************************************************/
14enum ASN1_Tag {
15 UNIVERSAL = 0x00,
16 APPLICATION = 0x40,
17 CONTEXT_SPECIFIC = 0x80,
18 PRIVATE = 0xC0,
19
20 CONSTRUCTED = 0x20,
21
22 EOC = 0x00,
23 BOOLEAN = 0x01,
24 INTEGER = 0x02,
25 BIT_STRING = 0x03,
26 OCTET_STRING = 0x04,
27 NULL_TAG = 0x05,
28 OBJECT_ID = 0x06,
29 ENUMERATED = 0x0A,
30 SEQUENCE = 0x10,
31 SET = 0x11,
32
33 UTF8_STRING = 0x0C,
34 NUMERIC_STRING = 0x12,
35 PRINTABLE_STRING = 0x13,
36 T61_STRING = 0x14,
37 IA5_STRING = 0x16,
38 VISIBLE_STRING = 0x1A,
39 BMP_STRING = 0x1E,
40
41 UTC_TIME = 0x17,
42 GENERALIZED_TIME = 0x18,
43
44 NO_OBJECT = 0xFF00,
45 DIRECTORY_STRING = 0xFF01
46};
47
48/*************************************************
49* X.509v3 Key Constraints *
50*************************************************/
51enum Key_Constraints {
52 NO_CONSTRAINTS = 0,
53 DIGITAL_SIGNATURE = 32768,
54 NON_REPUDIATION = 16384,
55 KEY_ENCIPHERMENT = 8192,
56 DATA_ENCIPHERMENT = 4096,
57 KEY_AGREEMENT = 2048,
58 KEY_CERT_SIGN = 1024,
59 CRL_SIGN = 512,
60 ENCIPHER_ONLY = 256,
61 DECIPHER_ONLY = 128
62};
63
64/*************************************************
65* X.509v2 CRL Reason Code *
66*************************************************/
67enum CRL_Code {
68 UNSPECIFIED = 0,
69 KEY_COMPROMISE = 1,
70 CA_COMPROMISE = 2,
71 AFFILIATION_CHANGED = 3,
72 SUPERSEDED = 4,
73 CESSATION_OF_OPERATION = 5,
74 CERTIFICATE_HOLD = 6,
75 REMOVE_FROM_CRL = 8,
76 PRIVLEDGE_WITHDRAWN = 9,
77 AA_COMPROMISE = 10,
78
79 DELETE_CRL_ENTRY = 0xFF00,
80 OCSP_GOOD = 0xFF01,
81 OCSP_UNKNOWN = 0xFF02
82};
83
84/*************************************************
85* Various Other Enumerations *
86*************************************************/
87enum Decoder_Checking { NONE, IGNORE_WS, FULL_CHECK };
88
89enum X509_Encoding { RAW_BER, PEM };
90
91enum Cipher_Dir { ENCRYPTION, DECRYPTION };
92
93enum Signature_Format { IEEE_1363, DER_SEQUENCE };
94
95enum Character_Set {
96 LOCAL_CHARSET,
97 UCS2_CHARSET,
98 UTF8_CHARSET,
99 LATIN1_CHARSET
100};
101
102/*************************************************
103* Pulse Function *
104*************************************************/
105enum Pulse_Type {
106 GENERAL_PULSE,
107
108 PIPE_WRITE,
109
110 PRIME_SEARCHING,
111 PRIME_SIEVING,
112 PRIME_PASSED_SIEVE,
113 PRIME_TESTING,
114 PRIME_FOUND
115};
116
117static const u32bit NO_CERT_PATH_LIMIT = 0xFFFFFFF0;
118
119}
120
121#endif

Archive Download this file

Branches

Tags

Quick Links:     www.monotone.ca    -     Downloads    -     Documentation    -     Wiki    -     Code Forge    -     Build Status