Move internal only ASN.1 functions to asn1_locl.h
authorDr. Stephen Henson <steve@openssl.org>
Wed, 25 Mar 2015 15:42:56 +0000 (15:42 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Wed, 25 Mar 2015 15:48:16 +0000 (15:48 +0000)
Reviewed-by: Richard Levitte <levitte@openssl.org>
crypto/asn1/asn1_locl.h
crypto/asn1/asn1t.h
crypto/asn1/tasn_dec.c
crypto/asn1/tasn_enc.c
crypto/asn1/tasn_fre.c
crypto/asn1/tasn_new.c
crypto/asn1/tasn_prn.c
crypto/asn1/tasn_utl.c

index ec4c0e8052be36652d9f85ef41bd2dcb93c30918..79d76ecc72b8cb780aad6f77671e6f94073c982e 100644 (file)
@@ -104,3 +104,26 @@ struct x509_crl_method_st {
                        ASN1_INTEGER *ser, X509_NAME *issuer);
     int (*crl_verify) (X509_CRL *crl, EVP_PKEY *pk);
 };
+
+int asn1_ex_i2c(ASN1_VALUE **pval, unsigned char *cont, int *putype,
+                const ASN1_ITEM *it);
+int asn1_ex_c2i(ASN1_VALUE **pval, const unsigned char *cont, int len,
+                int utype, char *free_cont, const ASN1_ITEM *it);
+
+int asn1_get_choice_selector(ASN1_VALUE **pval, const ASN1_ITEM *it);
+int asn1_set_choice_selector(ASN1_VALUE **pval, int value,
+                             const ASN1_ITEM *it);
+
+ASN1_VALUE **asn1_get_field_ptr(ASN1_VALUE **pval, const ASN1_TEMPLATE *tt);
+
+const ASN1_TEMPLATE *asn1_do_adb(ASN1_VALUE **pval, const ASN1_TEMPLATE *tt,
+                                 int nullerr);
+
+int asn1_do_lock(ASN1_VALUE **pval, int op, const ASN1_ITEM *it);
+
+void asn1_enc_init(ASN1_VALUE **pval, const ASN1_ITEM *it);
+void asn1_enc_free(ASN1_VALUE **pval, const ASN1_ITEM *it);
+int asn1_enc_restore(int *len, unsigned char **out, ASN1_VALUE **pval,
+                     const ASN1_ITEM *it);
+int asn1_enc_save(ASN1_VALUE **pval, const unsigned char *in, int inlen,
+                  const ASN1_ITEM *it);
index 3dcca325de80912e7f1ac63b32bec67add049d60..e6f6d79c7ef87d74b627cb30bc7cd070cb1355a7 100644 (file)
@@ -910,29 +910,6 @@ int ASN1_template_i2d(ASN1_VALUE **pval, unsigned char **out,
                       const ASN1_TEMPLATE *tt);
 void ASN1_primitive_free(ASN1_VALUE **pval, const ASN1_ITEM *it);
 
-int asn1_ex_i2c(ASN1_VALUE **pval, unsigned char *cont, int *putype,
-                const ASN1_ITEM *it);
-int asn1_ex_c2i(ASN1_VALUE **pval, const unsigned char *cont, int len,
-                int utype, char *free_cont, const ASN1_ITEM *it);
-
-int asn1_get_choice_selector(ASN1_VALUE **pval, const ASN1_ITEM *it);
-int asn1_set_choice_selector(ASN1_VALUE **pval, int value,
-                             const ASN1_ITEM *it);
-
-ASN1_VALUE **asn1_get_field_ptr(ASN1_VALUE **pval, const ASN1_TEMPLATE *tt);
-
-const ASN1_TEMPLATE *asn1_do_adb(ASN1_VALUE **pval, const ASN1_TEMPLATE *tt,
-                                 int nullerr);
-
-int asn1_do_lock(ASN1_VALUE **pval, int op, const ASN1_ITEM *it);
-
-void asn1_enc_init(ASN1_VALUE **pval, const ASN1_ITEM *it);
-void asn1_enc_free(ASN1_VALUE **pval, const ASN1_ITEM *it);
-int asn1_enc_restore(int *len, unsigned char **out, ASN1_VALUE **pval,
-                     const ASN1_ITEM *it);
-int asn1_enc_save(ASN1_VALUE **pval, const unsigned char *in, int inlen,
-                  const ASN1_ITEM *it);
-
 #ifdef  __cplusplus
 }
 #endif
index b96c1b58bbf2c1a02ac021100790bb7740e9850e..5111c123bd033988d78911179a9ebd9cfe5eb9ac 100644 (file)
@@ -64,6 +64,7 @@
 #include <openssl/objects.h>
 #include <openssl/buffer.h>
 #include <openssl/err.h>
+#include "asn1_locl.h"
 
 static int asn1_check_eoc(const unsigned char **in, long len);
 static int asn1_find_end(const unsigned char **in, long len, char inf);
index 1d1f838078289cc4b1d57370254e4af305c13fa1..251a8f15b422bab0bdcef75047e3e26a9a1cb1b6 100644 (file)
@@ -64,6 +64,7 @@
 #include <openssl/asn1t.h>
 #include <openssl/objects.h>
 #include "internal/asn1_int.h"
+#include "asn1_locl.h"
 
 static int asn1_i2d_ex_primitive(ASN1_VALUE **pval, unsigned char **out,
                                  const ASN1_ITEM *it, int tag, int aclass);
index bdc26f9bb4bf241f0224bdea2dda9f21bfa93410..6f62fd4a71698c670914a8cb4d666531ea0afeb3 100644 (file)
@@ -61,6 +61,7 @@
 #include <openssl/asn1.h>
 #include <openssl/asn1t.h>
 #include <openssl/objects.h>
+#include "asn1_locl.h"
 
 static void asn1_item_combine_free(ASN1_VALUE **pval, const ASN1_ITEM *it,
                                    int combine);
index 3884897a4e5b4ce2961965e488ae125342e188e8..996a4d5cc6719dc7975898561a3fee100578d7d4 100644 (file)
@@ -63,6 +63,7 @@
 #include <openssl/err.h>
 #include <openssl/asn1t.h>
 #include <string.h>
+#include "asn1_locl.h"
 
 static int asn1_item_ex_combine_new(ASN1_VALUE **pval, const ASN1_ITEM *it,
                                     int combine);
index cb3d35b63da297a502b2c64b7325636b0802aaf2..d1e5ba509a6ca0a7bc7013c6009c2503615a424b 100644 (file)
@@ -66,6 +66,7 @@
 #include <openssl/err.h>
 #include <openssl/x509v3.h>
 #include "internal/asn1_int.h"
+#include "asn1_locl.h"
 
 /*
  * Print routines.
index 2e14c2f8dba0c048fa90540acda42cbfd10b0fca..da7b029799b04926cd8f766d3f6e8adcf1780108 100644 (file)
@@ -63,6 +63,7 @@
 #include <openssl/asn1t.h>
 #include <openssl/objects.h>
 #include <openssl/err.h>
+#include "asn1_locl.h"
 
 /* Utility functions for manipulating fields and offsets */