In Message-ID: <003201bfb332$14a07520$0801a8c0@janm.transactionsite.com>,

"Jan Mikkelsen" <janm@transactionsite.com> correctly states that the
OpenSSL header files have #include's and extern "C"'s in an incorrect
order.  Thusly fixed.
This commit is contained in:
Richard Levitte 2000-05-02 12:16:01 +00:00
parent 22a415478f
commit 82271cee5b
32 changed files with 157 additions and 114 deletions

View File

@ -59,10 +59,6 @@
#ifndef HEADER_ASN1_H #ifndef HEADER_ASN1_H
#define HEADER_ASN1_H #define HEADER_ASN1_H
#ifdef __cplusplus
extern "C" {
#endif
#include <time.h> #include <time.h>
#include <openssl/bn.h> #include <openssl/bn.h>
#include <openssl/stack.h> #include <openssl/stack.h>
@ -72,6 +68,10 @@ extern "C" {
#include <openssl/vms_idhacks.h> #include <openssl/vms_idhacks.h>
#endif #endif
#ifdef __cplusplus
extern "C" {
#endif
#define V_ASN1_UNIVERSAL 0x00 #define V_ASN1_UNIVERSAL 0x00
#define V_ASN1_APPLICATION 0x40 #define V_ASN1_APPLICATION 0x40
#define V_ASN1_CONTEXT_SPECIFIC 0x80 #define V_ASN1_CONTEXT_SPECIFIC 0x80

View File

@ -59,12 +59,12 @@
#ifndef HEADER_ASN1_MAC_H #ifndef HEADER_ASN1_MAC_H
#define HEADER_ASN1_MAC_H #define HEADER_ASN1_MAC_H
#include <openssl/asn1.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/asn1.h>
#ifndef ASN1_MAC_ERR_LIB #ifndef ASN1_MAC_ERR_LIB
#define ASN1_MAC_ERR_LIB ERR_LIB_ASN1 #define ASN1_MAC_ERR_LIB ERR_LIB_ASN1
#endif #endif

View File

@ -59,14 +59,14 @@
#ifndef HEADER_BIO_H #ifndef HEADER_BIO_H
#define HEADER_BIO_H #define HEADER_BIO_H
#ifdef __cplusplus
extern "C" {
#endif
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <openssl/crypto.h> #include <openssl/crypto.h>
#ifdef __cplusplus
extern "C" {
#endif
/* These are the 'types' of BIOs */ /* These are the 'types' of BIOs */
#define BIO_TYPE_NONE 0 #define BIO_TYPE_NONE 0
#define BIO_TYPE_MEM (1|0x0400) #define BIO_TYPE_MEM (1|0x0400)

View File

@ -2,12 +2,12 @@
#ifndef HEADER_COMP_H #ifndef HEADER_COMP_H
#define HEADER_COMP_H #define HEADER_COMP_H
#include <openssl/crypto.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/crypto.h>
typedef struct comp_method_st typedef struct comp_method_st
{ {
int type; /* NID for compression library */ int type; /* NID for compression library */

View File

@ -59,16 +59,16 @@
#ifndef HEADER_CONF_H #ifndef HEADER_CONF_H
#define HEADER_CONF_H #define HEADER_CONF_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/bio.h> #include <openssl/bio.h>
#include <openssl/lhash.h> #include <openssl/lhash.h>
#include <openssl/stack.h> #include <openssl/stack.h>
#include <openssl/safestack.h> #include <openssl/safestack.h>
#include <openssl/e_os.h> #include <openssl/e_os.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct typedef struct
{ {
char *section; char *section;

View File

@ -59,13 +59,13 @@
#ifndef HEADER_CONF_API_H #ifndef HEADER_CONF_API_H
#define HEADER_CONF_API_H #define HEADER_CONF_API_H
#include <openssl/lhash.h>
#include <openssl/conf.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/lhash.h>
#include <openssl/conf.h>
/* Up until OpenSSL 0.9.5a, this was new_section */ /* Up until OpenSSL 0.9.5a, this was new_section */
CONF_VALUE *_CONF_new_section(CONF *conf, char *section); CONF_VALUE *_CONF_new_section(CONF *conf, char *section);
/* Up until OpenSSL 0.9.5a, this was get_section */ /* Up until OpenSSL 0.9.5a, this was get_section */

View File

@ -59,10 +59,6 @@
#ifndef HEADER_DES_H #ifndef HEADER_DES_H
#define HEADER_DES_H #define HEADER_DES_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_DES #ifdef NO_DES
#error DES is disabled. #error DES is disabled.
#endif #endif
@ -75,6 +71,10 @@ extern "C" {
#include <openssl/opensslconf.h> /* DES_LONG */ #include <openssl/opensslconf.h> /* DES_LONG */
#include <openssl/e_os2.h> /* OPENSSL_EXTERN */ #include <openssl/e_os2.h> /* OPENSSL_EXTERN */
#ifdef __cplusplus
extern "C" {
#endif
typedef unsigned char des_cblock[8]; typedef unsigned char des_cblock[8];
typedef /* const */ unsigned char const_des_cblock[8]; typedef /* const */ unsigned char const_des_cblock[8];
/* With "const", gcc 2.8.1 on Solaris thinks that des_cblock * /* With "const", gcc 2.8.1 on Solaris thinks that des_cblock *

View File

@ -59,10 +59,6 @@
#ifndef HEADER_DH_H #ifndef HEADER_DH_H
#define HEADER_DH_H #define HEADER_DH_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_DH #ifdef NO_DH
#error DH is disabled. #error DH is disabled.
#endif #endif
@ -72,6 +68,10 @@ extern "C" {
#define DH_FLAG_CACHE_MONT_P 0x01 #define DH_FLAG_CACHE_MONT_P 0x01
#ifdef __cplusplus
extern "C" {
#endif
typedef struct dh_st DH; typedef struct dh_st DH;
typedef struct dh_method { typedef struct dh_method {

View File

@ -65,10 +65,6 @@
#ifndef HEADER_DSA_H #ifndef HEADER_DSA_H
#define HEADER_DSA_H #define HEADER_DSA_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_DSA #ifdef NO_DSA
#error DSA is disabled. #error DSA is disabled.
#endif #endif
@ -81,6 +77,10 @@ extern "C" {
#define DSA_FLAG_CACHE_MONT_P 0x01 #define DSA_FLAG_CACHE_MONT_P 0x01
#ifdef __cplusplus
extern "C" {
#endif
typedef struct dsa_st DSA; typedef struct dsa_st DSA;
typedef struct DSA_SIG_st typedef struct DSA_SIG_st

View File

@ -59,14 +59,14 @@
#ifndef HEADER_ERR_H #ifndef HEADER_ERR_H
#define HEADER_ERR_H #define HEADER_ERR_H
#ifdef __cplusplus
extern "C" {
#endif
#ifndef NO_FP_API #ifndef NO_FP_API
#include <stdio.h> #include <stdio.h>
#endif #endif
#ifdef __cplusplus
extern "C" {
#endif
/* The following is a bit of a trick to help the object files only contain /* The following is a bit of a trick to help the object files only contain
* the 'name of the file' string once. Since 'err.h' is protected by the * the 'name of the file' string once. Since 'err.h' is protected by the
* HEADER_ERR_H stuff, this should be included only once per file. */ * HEADER_ERR_H stuff, this should be included only once per file. */

View File

@ -59,10 +59,6 @@
#ifndef HEADER_ENVELOPE_H #ifndef HEADER_ENVELOPE_H
#define HEADER_ENVELOPE_H #define HEADER_ENVELOPE_H
#ifdef __cplusplus
extern "C" {
#endif
#ifndef NO_MD2 #ifndef NO_MD2
#include <openssl/md2.h> #include <openssl/md2.h>
#endif #endif
@ -147,6 +143,10 @@ extern "C" {
#define EVP_PKEY_DSA4 NID_dsaWithSHA1_2 #define EVP_PKEY_DSA4 NID_dsaWithSHA1_2
#define EVP_PKEY_DH NID_dhKeyAgreement #define EVP_PKEY_DH NID_dhKeyAgreement
#ifdef __cplusplus
extern "C" {
#endif
/* Type needs to be a bit field /* Type needs to be a bit field
* Sub-type needs to be for variations on the method, as in, can it do * Sub-type needs to be for variations on the method, as in, can it do
* arbitrary encryption.... */ * arbitrary encryption.... */

View File

@ -58,10 +58,6 @@
#ifndef HEADER_HMAC_H #ifndef HEADER_HMAC_H
#define HEADER_HMAC_H #define HEADER_HMAC_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_HMAC #ifdef NO_HMAC
#error HMAC is disabled. #error HMAC is disabled.
#endif #endif
@ -70,6 +66,10 @@ extern "C" {
#define HMAC_MAX_MD_CBLOCK 64 #define HMAC_MAX_MD_CBLOCK 64
#ifdef __cplusplus
extern "C" {
#endif
typedef struct hmac_ctx_st typedef struct hmac_ctx_st
{ {
const EVP_MD *md; const EVP_MD *md;

View File

@ -59,10 +59,6 @@
#ifndef HEADER_IDEA_H #ifndef HEADER_IDEA_H
#define HEADER_IDEA_H #define HEADER_IDEA_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_IDEA #ifdef NO_IDEA
#error IDEA is disabled. #error IDEA is disabled.
#endif #endif
@ -74,6 +70,10 @@ extern "C" {
#define IDEA_BLOCK 8 #define IDEA_BLOCK 8
#define IDEA_KEY_LENGTH 16 #define IDEA_KEY_LENGTH 16
#ifdef __cplusplus
extern "C" {
#endif
typedef struct idea_key_st typedef struct idea_key_st
{ {
IDEA_INT data[9][6]; IDEA_INT data[9][6];

View File

@ -63,14 +63,14 @@
#ifndef HEADER_LHASH_H #ifndef HEADER_LHASH_H
#define HEADER_LHASH_H #define HEADER_LHASH_H
#ifdef __cplusplus
extern "C" {
#endif
#ifndef NO_FP_API #ifndef NO_FP_API
#include <stdio.h> #include <stdio.h>
#endif #endif
#ifdef __cplusplus
extern "C" {
#endif
typedef struct lhash_node_st typedef struct lhash_node_st
{ {
void *data; void *data;

View File

@ -59,10 +59,6 @@
#ifndef HEADER_MD2_H #ifndef HEADER_MD2_H
#define HEADER_MD2_H #define HEADER_MD2_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_MD2 #ifdef NO_MD2
#error MD2 is disabled. #error MD2 is disabled.
#endif #endif
@ -71,6 +67,10 @@ extern "C" {
#define MD2_BLOCK 16 #define MD2_BLOCK 16
#include <openssl/opensslconf.h> /* MD2_INT */ #include <openssl/opensslconf.h> /* MD2_INT */
#ifdef __cplusplus
extern "C" {
#endif
typedef struct MD2state_st typedef struct MD2state_st
{ {
int num; int num;

View File

@ -59,12 +59,12 @@
#ifndef HEADER_MDC2_H #ifndef HEADER_MDC2_H
#define HEADER_MDC2_H #define HEADER_MDC2_H
#include <openssl/des.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/des.h>
#ifdef NO_MDC2 #ifdef NO_MDC2
#error MDC2 is disabled. #error MDC2 is disabled.
#endif #endif

View File

@ -59,10 +59,6 @@
#ifndef HEADER_OBJECTS_H #ifndef HEADER_OBJECTS_H
#define HEADER_OBJECTS_H #define HEADER_OBJECTS_H
#ifdef __cplusplus
extern "C" {
#endif
#define SN_undef "UNDEF" #define SN_undef "UNDEF"
#define LN_undef "undefined" #define LN_undef "undefined"
#define NID_undef 0 #define NID_undef 0
@ -967,6 +963,10 @@ extern "C" {
#define OBJ_NAME_ALIAS 0x8000 #define OBJ_NAME_ALIAS 0x8000
#ifdef __cplusplus
extern "C" {
#endif
typedef struct obj_name_st typedef struct obj_name_st
{ {
int type; int type;

View File

@ -59,14 +59,14 @@
#ifndef HEADER_PEM_H #ifndef HEADER_PEM_H
#define HEADER_PEM_H #define HEADER_PEM_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/evp.h> #include <openssl/evp.h>
#include <openssl/x509.h> #include <openssl/x509.h>
#include <openssl/pem2.h> #include <openssl/pem2.h>
#ifdef __cplusplus
extern "C" {
#endif
#define PEM_BUFSIZE 1024 #define PEM_BUFSIZE 1024
#define PEM_OBJ_UNDEF 0 #define PEM_OBJ_UNDEF 0

View File

@ -57,4 +57,12 @@
* Ben 30 Jan 1999. * Ben 30 Jan 1999.
*/ */
#ifdef __cplusplus
extern "C" {
#endif
void ERR_load_PEM_strings(void); void ERR_load_PEM_strings(void);
#ifdef __cplusplus
}
#endif

View File

@ -59,13 +59,13 @@
#ifndef HEADER_PKCS12_H #ifndef HEADER_PKCS12_H
#define HEADER_PKCS12_H #define HEADER_PKCS12_H
#include <openssl/bio.h>
#include <openssl/x509.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/bio.h>
#include <openssl/x509.h>
#define PKCS12_KEY_ID 1 #define PKCS12_KEY_ID 1
#define PKCS12_IV_ID 2 #define PKCS12_IV_ID 2
#define PKCS12_MAC_ID 3 #define PKCS12_MAC_ID 3

View File

@ -59,10 +59,6 @@
#ifndef HEADER_PKCS7_H #ifndef HEADER_PKCS7_H
#define HEADER_PKCS7_H #define HEADER_PKCS7_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/bio.h> #include <openssl/bio.h>
#include <openssl/x509.h> #include <openssl/x509.h>
@ -70,6 +66,10 @@ extern "C" {
#include <openssl/vms_idhacks.h> #include <openssl/vms_idhacks.h>
#endif #endif
#ifdef __cplusplus
extern "C" {
#endif
#ifdef WIN32 #ifdef WIN32
/* Under Win32 thes are defined in wincrypt.h */ /* Under Win32 thes are defined in wincrypt.h */
#undef PKCS7_ISSUER_AND_SERIAL #undef PKCS7_ISSUER_AND_SERIAL

View File

@ -90,12 +90,26 @@ int RAND_write_file(const char *file);
const char *RAND_file_name(char *file,int num); const char *RAND_file_name(char *file,int num);
int RAND_status(void); int RAND_status(void);
int RAND_egd(const char *path); int RAND_egd(const char *path);
void ERR_load_RAND_strings(void);
#ifdef __cplusplus
}
#endif
#if defined(WINDOWS) || defined(WIN32) #if defined(WINDOWS) || defined(WIN32)
#include <windows.h> #include <windows.h>
#ifdef __cplusplus
extern "C" {
#endif
void RAND_screen(void); void RAND_screen(void);
int RAND_event(UINT, WPARAM, LPARAM); int RAND_event(UINT, WPARAM, LPARAM);
#ifdef __cplusplus
}
#endif
#endif #endif
void ERR_load_RAND_strings(void);
/* BEGIN ERROR CODES */ /* BEGIN ERROR CODES */
/* The following lines are auto generated by the script mkerr.pl. Any changes /* The following lines are auto generated by the script mkerr.pl. Any changes
@ -110,8 +124,5 @@ void ERR_load_RAND_strings(void);
/* Reason codes. */ /* Reason codes. */
#define RAND_R_PRNG_NOT_SEEDED 100 #define RAND_R_PRNG_NOT_SEEDED 100
#ifdef __cplusplus
}
#endif
#endif #endif

View File

@ -59,10 +59,6 @@
#ifndef HEADER_RC2_H #ifndef HEADER_RC2_H
#define HEADER_RC2_H #define HEADER_RC2_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_RC2 #ifdef NO_RC2
#error RC2 is disabled. #error RC2 is disabled.
#endif #endif
@ -74,6 +70,10 @@ extern "C" {
#define RC2_BLOCK 8 #define RC2_BLOCK 8
#define RC2_KEY_LENGTH 16 #define RC2_KEY_LENGTH 16
#ifdef __cplusplus
extern "C" {
#endif
typedef struct rc2_key_st typedef struct rc2_key_st
{ {
RC2_INT data[64]; RC2_INT data[64];

View File

@ -59,16 +59,16 @@
#ifndef HEADER_RC4_H #ifndef HEADER_RC4_H
#define HEADER_RC4_H #define HEADER_RC4_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef NO_RC4 #ifdef NO_RC4
#error RC4 is disabled. #error RC4 is disabled.
#endif #endif
#include <openssl/opensslconf.h> /* RC4_INT */ #include <openssl/opensslconf.h> /* RC4_INT */
#ifdef __cplusplus
extern "C" {
#endif
typedef struct rc4_key_st typedef struct rc4_key_st
{ {
RC4_INT x,y; RC4_INT x,y;

View File

@ -59,10 +59,6 @@
#ifndef HEADER_RSA_H #ifndef HEADER_RSA_H
#define HEADER_RSA_H #define HEADER_RSA_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/bn.h> #include <openssl/bn.h>
#include <openssl/crypto.h> #include <openssl/crypto.h>
@ -70,6 +66,10 @@ extern "C" {
#error RSA is disabled. #error RSA is disabled.
#endif #endif
#ifdef __cplusplus
extern "C" {
#endif
typedef struct rsa_st RSA; typedef struct rsa_st RSA;
typedef struct rsa_meth_st typedef struct rsa_meth_st

View File

@ -59,10 +59,6 @@
#ifndef HEADER_TXT_DB_H #ifndef HEADER_TXT_DB_H
#define HEADER_TXT_DB_H #define HEADER_TXT_DB_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/stack.h> #include <openssl/stack.h>
#include <openssl/lhash.h> #include <openssl/lhash.h>
@ -73,6 +69,10 @@ extern "C" {
#define DB_ERROR_NO_INDEX 4 #define DB_ERROR_NO_INDEX 4
#define DB_ERROR_INSERT_INDEX_CLASH 5 #define DB_ERROR_INSERT_INDEX_CLASH 5
#ifdef __cplusplus
extern "C" {
#endif
typedef struct txt_db_st typedef struct txt_db_st
{ {
int num_fields; int num_fields;

View File

@ -59,10 +59,6 @@
#ifndef HEADER_X509_H #ifndef HEADER_X509_H
#define HEADER_X509_H #define HEADER_X509_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef VMS #ifdef VMS
#undef X509_REVOKED_get_ext_by_critical #undef X509_REVOKED_get_ext_by_critical
#define X509_REVOKED_get_ext_by_critical X509_REVOKED_get_ext_by_critic #define X509_REVOKED_get_ext_by_critical X509_REVOKED_get_ext_by_critic
@ -87,6 +83,10 @@ extern "C" {
#include <openssl/evp.h> #include <openssl/evp.h>
#ifdef __cplusplus
extern "C" {
#endif
#ifdef WIN32 #ifdef WIN32
/* Under Win32 this is defined in wincrypt.h */ /* Under Win32 this is defined in wincrypt.h */
#undef X509_NAME #undef X509_NAME
@ -445,9 +445,17 @@ typedef struct pkcs8_priv_key_info_st
STACK_OF(X509_ATTRIBUTE) *attributes; STACK_OF(X509_ATTRIBUTE) *attributes;
} PKCS8_PRIV_KEY_INFO; } PKCS8_PRIV_KEY_INFO;
#ifdef __cplusplus
}
#endif
#include <openssl/x509_vfy.h> #include <openssl/x509_vfy.h>
#include <openssl/pkcs7.h> #include <openssl/pkcs7.h>
#ifdef __cplusplus
extern "C" {
#endif
#ifdef SSLEAY_MACROS #ifdef SSLEAY_MACROS
#define X509_verify(a,r) ASN1_verify((int (*)())i2d_X509_CINF,a->sig_alg,\ #define X509_verify(a,r) ASN1_verify((int (*)())i2d_X509_CINF,a->sig_alg,\
a->signature,(char *)a->cert_info,r) a->signature,(char *)a->cert_info,r)

View File

@ -65,13 +65,13 @@
#ifndef HEADER_X509_VFY_H #ifndef HEADER_X509_VFY_H
#define HEADER_X509_VFY_H #define HEADER_X509_VFY_H
#include <openssl/bio.h>
#include <openssl/crypto.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/bio.h>
#include <openssl/crypto.h>
/* Outer object */ /* Outer object */
typedef struct x509_hash_dir_st typedef struct x509_hash_dir_st
{ {

View File

@ -58,14 +58,14 @@
#ifndef HEADER_X509V3_H #ifndef HEADER_X509V3_H
#define HEADER_X509V3_H #define HEADER_X509V3_H
#ifdef __cplusplus
extern "C" {
#endif
#include <openssl/bio.h> #include <openssl/bio.h>
#include <openssl/x509.h> #include <openssl/x509.h>
#include <openssl/conf.h> #include <openssl/conf.h>
#ifdef __cplusplus
extern "C" {
#endif
/* Forward reference */ /* Forward reference */
struct v3_ext_method; struct v3_ext_method;
struct v3_ext_ctx; struct v3_ext_ctx;

View File

@ -3,12 +3,12 @@
#ifndef HEADER_E_OS2_H #ifndef HEADER_E_OS2_H
#define HEADER_E_OS2_H #define HEADER_E_OS2_H
#include <openssl/opensslconf.h> /* OPENSSL_UNISTD */
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/opensslconf.h> /* OPENSSL_UNISTD */
#ifdef MSDOS #ifdef MSDOS
# define OPENSSL_UNISTD_IO <io.h> # define OPENSSL_UNISTD_IO <io.h>
# define OPENSSL_DECLARE_EXIT extern void exit(int); # define OPENSSL_DECLARE_EXIT extern void exit(int);

View File

@ -59,13 +59,13 @@
#ifndef HEADER_RSAREF_H #ifndef HEADER_RSAREF_H
#define HEADER_RSAREF_H #define HEADER_RSAREF_H
#ifndef NO_RSA
#include <openssl/rsa.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#ifndef NO_RSA
#include <openssl/rsa.h>
/* RSAeuro */ /* RSAeuro */
/*#define RSAref_MAX_BITS 2048*/ /*#define RSAref_MAX_BITS 2048*/
@ -133,6 +133,10 @@ int R_RandomFinal(RSARandomState *rnd);
void ERR_load_RSAREF_strings(void ); void ERR_load_RSAREF_strings(void );
RSA_METHOD *RSA_PKCS1_RSAref(void ); RSA_METHOD *RSA_PKCS1_RSAref(void );
#ifdef __cplusplus
}
#endif
#endif #endif
/* BEGIN ERROR CODES */ /* BEGIN ERROR CODES */
@ -173,8 +177,4 @@ RSA_METHOD *RSA_PKCS1_RSAref(void );
#define RSAREF_R_SIGNATURE 0x040b #define RSAREF_R_SIGNATURE 0x040b
#define RSAREF_R_SIGNATURE_ENCODING 0x040c #define RSAREF_R_SIGNATURE_ENCODING 0x040c
#ifdef __cplusplus
}
#endif #endif
#endif

View File

@ -59,12 +59,12 @@
#ifndef HEADER_SSL_H #ifndef HEADER_SSL_H
#define HEADER_SSL_H #define HEADER_SSL_H
#include <openssl/safestack.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <openssl/safestack.h>
/* SSLeay version number for ASN.1 encoding of the session information */ /* SSLeay version number for ASN.1 encoding of the session information */
/* Version 0 - initial version /* Version 0 - initial version
* Version 1 - added the optional peer certificate * Version 1 - added the optional peer certificate
@ -140,6 +140,10 @@ extern "C" {
#define SSL_SENT_SHUTDOWN 1 #define SSL_SENT_SHUTDOWN 1
#define SSL_RECEIVED_SHUTDOWN 2 #define SSL_RECEIVED_SHUTDOWN 2
#ifdef __cplusplus
}
#endif
#include <openssl/crypto.h> #include <openssl/crypto.h>
#include <openssl/lhash.h> #include <openssl/lhash.h>
#include <openssl/buffer.h> #include <openssl/buffer.h>
@ -147,6 +151,10 @@ extern "C" {
#include <openssl/pem.h> #include <openssl/pem.h>
#include <openssl/x509.h> #include <openssl/x509.h>
#ifdef __cplusplus
extern "C" {
#endif
#if (defined(NO_RSA) || defined(NO_MD5)) && !defined(NO_SSL2) #if (defined(NO_RSA) || defined(NO_MD5)) && !defined(NO_SSL2)
#define NO_SSL2 #define NO_SSL2
#endif #endif
@ -655,11 +663,19 @@ struct ssl_st
* SSLv3/TLS rollback check */ * SSLv3/TLS rollback check */
}; };
#ifdef __cplusplus
}
#endif
#include <openssl/ssl2.h> #include <openssl/ssl2.h>
#include <openssl/ssl3.h> #include <openssl/ssl3.h>
#include <openssl/tls1.h> /* This is mostly sslv3 with a few tweaks */ #include <openssl/tls1.h> /* This is mostly sslv3 with a few tweaks */
#include <openssl/ssl23.h> #include <openssl/ssl23.h>
#ifdef __cplusplus
extern "C" {
#endif
/* compatibility */ /* compatibility */
#define SSL_set_app_data(s,arg) (SSL_set_ex_data(s,0,(char *)arg)) #define SSL_set_app_data(s,arg) (SSL_set_ex_data(s,0,(char *)arg))
#define SSL_get_app_data(s) (SSL_get_ex_data(s,0)) #define SSL_get_app_data(s) (SSL_get_ex_data(s,0))