/[svn]/hopm/trunk/src/irc.c
ViewVC logotype

Diff of /hopm/trunk/src/irc.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 9902 by michael, Sat Jan 2 18:42:37 2021 UTC revision 9903 by michael, Thu Jan 21 13:20:36 2021 UTC
# Line 600  irc_init(void) Line 600  irc_init(void)
600    
601      if (IRCItem.tls_hostname_verification)      if (IRCItem.tls_hostname_verification)
602      {      {
603    #ifndef LIBRESSL_VERSION_NUMBER
604        SSL_set_hostflags(ssl_handle, X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS);        SSL_set_hostflags(ssl_handle, X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS);
605    
606        if (SSL_set1_host(ssl_handle, IRCItem.server) == 0)        if (SSL_set1_host(ssl_handle, IRCItem.server) == 0)
607    #else
608          X509_VERIFY_PARAM *param = SSL_get0_param(ssl_handle);
609          X509_VERIFY_PARAM_set_hostflags(param, X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS);
610    
611          if (X509_VERIFY_PARAM_set1_host(param, IRCItem.server, 0) == 0)
612    #endif
613        {        {
614          log_printf("IRC -> unable to set expected DNS hostname");          log_printf("IRC -> unable to set expected DNS hostname");
615          /* OpenSSL is unable to verify the server hostname at this point, so we exit. */          /* OpenSSL is unable to verify the server hostname at this point, so we exit. */

Legend:
Removed from v.9902  
changed lines
  Added in v.9903

svnadmin@ircd-hybrid.org
ViewVC Help
Powered by ViewVC 1.1.28