]> git.sur5r.net Git - openldap/commitdiff
Add TLS_CIPHER_SUITE directive
authorKurt Zeilenga <kurt@openldap.org>
Wed, 8 Sep 2004 00:34:42 +0000 (00:34 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Wed, 8 Sep 2004 00:34:42 +0000 (00:34 +0000)
doc/man/man5/ldap.conf.5
libraries/libldap/init.c
libraries/libldap/tls.c

index 5c75bc62c9bae0173ed8d81bb7f66e83f0daad0a..0821a62db0b75df1b3ef5e7584c22c260f7af702 100644 (file)
@@ -220,6 +220,11 @@ file. Currently, the private key must not be protected with a password, so
 it is of critical importance that the key file is protected carefully. This
 is a user\-only option.
 .TP
+.B TLS_CIPHER_SUITE <cipher-suite-spec>
+Specifies acceptable cipher suite and preference order.
+<cipher-suite-spec> should be a cipher specification for OpenSSL,
+e.g., HIGH:MEDIUM:+SSLv2.
+.TP
 .B TLS_RANDFILE <filename>
 Specifies the file to obtain random bits from when /dev/[u]random is
 not available. Generally set to the name of the EGD/PRNGD socket.
index f20223294a11b7a50b1bb4e045cb70be9fc74b20..0314f8ba926379415b0f21056578cba61ae8bd34 100644 (file)
@@ -91,12 +91,13 @@ static const struct ol_attribute {
 #endif
 
 #ifdef HAVE_TLS
-       {1, ATTR_TLS,           "TLS_CERT",             NULL,   LDAP_OPT_X_TLS_CERTFILE},
-       {1, ATTR_TLS,           "TLS_KEY",              NULL,   LDAP_OPT_X_TLS_KEYFILE},
-       {0, ATTR_TLS,           "TLS_CACERT",   NULL,   LDAP_OPT_X_TLS_CACERTFILE},
-       {0, ATTR_TLS,           "TLS_CACERTDIR",NULL,   LDAP_OPT_X_TLS_CACERTDIR},
-       {0, ATTR_TLS,           "TLS_REQCERT",  NULL,   LDAP_OPT_X_TLS_REQUIRE_CERT},
-       {0, ATTR_TLS,           "TLS_RANDFILE", NULL,   LDAP_OPT_X_TLS_RANDOM_FILE},
+       {1, ATTR_TLS,   "TLS_CERT",                     NULL,   LDAP_OPT_X_TLS_CERTFILE},
+       {1, ATTR_TLS,   "TLS_KEY",                      NULL,   LDAP_OPT_X_TLS_KEYFILE},
+       {0, ATTR_TLS,   "TLS_CACERT",           NULL,   LDAP_OPT_X_TLS_CACERTFILE},
+       {0, ATTR_TLS,   "TLS_CACERTDIR",        NULL,   LDAP_OPT_X_TLS_CACERTDIR},
+       {0, ATTR_TLS,   "TLS_REQCERT",          NULL,   LDAP_OPT_X_TLS_REQUIRE_CERT},
+       {0, ATTR_TLS,   "TLS_RANDFILE",         NULL,   LDAP_OPT_X_TLS_RANDOM_FILE},
+       {0, ATTR_TLS,   "TLS_CIPHER_SUITE",     NULL,   LDAP_OPT_X_TLS_CIPHER_SUITE},
 #endif
 
        {0, ATTR_NONE,          NULL,           NULL,   0}
index 8c30370d845d2179a94852b67552f675b7684d11..8610aaa353e2f1c155f71cd5f1797ab9cf633e74 100644 (file)
@@ -1143,6 +1143,7 @@ ldap_int_tls_config( LDAP *ld, int option, const char *arg )
        case LDAP_OPT_X_TLS_CERTFILE:
        case LDAP_OPT_X_TLS_KEYFILE:
        case LDAP_OPT_X_TLS_RANDOM_FILE:
+       case LDAP_OPT_X_TLS_CIPHER_SUITE:
                return ldap_pvt_tls_set_option( ld, option, (void *) arg );
 
        case LDAP_OPT_X_TLS_REQUIRE_CERT: