Lines Matching refs:peer
541 const struct ssl_peer *peer, in Curl_ssl_getsessionid() argument
577 if(strcasecompare(peer->hostname, check->name) && in Curl_ssl_getsessionid()
584 (peer->port == check->remote_port) && in Curl_ssl_getsessionid()
585 (peer->transport == check->transport) && in Curl_ssl_getsessionid()
603 cf->conn->handler->scheme, peer->hostname, peer->port); in Curl_ssl_getsessionid()
649 const struct ssl_peer *peer, in Curl_ssl_set_sessionid() argument
677 if(!Curl_ssl_getsessionid(cf, data, peer, &old_sessionid, &old_size, NULL)) { in Curl_ssl_set_sessionid()
693 clone_host = strdup(peer->hostname); in Curl_ssl_set_sessionid()
758 store->remote_port = peer->port; in Curl_ssl_set_sessionid()
760 store->transport = peer->transport; in Curl_ssl_set_sessionid()
1566 void Curl_ssl_peer_cleanup(struct ssl_peer *peer) in Curl_ssl_peer_cleanup() argument
1568 if(peer->dispname != peer->hostname) in Curl_ssl_peer_cleanup()
1569 free(peer->dispname); in Curl_ssl_peer_cleanup()
1570 free(peer->sni); in Curl_ssl_peer_cleanup()
1571 free(peer->hostname); in Curl_ssl_peer_cleanup()
1572 peer->hostname = peer->sni = peer->dispname = NULL; in Curl_ssl_peer_cleanup()
1573 peer->type = CURL_SSL_PEER_DNS; in Curl_ssl_peer_cleanup()
1582 Curl_ssl_peer_cleanup(&connssl->peer); in cf_close()
1606 CURLcode Curl_ssl_peer_init(struct ssl_peer *peer, struct Curl_cfilter *cf, in Curl_ssl_peer_init() argument
1613 DEBUGASSERT(peer); in Curl_ssl_peer_init()
1614 DEBUGASSERT(!peer->hostname); in Curl_ssl_peer_init()
1615 DEBUGASSERT(!peer->dispname); in Curl_ssl_peer_init()
1616 DEBUGASSERT(!peer->sni); in Curl_ssl_peer_init()
1622 peer->transport = transport; in Curl_ssl_peer_init()
1627 peer->port = cf->conn->http_proxy.port; in Curl_ssl_peer_init()
1634 peer->port = cf->conn->remote_port; in Curl_ssl_peer_init()
1643 peer->hostname = strdup(ehostname); in Curl_ssl_peer_init()
1644 if(!peer->hostname) in Curl_ssl_peer_init()
1647 peer->dispname = peer->hostname; in Curl_ssl_peer_init()
1649 peer->dispname = strdup(edispname); in Curl_ssl_peer_init()
1650 if(!peer->dispname) in Curl_ssl_peer_init()
1653 peer->type = get_peer_type(peer->hostname); in Curl_ssl_peer_init()
1654 if(peer->type == CURL_SSL_PEER_DNS) { in Curl_ssl_peer_init()
1657 size_t len = strlen(peer->hostname); in Curl_ssl_peer_init()
1658 if(len && (peer->hostname[len-1] == '.')) in Curl_ssl_peer_init()
1661 peer->sni = calloc(1, len + 1); in Curl_ssl_peer_init()
1662 if(!peer->sni) in Curl_ssl_peer_init()
1664 Curl_strntolower(peer->sni, peer->hostname, len); in Curl_ssl_peer_init()
1665 peer->sni[len] = 0; in Curl_ssl_peer_init()
1672 Curl_ssl_peer_cleanup(peer); in Curl_ssl_peer_init()
1730 if(!connssl->peer.hostname) { in ssl_cf_connect()
1731 result = Curl_ssl_peer_init(&connssl->peer, cf, TRNSPRT_TCP); in ssl_cf_connect()