Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/ngx_stream_lua_ssl_certby.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ ngx_stream_lua_ssl_cert_handler(ngx_ssl_conn_t *ssl_conn, void *data)

if (cctx->done) {
ngx_log_debug1(NGX_LOG_DEBUG_STREAM, c->log, 0,
"stream lua_certificate_by_lua:"
"stream ssl_certificate_by_lua:"
" cert cb exit code: %d",
cctx->exit_code);

Expand Down Expand Up @@ -319,7 +319,7 @@ ngx_stream_lua_ssl_cert_handler(ngx_ssl_conn_t *ssl_conn, void *data)
}

ngx_log_debug2(NGX_LOG_DEBUG_STREAM, c->log, 0,
"stream lua_certificate_by_lua:"
"stream ssl_certificate_by_lua:"
" handler return value: %i, "
"cert cb exit code: %d", rc, cctx->exit_code);

Expand Down Expand Up @@ -400,15 +400,15 @@ ngx_stream_lua_ssl_cert_aborted(void *data)
{
ngx_stream_lua_ssl_ctx_t *cctx = data;

dd("lua ssl cert done");
dd("lua ssl cert aborted");

if (cctx->done) {
/* completed successfully already */
return;
}

ngx_log_debug0(NGX_LOG_DEBUG_STREAM, cctx->connection->log, 0,
"stream lua_certificate_by_lua: cert cb aborted");
"stream ssl_certificate_by_lua: cert cb aborted");

cctx->aborted = 1;
cctx->request->connection->ssl = NULL;
Expand Down
2 changes: 1 addition & 1 deletion src/ngx_stream_lua_ssl_client_helloby.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ ngx_stream_lua_ssl_client_hello_aborted(void *data)
{
ngx_stream_lua_ssl_ctx_t *cctx = data;

dd("lua ssl client hello done");
dd("lua ssl client hello aborted");

if (cctx->done) {
/* completed successfully already */
Expand Down
9 changes: 5 additions & 4 deletions t/139-ssl-cert-by.t
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ reusable connection: 0
ssl cert: connection reusable: 0
reusable connection: 0
ssl_certificate_by_lua:1: ssl cert by lua is running!,
ssl_certificate_by_lua: handler return value: 0,
reusable connection: 0
reusable connection: 0
reusable connection: 0
Expand Down Expand Up @@ -448,7 +449,7 @@ failed to do SSL handshake: handshake failed

--- error_log eval
[
'lua_certificate_by_lua: handler return value: -1, cert cb exit code: 0',
'ssl_certificate_by_lua: handler return value: -1, cert cb exit code: 0',
qr/\[info\] .*? SSL_do_handshake\(\) failed .*?cert cb error/,
'lua exit with code -1',
]
Expand Down Expand Up @@ -567,7 +568,7 @@ failed to do SSL handshake: handshake failed

--- error_log eval
[
'lua_certificate_by_lua: cert cb exit code: 0',
'ssl_certificate_by_lua: cert cb exit code: 0',
qr/\[info\] .*? SSL_do_handshake\(\) failed .*?cert cb error/,
'lua exit with code -1',
]
Expand Down Expand Up @@ -627,7 +628,7 @@ failed to do SSL handshake: handshake failed
--- error_log eval
[
'runtime error: ssl_certificate_by_lua:2: bad bad bad',
'lua_certificate_by_lua: handler return value: 500, cert cb exit code: 0',
'ssl_certificate_by_lua: handler return value: 500, cert cb exit code: 0',
qr/\[info\] .*? SSL_do_handshake\(\) failed .*?cert cb error/,
qr/context: ssl_certificate_by_lua\*, client: \d+\.\d+\.\d+\.\d+, server: \d+\.\d+\.\d+\.\d+:\d+/,
]
Expand Down Expand Up @@ -688,7 +689,7 @@ failed to do SSL handshake: handshake failed
--- error_log eval
[
'runtime error: ssl_certificate_by_lua:3: bad bad bad',
'lua_certificate_by_lua: cert cb exit code: 0',
'ssl_certificate_by_lua: cert cb exit code: 0',
qr/\[info\] .*? SSL_do_handshake\(\) failed .*?cert cb error/,
]

Expand Down
Loading