100-handle-openssl-without-sslv2-sslv3.patch 529 B

12345678910111213141516171819202122
  1. --- a/openssl.c
  2. +++ b/openssl.c
  3. @@ -216,11 +216,17 @@ ssl_select_method(const char *uhp)
  4. cp = ssl_method_string(uhp);
  5. if (cp != NULL) {
  6. +#ifndef OPENSSL_NO_SSL2
  7. if (equal(cp, "ssl2"))
  8. method = SSLv2_client_method();
  9. - else if (equal(cp, "ssl3"))
  10. + else
  11. +#endif
  12. +#ifndef OPENSSL_NO_SSL3
  13. + if (equal(cp, "ssl3"))
  14. method = SSLv3_client_method();
  15. - else if (equal(cp, "tls1"))
  16. + else
  17. +#endif
  18. + if (equal(cp, "tls1"))
  19. method = TLSv1_client_method();
  20. else {
  21. fprintf(stderr, catgets(catd, CATSET, 244,