Просмотр исходного кода

Merge pull request #440 from technoLord/maint

Enabling Post Handshake Authentication for Nagios-plugins
Sebastian Wolf 6 лет назад
Родитель
Сommit
4461486752
1 измененных файлов с 3 добавлено и 0 удалено
  1. 3 0
      plugins/sslutils.c

+ 3 - 0
plugins/sslutils.c

@@ -170,6 +170,9 @@ int np_net_ssl_init_with_hostname_version_and_cert(int sd, char *host_name, int
 	options |= SSL_OP_NO_TICKET;
 #endif
 	SSL_CTX_set_options(c, options);
+#ifdef SSL_CTX_set_post_handshake_auth
+	SSL_CTX_set_post_handshake_auth(c, 1);
+#endif
 	SSL_CTX_set_mode(c, SSL_MODE_AUTO_RETRY);
 	if ((s = SSL_new(c)) != NULL) {
 #ifdef SSL_set_tlsext_host_name