Lines Matching defs:ssl_ctx
330 SSL_CTX *ssl_ctx;
331 ssl_ctx = SSL_CTX_new(TLS_client_method());
332 if (!ssl_ctx) {
336 SSL_CTX_set_options(ssl_ctx,
341 SSL_CTX_set_next_proto_select_cb(ssl_ctx, select_next_proto_cb, NULL);
345 SSL_CTX_set_alpn_protos(ssl_ctx, (const unsigned char *)"\x02h2", 3);
348 return ssl_ctx;
352 static SSL *create_ssl(SSL_CTX *ssl_ctx) {
354 ssl = SSL_new(ssl_ctx);
546 static void initiate_connection(struct event_base *evbase, SSL_CTX *ssl_ctx,
553 ssl = create_ssl(ssl_ctx);
575 SSL_CTX *ssl_ctx;
591 ssl_ctx = create_ssl_ctx();
598 initiate_connection(evbase, ssl_ctx, host, port, session_data);
605 SSL_CTX_free(ssl_ctx);