source: frontend/node_modules/node-forge/lib/oids.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 12 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 6.7 KB
RevLine 
[9af201e]1/**
2 * Object IDs for ASN.1.
3 *
4 * @author Dave Longley
5 *
6 * Copyright (c) 2010-2013 Digital Bazaar, Inc.
7 */
8var forge = require('./forge');
9
10forge.pki = forge.pki || {};
11var oids = module.exports = forge.pki.oids = forge.oids = forge.oids || {};
12
13// set id to name mapping and name to id mapping
14function _IN(id, name) {
15 oids[id] = name;
16 oids[name] = id;
17}
18// set id to name mapping only
19function _I_(id, name) {
20 oids[id] = name;
21}
22
23// algorithm OIDs
24_IN('1.2.840.113549.1.1.1', 'rsaEncryption');
25// Note: md2 & md4 not implemented
26//_IN('1.2.840.113549.1.1.2', 'md2WithRSAEncryption');
27//_IN('1.2.840.113549.1.1.3', 'md4WithRSAEncryption');
28_IN('1.2.840.113549.1.1.4', 'md5WithRSAEncryption');
29_IN('1.2.840.113549.1.1.5', 'sha1WithRSAEncryption');
30_IN('1.2.840.113549.1.1.7', 'RSAES-OAEP');
31_IN('1.2.840.113549.1.1.8', 'mgf1');
32_IN('1.2.840.113549.1.1.9', 'pSpecified');
33_IN('1.2.840.113549.1.1.10', 'RSASSA-PSS');
34_IN('1.2.840.113549.1.1.11', 'sha256WithRSAEncryption');
35_IN('1.2.840.113549.1.1.12', 'sha384WithRSAEncryption');
36_IN('1.2.840.113549.1.1.13', 'sha512WithRSAEncryption');
37// Edwards-curve Digital Signature Algorithm (EdDSA) Ed25519
38_IN('1.3.101.112', 'EdDSA25519');
39
40_IN('1.2.840.10040.4.3', 'dsa-with-sha1');
41
42_IN('1.3.14.3.2.7', 'desCBC');
43
44_IN('1.3.14.3.2.26', 'sha1');
45// Deprecated equivalent of sha1WithRSAEncryption
46_IN('1.3.14.3.2.29', 'sha1WithRSASignature');
47_IN('2.16.840.1.101.3.4.2.1', 'sha256');
48_IN('2.16.840.1.101.3.4.2.2', 'sha384');
49_IN('2.16.840.1.101.3.4.2.3', 'sha512');
50_IN('2.16.840.1.101.3.4.2.4', 'sha224');
51_IN('2.16.840.1.101.3.4.2.5', 'sha512-224');
52_IN('2.16.840.1.101.3.4.2.6', 'sha512-256');
53_IN('1.2.840.113549.2.2', 'md2');
54_IN('1.2.840.113549.2.5', 'md5');
55
56// pkcs#7 content types
57_IN('1.2.840.113549.1.7.1', 'data');
58_IN('1.2.840.113549.1.7.2', 'signedData');
59_IN('1.2.840.113549.1.7.3', 'envelopedData');
60_IN('1.2.840.113549.1.7.4', 'signedAndEnvelopedData');
61_IN('1.2.840.113549.1.7.5', 'digestedData');
62_IN('1.2.840.113549.1.7.6', 'encryptedData');
63
64// pkcs#9 oids
65_IN('1.2.840.113549.1.9.1', 'emailAddress');
66_IN('1.2.840.113549.1.9.2', 'unstructuredName');
67_IN('1.2.840.113549.1.9.3', 'contentType');
68_IN('1.2.840.113549.1.9.4', 'messageDigest');
69_IN('1.2.840.113549.1.9.5', 'signingTime');
70_IN('1.2.840.113549.1.9.6', 'counterSignature');
71_IN('1.2.840.113549.1.9.7', 'challengePassword');
72_IN('1.2.840.113549.1.9.8', 'unstructuredAddress');
73_IN('1.2.840.113549.1.9.14', 'extensionRequest');
74
75_IN('1.2.840.113549.1.9.20', 'friendlyName');
76_IN('1.2.840.113549.1.9.21', 'localKeyId');
77_IN('1.2.840.113549.1.9.22.1', 'x509Certificate');
78
79// pkcs#12 safe bags
80_IN('1.2.840.113549.1.12.10.1.1', 'keyBag');
81_IN('1.2.840.113549.1.12.10.1.2', 'pkcs8ShroudedKeyBag');
82_IN('1.2.840.113549.1.12.10.1.3', 'certBag');
83_IN('1.2.840.113549.1.12.10.1.4', 'crlBag');
84_IN('1.2.840.113549.1.12.10.1.5', 'secretBag');
85_IN('1.2.840.113549.1.12.10.1.6', 'safeContentsBag');
86
87// password-based-encryption for pkcs#12
88_IN('1.2.840.113549.1.5.13', 'pkcs5PBES2');
89_IN('1.2.840.113549.1.5.12', 'pkcs5PBKDF2');
90
91_IN('1.2.840.113549.1.12.1.1', 'pbeWithSHAAnd128BitRC4');
92_IN('1.2.840.113549.1.12.1.2', 'pbeWithSHAAnd40BitRC4');
93_IN('1.2.840.113549.1.12.1.3', 'pbeWithSHAAnd3-KeyTripleDES-CBC');
94_IN('1.2.840.113549.1.12.1.4', 'pbeWithSHAAnd2-KeyTripleDES-CBC');
95_IN('1.2.840.113549.1.12.1.5', 'pbeWithSHAAnd128BitRC2-CBC');
96_IN('1.2.840.113549.1.12.1.6', 'pbewithSHAAnd40BitRC2-CBC');
97
98// hmac OIDs
99_IN('1.2.840.113549.2.7', 'hmacWithSHA1');
100_IN('1.2.840.113549.2.8', 'hmacWithSHA224');
101_IN('1.2.840.113549.2.9', 'hmacWithSHA256');
102_IN('1.2.840.113549.2.10', 'hmacWithSHA384');
103_IN('1.2.840.113549.2.11', 'hmacWithSHA512');
104
105// symmetric key algorithm oids
106_IN('1.2.840.113549.3.7', 'des-EDE3-CBC');
107_IN('2.16.840.1.101.3.4.1.2', 'aes128-CBC');
108_IN('2.16.840.1.101.3.4.1.22', 'aes192-CBC');
109_IN('2.16.840.1.101.3.4.1.42', 'aes256-CBC');
110
111// certificate issuer/subject OIDs
112_IN('2.5.4.3', 'commonName');
113_IN('2.5.4.4', 'surname');
114_IN('2.5.4.5', 'serialNumber');
115_IN('2.5.4.6', 'countryName');
116_IN('2.5.4.7', 'localityName');
117_IN('2.5.4.8', 'stateOrProvinceName');
118_IN('2.5.4.9', 'streetAddress');
119_IN('2.5.4.10', 'organizationName');
120_IN('2.5.4.11', 'organizationalUnitName');
121_IN('2.5.4.12', 'title');
122_IN('2.5.4.13', 'description');
123_IN('2.5.4.15', 'businessCategory');
124_IN('2.5.4.17', 'postalCode');
125_IN('2.5.4.42', 'givenName');
126_IN('2.5.4.65', 'pseudonym');
127_IN('1.3.6.1.4.1.311.60.2.1.2', 'jurisdictionOfIncorporationStateOrProvinceName');
128_IN('1.3.6.1.4.1.311.60.2.1.3', 'jurisdictionOfIncorporationCountryName');
129
130// X.509 extension OIDs
131_IN('2.16.840.1.113730.1.1', 'nsCertType');
132_IN('2.16.840.1.113730.1.13', 'nsComment'); // deprecated in theory; still widely used
133_I_('2.5.29.1', 'authorityKeyIdentifier'); // deprecated, use .35
134_I_('2.5.29.2', 'keyAttributes'); // obsolete use .37 or .15
135_I_('2.5.29.3', 'certificatePolicies'); // deprecated, use .32
136_I_('2.5.29.4', 'keyUsageRestriction'); // obsolete use .37 or .15
137_I_('2.5.29.5', 'policyMapping'); // deprecated use .33
138_I_('2.5.29.6', 'subtreesConstraint'); // obsolete use .30
139_I_('2.5.29.7', 'subjectAltName'); // deprecated use .17
140_I_('2.5.29.8', 'issuerAltName'); // deprecated use .18
141_I_('2.5.29.9', 'subjectDirectoryAttributes');
142_I_('2.5.29.10', 'basicConstraints'); // deprecated use .19
143_I_('2.5.29.11', 'nameConstraints'); // deprecated use .30
144_I_('2.5.29.12', 'policyConstraints'); // deprecated use .36
145_I_('2.5.29.13', 'basicConstraints'); // deprecated use .19
146_IN('2.5.29.14', 'subjectKeyIdentifier');
147_IN('2.5.29.15', 'keyUsage');
148_I_('2.5.29.16', 'privateKeyUsagePeriod');
149_IN('2.5.29.17', 'subjectAltName');
150_IN('2.5.29.18', 'issuerAltName');
151_IN('2.5.29.19', 'basicConstraints');
152_I_('2.5.29.20', 'cRLNumber');
153_I_('2.5.29.21', 'cRLReason');
154_I_('2.5.29.22', 'expirationDate');
155_I_('2.5.29.23', 'instructionCode');
156_I_('2.5.29.24', 'invalidityDate');
157_I_('2.5.29.25', 'cRLDistributionPoints'); // deprecated use .31
158_I_('2.5.29.26', 'issuingDistributionPoint'); // deprecated use .28
159_I_('2.5.29.27', 'deltaCRLIndicator');
160_I_('2.5.29.28', 'issuingDistributionPoint');
161_I_('2.5.29.29', 'certificateIssuer');
162_I_('2.5.29.30', 'nameConstraints');
163_IN('2.5.29.31', 'cRLDistributionPoints');
164_IN('2.5.29.32', 'certificatePolicies');
165_I_('2.5.29.33', 'policyMappings');
166_I_('2.5.29.34', 'policyConstraints'); // deprecated use .36
167_IN('2.5.29.35', 'authorityKeyIdentifier');
168_I_('2.5.29.36', 'policyConstraints');
169_IN('2.5.29.37', 'extKeyUsage');
170_I_('2.5.29.46', 'freshestCRL');
171_I_('2.5.29.54', 'inhibitAnyPolicy');
172
173// extKeyUsage purposes
174_IN('1.3.6.1.4.1.11129.2.4.2', 'timestampList');
175_IN('1.3.6.1.5.5.7.1.1', 'authorityInfoAccess');
176_IN('1.3.6.1.5.5.7.3.1', 'serverAuth');
177_IN('1.3.6.1.5.5.7.3.2', 'clientAuth');
178_IN('1.3.6.1.5.5.7.3.3', 'codeSigning');
179_IN('1.3.6.1.5.5.7.3.4', 'emailProtection');
180_IN('1.3.6.1.5.5.7.3.8', 'timeStamping');
Note: See TracBrowser for help on using the repository browser.