httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From do...@apache.org
Subject cvs commit: httpd-2.0/modules/ssl ssl_toolkit_compat.h mod_ssl.h
Date Wed, 27 Mar 2002 02:28:16 GMT
dougm       02/03/26 18:28:16

  Modified:    modules/ssl mod_ssl.h
  Added:       modules/ssl ssl_toolkit_compat.h
  Log:
  moving OpenSSL+sslc compat foo to ssl_toolkit_compat.h
  
  Revision  Changes    Path
  1.89      +2 -52     httpd-2.0/modules/ssl/mod_ssl.h
  
  Index: mod_ssl.h
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/ssl/mod_ssl.h,v
  retrieving revision 1.88
  retrieving revision 1.89
  diff -u -r1.88 -r1.89
  --- mod_ssl.h	27 Mar 2002 01:58:15 -0000	1.88
  +++ mod_ssl.h	27 Mar 2002 02:28:15 -0000	1.89
  @@ -125,6 +125,8 @@
   #include <engine.h>
   #endif
   
  +#include "ssl_toolkit_compat.h"
  +
   /* mod_ssl headers */
   #include "ssl_expr.h"
   #include "ssl_util_ssl.h"
  @@ -324,59 +326,7 @@
   
   #ifndef X509_V_ERR_CERT_UNTRUSTED
   #define X509_V_ERR_CERT_UNTRUSTED 27
  -
  -#endif
  -
  -#ifdef OPENSSL_VERSION_NUMBER
  -
  -/*
  - * rsa sslc uses incomplete types for most structures
  - * so we macroize for OpenSSL those which cannot be dereferenced
  - * using the same sames as the sslc functions
  - */
  -
  -#define EVP_PKEY_key_type(k)              (EVP_PKEY_type(k->type))
  -
  -#define X509_NAME_get_entries(xs)         (xs->entries)
  -#define X509_REVOKED_get_serialNumber(xs) (xs->serialNumber)
  -
  -#define X509_get_signature_algorithm(xs) (xs->cert_info->signature->algorithm)
  -#define X509_get_key_algorithm(xs)       (xs->cert_info->key->algor->algorithm)
  -
  -#define X509_NAME_ENTRY_get_data_ptr(xs) (xs->value->data)
  -#define X509_NAME_ENTRY_get_data_len(xs) (xs->value->length)
  -
  -#define SSL_CTX_get_extra_certs(ctx)       (ctx->extra_certs)
  -#define SSL_CTX_set_extra_certs(ctx,value) {ctx->extra_certs = value;}
  -
  -#define SSL_CIPHER_get_name(s)             (s->name)
  -#define SSL_CIPHER_get_valid(s)            (s->valid)
  -
  -#define SSL_SESSION_get_session_id(s)      (s->session_id)
  -#define SSL_SESSION_get_session_id_length(s) (s->session_id_length)
  -
  -/*
  - * Support for retrieving/overriding states
  - */
  -#ifndef SSL_get_state
  -#define SSL_get_state(ssl) SSL_state(ssl)
   #endif
  -
  -#define SSL_set_state(ssl,val) (ssl)->state = val
  -
  -#define MODSSL_BIO_CB_ARG_TYPE const char
  -
  -#else
  -
  -/* support some OpenSSL-izms for compat with ssl */
  -
  -#ifndef STACK_OF
  -#define STACK_OF(type) STACK
  -#endif
  -
  -#define MODSSL_BIO_CB_ARG_TYPE char
  -
  -#endif /* OPENSSL_VERSION_NUMBER */
   
   #define ssl_verify_error_is_optional(errnum) \
      ((errnum == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) \
  
  
  
  1.1                  httpd-2.0/modules/ssl/ssl_toolkit_compat.h
  
  Index: ssl_toolkit_compat.h
  ===================================================================
  #ifndef SSL_TOOLKIT_COMPAT_H
  #define SSL_TOOLKIT_COMPAT_H
  
  /*
   * this header file provides a compatiblity layer
   * between OpenSSL and RSA sslc
   */
  
  #ifdef OPENSSL_VERSION_NUMBER
  
  /*
   * rsa sslc uses incomplete types for most structures
   * so we macroize for OpenSSL those which cannot be dereferenced
   * using the same sames as the sslc functions
   */
  
  #define EVP_PKEY_key_type(k)              (EVP_PKEY_type(k->type))
  
  #define X509_NAME_get_entries(xs)         (xs->entries)
  #define X509_REVOKED_get_serialNumber(xs) (xs->serialNumber)
  
  #define X509_get_signature_algorithm(xs) (xs->cert_info->signature->algorithm)
  #define X509_get_key_algorithm(xs)       (xs->cert_info->key->algor->algorithm)
  
  #define X509_NAME_ENTRY_get_data_ptr(xs) (xs->value->data)
  #define X509_NAME_ENTRY_get_data_len(xs) (xs->value->length)
  
  #define SSL_CTX_get_extra_certs(ctx)       (ctx->extra_certs)
  #define SSL_CTX_set_extra_certs(ctx,value) {ctx->extra_certs = value;}
  
  #define SSL_CIPHER_get_name(s)             (s->name)
  #define SSL_CIPHER_get_valid(s)            (s->valid)
  
  #define SSL_SESSION_get_session_id(s)      (s->session_id)
  #define SSL_SESSION_get_session_id_length(s) (s->session_id_length)
  
  /*
   * Support for retrieving/overriding states
   */
  #ifndef SSL_get_state
  #define SSL_get_state(ssl) SSL_state(ssl)
  #endif
  
  #define SSL_set_state(ssl,val) (ssl)->state = val
  
  #define MODSSL_BIO_CB_ARG_TYPE const char
  
  #else /* RSA sslc */
  
  #ifndef STACK_OF
  #define STACK_OF(type) STACK
  #endif
  
  #define MODSSL_BIO_CB_ARG_TYPE char
  
  #endif /* OPENSSL_VERSION_NUMBER */
  
  #endif /* SSL_TOOLKIT_COMPAT_H */
  
  
  

Mime
View raw message