]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#9518 fix prev commit
authorHoward Chu <hyc@openldap.org>
Fri, 9 Apr 2021 18:29:11 +0000 (19:29 +0100)
committerHoward Chu <hyc@openldap.org>
Fri, 9 Apr 2021 18:29:11 +0000 (19:29 +0100)
libraries/libldap/ldap-int.h
libraries/libldap/tls_o.c

index cbcbc1ae3da3d5e3d2f92188a5ba906134598973..4dacecbfedd8231bc3e6088e5edf442963b9d1d3 100644 (file)
@@ -315,8 +315,7 @@ struct ldapoptions {
        int                     ldo_tls_require_san;
        char            *ldo_tls_pin_hashalg;
        struct berval   ldo_tls_pin;
-#define LDAP_LDO_TLS_NULLARG ,0,0,0,{0,0,0,0,0,0,0,0,0,\
-       LDAP_OPT_X_TLS_PROTOCOL(0,0), LDAP_OPT_X_TLS_PROTOCOL(255,255)},0,0,0,0,0,0,{0,0}
+#define LDAP_LDO_TLS_NULLARG ,0,0,0,{0,0,0,0,0,0,0,0,0},0,0,0,0,0,0,{0,0}
 #else
 #define LDAP_LDO_TLS_NULLARG
 #endif
index 10351379e7b3234180bc1e061057df07a18f50fc..bbf1f9156eb40f5126ecc3c16b4bdfda89a099c2 100644 (file)
@@ -363,7 +363,7 @@ tlso_ctx_init( struct ldapoptions *lo, struct ldaptls *lt, int is_server )
                if ( opt )
                        SSL_CTX_set_options( ctx, opt );
        }
-       {
+       if ( lo->ldo_tls_protocol_max ) {
                int opt = 0;
 #ifdef SSL_OP_NO_TLSv1_3
                if ( lo->ldo_tls_protocol_max < LDAP_OPT_X_TLS_PROTOCOL_TLS1_3 )