Lines Matching defs:ssl
40 SSL *s = wsi->tls.ssl;
55 if (!wsi->tls.ssl)
58 m = SSL_get_error(wsi->tls.ssl, n);
59 lwsl_debug("%s: %p %d -> %d (errno %d)\n", __func__, wsi->tls.ssl, n, m, LWS_ERRNO);
117 * password provided, set ssl callback and user data
203 if (!wsi->tls.ssl)
212 n = SSL_read(wsi->tls.ssl, buf, (int)(ssize_t)len);
247 lwsl_debug("%s: ssl err %d errno %d\n", lws_wsi_tag(wsi), m, LWS_ERRNO);
273 if (SSL_want_read(wsi->tls.ssl)) {
278 if (SSL_want_write(wsi->tls.ssl)) {
312 if (!wsi->tls.ssl)
315 if (SSL_pending(wsi->tls.ssl)) {
332 if (!wsi->tls.ssl)
335 return SSL_pending(wsi->tls.ssl);
354 if (!wsi->tls.ssl)
359 n = SSL_write(wsi->tls.ssl, buf, (int)(ssize_t)len);
371 if (m == SSL_ERROR_WANT_READ || SSL_want_read(wsi->tls.ssl)) {
377 if (m == SSL_ERROR_WANT_WRITE || SSL_want_write(wsi->tls.ssl)) {
401 lws_ssl_info_callback(const SSL *ssl, int where, int ret)
410 SSL_get_SSL_CTX(ssl),
414 SSL_get_SSL_CTX((SSL*) ssl),
420 fd = SSL_get_fd(ssl);
446 if (!wsi->tls.ssl)
450 /* kill ssl callbacks, because we will remove the fd from the
454 SSL_set_info_callback(wsi->tls.ssl, NULL);
466 n = SSL_get_fd(wsi->tls.ssl);
468 SSL_shutdown(wsi->tls.ssl);
470 SSL_free(wsi->tls.ssl);
471 wsi->tls.ssl = NULL;
475 // lwsl_notice("%s: ssl restr %d, simul %d\n", __func__,
527 if (!wsi->tls.ssl)
530 return SSL_get_SSL_CTX(wsi->tls.ssl);
544 n = SSL_shutdown(wsi->tls.ssl);
556 n = SSL_get_error(wsi->tls.ssl, n);
558 if (SSL_want_read(wsi->tls.ssl)) {
563 if (SSL_want_write(wsi->tls.ssl)) {