Generate obj_dat.h in "make update".
[openssl.git] / crypto / objects / objects.h
index e9a8f47a83f8e0cf5213230c2153b7a963753096..e2587a8a684efa766db76380736f1ae82bba3aaa 100644 (file)
@@ -384,10 +384,13 @@ extern "C" {
 #define NID_pbeWithSHA1AndRC2_CBC      68
 #define OBJ_pbeWithSHA1AndRC2_CBC      OBJ_pkcs,5L,11L 
 
-/* proposed by microsoft to RSA */
-#define LN_pbeWithSHA1AndRC4           "pbeWithSHA1AndRC4"
-#define NID_pbeWithSHA1AndRC4          69
-#define OBJ_pbeWithSHA1AndRC4          OBJ_pkcs,5L,12L 
+/* proposed by microsoft to RSA as pbeWithSHA1AndRC4: it is now
+ * defined explicitly in PKCS#5 v2.0 as id-PBKDF2 which is something
+ * completely different.
+ */
+#define LN_id_pbkdf2                   "PBKDF2"
+#define NID_id_pbkdf2                  69
+#define OBJ_id_pbkdf2                  OBJ_pkcs,5L,12L 
 
 #define SN_dsaWithSHA1_2               "DSA-SHA1-old"
 #define LN_dsaWithSHA1_2               "dsaWithSHA1-old"
@@ -658,12 +661,12 @@ extern "C" {
 #define SN_rle_compression             "RLE"
 #define LN_rle_compression             "run length compression"
 #define NID_rle_compression            124
-#define OBJ_rle_compression            1L,1L,1L,1L,666L.1L
+#define OBJ_rle_compression            1L,1L,1L,1L,666L,1L
 
 #define SN_zlib_compression            "ZLIB"
 #define LN_zlib_compression            "zlib compression"
 #define NID_zlib_compression           125
-#define OBJ_zlib_compression           1L,1L,1L,1L,666L.2L
+#define OBJ_zlib_compression           1L,1L,1L,1L,666L,2L
 
 #define SN_ext_key_usage               "extendedKeyUsage"
 #define LN_ext_key_usage               "X509v3 Extended Key Usage"
@@ -854,8 +857,53 @@ extern "C" {
 #define NID_hmacWithSHA1       163
 #define OBJ_hmacWithSHA1       OBJ_rsadsi,2L,7L
 
-#include "bio.h"
-#include "asn1.h"
+/* Policy Qualifier Ids */
+
+#define LN_id_qt_cps           "Policy Qualifier CPS"
+#define SN_id_qt_cps           "id-qt-cps"
+#define NID_id_qt_cps          164
+#define OBJ_id_qt_cps          OBJ_id_pkix,2L,1L
+
+#define LN_id_qt_unotice       "Policy Qualifier User Notice"
+#define SN_id_qt_unotice       "id-qt-unotice"
+#define NID_id_qt_unotice      165
+#define OBJ_id_qt_unotice      OBJ_id_pkix,2L,2L
+
+#define SN_rc2_64_cbc                  "RC2-64-CBC"
+#define LN_rc2_64_cbc                  "rc2-64-cbc"
+#define NID_rc2_64_cbc                 166
+
+#define SN_SMIMECapabilities           "SMIME-CAPS"
+#define LN_SMIMECapabilities           "S/MIME Capabilities"
+#define NID_SMIMECapabilities          167
+#define OBJ_SMIMECapabilities          OBJ_id_pkcs9,15L
+
+#define LN_pbeWithMD2AndRC2_CBC                "pbeWithMD2AndRC2-CBC"
+#define NID_pbeWithMD2AndRC2_CBC       168
+#define OBJ_pbeWithMD2AndRC2_CBC       OBJ_pkcs,5L,4L
+
+#define LN_pbeWithMD5AndRC2_CBC                "pbeWithMD5AndRC2-CBC"
+#define NID_pbeWithMD5AndRC2_CBC       169
+#define OBJ_pbeWithMD5AndRC2_CBC       OBJ_pkcs,5L,6L
+
+#define LN_pbeWithSHA1AndDES_CBC       "pbeWithSHA1AndDES-CBC"
+#define NID_pbeWithSHA1AndDES_CBC      170
+#define OBJ_pbeWithSHA1AndDES_CBC      OBJ_pkcs,5L,10L
+
+/* Extension request OIDs */
+
+#define LN_ms_ext_req                  "Microsoft Extension Request"
+#define SN_ms_ext_req                  "msExtReq"
+#define NID_ms_ext_req                 171
+#define OBJ_ms_ext_req                 1L,3L,6L,1L,4L,1L,311L,2L,1L,14L
+
+#define LN_ext_req                     "Extension Request"
+#define SN_ext_req                     "extReq"
+#define NID_ext_req                    172
+#define OBJ_ext_req                    OBJ_pkcs9,14L
+
+#include <openssl/bio.h>
+#include <openssl/asn1.h>
 
 #define        OBJ_NAME_TYPE_UNDEF             0x00
 #define        OBJ_NAME_TYPE_MD_METH           0x01
@@ -871,31 +919,31 @@ typedef struct obj_name_st
        {
        int type;
        int alias;
-       char *name;
-       char *data;
+       const char *name;
+       const char *data;
        } OBJ_NAME;
 
 #define                OBJ_create_and_add_object(a,b,c) OBJ_create(a,b,c)
 
-#ifndef NOPROTO
 
 int OBJ_NAME_init(void);
 int OBJ_NAME_new_index(unsigned long (*hash_func)(),int (*cmp_func)(),
        void (*free_func)());
-char *OBJ_NAME_get(char *name,int type);
-int OBJ_NAME_add(char *name,int type,char *data);
-int OBJ_NAME_remove(char *name,int type);
+const char *OBJ_NAME_get(const char *name,int type);
+int OBJ_NAME_add(const char *name,int type,const char *data);
+int OBJ_NAME_remove(const char *name,int type);
 void OBJ_NAME_cleanup(int type); /* -1 for everything */
 
 ASN1_OBJECT *  OBJ_dup(ASN1_OBJECT *o);
 ASN1_OBJECT *  OBJ_nid2obj(int n);
-char *         OBJ_nid2ln(int n);
-char *         OBJ_nid2sn(int n);
+const char *   OBJ_nid2ln(int n);
+const char *   OBJ_nid2sn(int n);
 int            OBJ_obj2nid(ASN1_OBJECT *o);
-ASN1_OBJECT *  OBJ_txt2obj(char *s, int no_name);
+ASN1_OBJECT *  OBJ_txt2obj(const char *s, int no_name);
+int    OBJ_obj2txt(char *buf, int buf_len, ASN1_OBJECT *a, int no_name);
 int            OBJ_txt2nid(char *s);
-int            OBJ_ln2nid(char *s);
-int            OBJ_sn2nid(char *s);
+int            OBJ_ln2nid(const char *s);
+int            OBJ_sn2nid(const char *s);
 int            OBJ_cmp(ASN1_OBJECT *a,ASN1_OBJECT *b);
 char *         OBJ_bsearch(char *key,char *base,int num,int size,int (*cmp)());
 
@@ -907,38 +955,11 @@ int               OBJ_create(char *oid,char *sn,char *ln);
 void           OBJ_cleanup(void );
 int            OBJ_create_objects(BIO *in);
 
-#else
-
-int OBJ_NAME_init();
-int OBJ_NAME_new_index();
-char *OBJ_NAME_get();
-int OBJ_NAME_add();
-int OBJ_NAME_remove();
-void OBJ_NAME_cleanup();
-
-ASN1_OBJECT *  OBJ_dup();
-ASN1_OBJECT *  OBJ_nid2obj();
-char *         OBJ_nid2ln();
-char *         OBJ_nid2sn();
-int            OBJ_obj2nid();
-ASN1_OBJECT *  OBJ_txt2obj();
-int            OBJ_txt2nid();
-int            OBJ_ln2nid();
-int            OBJ_sn2nid();
-int            OBJ_cmp();
-char *         OBJ_bsearch();
-
-void           ERR_load_OBJ_strings();
-
-int            OBJ_new_nid();
-int            OBJ_add_object();
-int            OBJ_create();
-void           OBJ_cleanup();
-int            OBJ_create_objects();
-
-#endif
-
 /* BEGIN ERROR CODES */
+/* The following lines are auto generated by the script mkerr.pl. Any changes
+ * made after this point may be overwritten when the script is next run.
+ */
+
 /* Error codes for the OBJ functions. */
 
 /* Function codes. */
@@ -951,7 +972,7 @@ int         OBJ_create_objects();
 /* Reason codes. */
 #define OBJ_R_MALLOC_FAILURE                            100
 #define OBJ_R_UNKNOWN_NID                               101
+
 #ifdef  __cplusplus
 }
 #endif