Lines Matching refs:cf

532 static CURLcode bearssl_connect_step1(struct Curl_cfilter *cf,  in bearssl_connect_step1()  argument
535 struct ssl_connect_data *connssl = cf->ctx; in bearssl_connect_step1()
538 struct ssl_primary_config *conn_config = Curl_ssl_cf_get_primary_config(cf); in bearssl_connect_step1()
539 struct ssl_config_data *ssl_config = Curl_ssl_cf_get_config(cf, data); in bearssl_connect_step1()
551 CURL_TRC_CF(data, cf, "connect_step1"); in bearssl_connect_step1()
560 CURL_TRC_CF(data, cf, "connect_step1, load ca_info_blob"); in bearssl_connect_step1()
574 CURL_TRC_CF(data, cf, "connect_step1, load cafile"); in bearssl_connect_step1()
598 CURL_TRC_CF(data, cf, "connect_step1, set ciphers"); in bearssl_connect_step1()
616 CURL_TRC_CF(data, cf, "connect_step1, check session cache"); in bearssl_connect_step1()
618 if(!Curl_ssl_getsessionid(cf, data, &connssl->peer, &sdata, &slen, NULL) && in bearssl_connect_step1()
655 CURL_TRC_CF(data, cf, "connect_step1, SNI set"); in bearssl_connect_step1()
679 static CURLcode bearssl_run_until(struct Curl_cfilter *cf, in bearssl_run_until() argument
683 struct ssl_connect_data *connssl = cf->ctx; in bearssl_run_until()
732 ret = Curl_conn_cf_send(cf->next, data, (char *)buf, len, FALSE, in bearssl_run_until()
734 CURL_TRC_CF(data, cf, "ssl_send(len=%zu) -> %zd, %d", len, ret, result); in bearssl_run_until()
744 ret = Curl_conn_cf_recv(cf->next, data, (char *)buf, len, &result); in bearssl_run_until()
745 CURL_TRC_CF(data, cf, "ssl_recv(len=%zu) -> %zd, %d", len, ret, result); in bearssl_run_until()
760 static CURLcode bearssl_connect_step2(struct Curl_cfilter *cf, in bearssl_connect_step2() argument
763 struct ssl_connect_data *connssl = cf->ctx; in bearssl_connect_step2()
771 CURL_TRC_CF(data, cf, "connect_step2"); in bearssl_connect_step2()
773 ret = bearssl_run_until(cf, data, BR_SSL_SENDAPP | BR_SSL_RECVAPP); in bearssl_connect_step2()
813 static CURLcode bearssl_connect_step3(struct Curl_cfilter *cf, in bearssl_connect_step3() argument
816 struct ssl_connect_data *connssl = cf->ctx; in bearssl_connect_step3()
819 struct ssl_config_data *ssl_config = Curl_ssl_cf_get_config(cf, data); in bearssl_connect_step3()
824 CURL_TRC_CF(data, cf, "connect_step3"); in bearssl_connect_step3()
830 Curl_alpn_set_negotiated(cf, data, connssl, (const unsigned char *)proto, in bearssl_connect_step3()
842 ret = Curl_ssl_set_sessionid(cf, data, &connssl->peer, NULL, in bearssl_connect_step3()
855 static ssize_t bearssl_send(struct Curl_cfilter *cf, struct Curl_easy *data, in bearssl_send() argument
858 struct ssl_connect_data *connssl = cf->ctx; in bearssl_send()
867 *err = bearssl_run_until(cf, data, BR_SSL_SENDAPP); in bearssl_send()
890 static ssize_t bearssl_recv(struct Curl_cfilter *cf, struct Curl_easy *data, in bearssl_recv() argument
893 struct ssl_connect_data *connssl = cf->ctx; in bearssl_recv()
901 *err = bearssl_run_until(cf, data, BR_SSL_RECVAPP); in bearssl_recv()
915 static CURLcode bearssl_connect_common(struct Curl_cfilter *cf, in bearssl_connect_common() argument
921 struct ssl_connect_data *connssl = cf->ctx; in bearssl_connect_common()
922 curl_socket_t sockfd = Curl_conn_cf_get_socket(cf, data); in bearssl_connect_common()
926 CURL_TRC_CF(data, cf, "connect_common(blocking=%d)", !nonblocking); in bearssl_connect_common()
929 CURL_TRC_CF(data, cf, "connect_common, connected"); in bearssl_connect_common()
935 ret = bearssl_connect_step1(cf, data); in bearssl_connect_common()
957 CURL_TRC_CF(data, cf, "connect_common, check socket"); in bearssl_connect_common()
960 CURL_TRC_CF(data, cf, "connect_common, check socket -> %d", what); in bearssl_connect_common()
987 ret = bearssl_connect_step2(cf, data); in bearssl_connect_common()
993 ret = bearssl_connect_step3(cf, data); in bearssl_connect_common()
1016 static bool bearssl_data_pending(struct Curl_cfilter *cf, in bearssl_data_pending() argument
1019 struct ssl_connect_data *ctx = cf->ctx; in bearssl_data_pending()
1048 static CURLcode bearssl_connect(struct Curl_cfilter *cf, in bearssl_connect() argument
1054 ret = bearssl_connect_common(cf, data, FALSE, &done); in bearssl_connect()
1063 static CURLcode bearssl_connect_nonblocking(struct Curl_cfilter *cf, in bearssl_connect_nonblocking() argument
1067 return bearssl_connect_common(cf, data, TRUE, done); in bearssl_connect_nonblocking()
1079 static CURLcode bearssl_shutdown(struct Curl_cfilter *cf, in bearssl_shutdown() argument
1083 struct ssl_connect_data *connssl = cf->ctx; in bearssl_shutdown()
1089 if(!backend->active || cf->shutdown) { in bearssl_shutdown()
1101 result = bearssl_run_until(cf, data, BR_SSL_CLOSED); in bearssl_shutdown()
1106 CURL_TRC_CF(data, cf, "shutdown EAGAIN, io_need=%x", connssl->io_need); in bearssl_shutdown()
1110 CURL_TRC_CF(data, cf, "shutdown error: %d", result); in bearssl_shutdown()
1112 cf->shutdown = (result || *done); in bearssl_shutdown()
1116 static void bearssl_close(struct Curl_cfilter *cf, struct Curl_easy *data) in bearssl_close() argument
1118 struct ssl_connect_data *connssl = cf->ctx; in bearssl_close()