Diff for /libraries/libldap/tls2.c between versions 1.4.2.2 and 1.4.2.3

version 1.4.2.2, 2009/02/04 12:53:38 version 1.4.2.3, 2009/02/08 06:06:04
Line 1 Line 1
 /* tls.c - Handle tls/ssl. */  /* tls.c - Handle tls/ssl. */
 /* $OpenLDAP: pkg/ldap/libraries/libldap/tls2.c,v 1.4.2.1 2009/01/26 23:29:53 quanah Exp $ */  /* $OpenLDAP: pkg/ldap/libraries/libldap/tls2.c,v 1.4.2.2 2009/02/04 12:53:38 quanah Exp $ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.  /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *   *
  * Copyright 1998-2009 The OpenLDAP Foundation.   * Copyright 1998-2009 The OpenLDAP Foundation.
Line 74  static oid_name oids[] = { Line 74  static oid_name oids[] = {
         { BER_BVNULL, BER_BVNULL }          { BER_BVNULL, BER_BVNULL }
 };  };
   
   #ifdef HAVE_TLS
   
 void  void
 ldap_pvt_tls_ctx_free ( void *c )  ldap_pvt_tls_ctx_free ( void *c )
 {  {
Line 848  ldap_int_tls_start ( LDAP *ld, LDAPConn Line 850  ldap_int_tls_start ( LDAP *ld, LDAPConn
 void *  void *
 ldap_pvt_tls_sb_ctx( Sockbuf *sb )  ldap_pvt_tls_sb_ctx( Sockbuf *sb )
 {  {
 #ifdef HAVE_TLS  
         void                    *p = NULL;          void                    *p = NULL;
                   
         ber_sockbuf_ctrl( sb, LBER_SB_OPT_GET_SSL, (void *)&p );          ber_sockbuf_ctrl( sb, LBER_SB_OPT_GET_SSL, (void *)&p );
         return p;          return p;
 #endif  
         return NULL;  
 }  }
   
 int  int
Line 865  ldap_pvt_tls_get_strength( void *s ) Line 864  ldap_pvt_tls_get_strength( void *s )
         return tls_imp->ti_session_strength( session );          return tls_imp->ti_session_strength( session );
 }  }
   
   
 int  int
 ldap_pvt_tls_get_my_dn( void *s, struct berval *dn, LDAPDN_rewrite_dummy *func, unsigned flags )  ldap_pvt_tls_get_my_dn( void *s, struct berval *dn, LDAPDN_rewrite_dummy *func, unsigned flags )
 {  {
 #ifdef HAVE_TLS  
         tls_session *session = s;          tls_session *session = s;
         struct berval der_dn;          struct berval der_dn;
         int rc;          int rc;
Line 877  ldap_pvt_tls_get_my_dn( void *s, struct Line 874  ldap_pvt_tls_get_my_dn( void *s, struct
         tls_imp->ti_session_my_dn( session, &der_dn );          tls_imp->ti_session_my_dn( session, &der_dn );
         rc = ldap_X509dn2bv(&der_dn, dn, (LDAPDN_rewrite_func *)func, flags );          rc = ldap_X509dn2bv(&der_dn, dn, (LDAPDN_rewrite_func *)func, flags );
         return rc;          return rc;
 #else /* !HAVE_TLS */  
         return LDAP_NOT_SUPPORTED;  
 #endif  
 }  }
   #endif /* HAVE_TLS */
   
 int  int
 ldap_start_tls( LDAP *ld,  ldap_start_tls( LDAP *ld,

Removed from v.1.4.2.2  
changed lines
  Added in v.1.4.2.3


______________
© Copyright 1998-2020, OpenLDAP Foundation, info@OpenLDAP.org