Lines Matching refs:server_hostname
316 PyObject *server_hostname; member
498 sslsock->server_hostname in fill_and_set_sslerror()
504 sslsock->server_hostname in fill_and_set_sslerror()
714 _ssl_configure_hostname(PySSLSocket *self, const char* server_hostname) in _ssl_configure_hostname() argument
721 assert(server_hostname); in _ssl_configure_hostname()
727 len = strlen(server_hostname); in _ssl_configure_hostname()
728 if (len == 0 || *server_hostname == '.') { in _ssl_configure_hostname()
737 ip = a2i_IPADDRESS(server_hostname); in _ssl_configure_hostname()
742 hostname = PyUnicode_Decode(server_hostname, len, "ascii", "strict"); in _ssl_configure_hostname()
746 self->server_hostname = hostname; in _ssl_configure_hostname()
750 if (!SSL_set_tlsext_host_name(self->ssl, server_hostname)) { in _ssl_configure_hostname()
758 if (!X509_VERIFY_PARAM_set1_host(param, server_hostname, in _ssl_configure_hostname()
759 strlen(server_hostname))) { in _ssl_configure_hostname()
782 char *server_hostname, in newPySSLSocket() argument
816 self->server_hostname = NULL; in newPySSLSocket()
872 if (server_hostname != NULL) { in newPySSLSocket()
873 if (_ssl_configure_hostname(self, server_hostname) < 0) { in newPySSLSocket()
2147 if (self->server_hostname == NULL) in PySSL_get_server_hostname()
2149 Py_INCREF(self->server_hostname); in PySSL_get_server_hostname()
2150 return self->server_hostname; in PySSL_get_server_hostname()
2211 Py_XDECREF(self->server_hostname); in PySSL_dealloc()