| 954 | } |
| 955 | |
| 956 | void TSSLSocketFactory::ciphers(const string& enable) { |
| 957 | int rc = SSL_CTX_set_cipher_list(ctx_->get(), enable.c_str()); |
| 958 | if (ERR_peek_error() != 0) { |
| 959 | string errors; |
| 960 | buildErrors(errors); |
| 961 | throw TSSLException("SSL_CTX_set_cipher_list: " + errors); |
| 962 | } |
| 963 | if (rc == 0) { |
| 964 | throw TSSLException("None of specified ciphers are supported"); |
| 965 | } |
| 966 | } |
| 967 | |
| 968 | void TSSLSocketFactory::authenticate(bool required) { |
| 969 | int mode; |