[PATCH] HTTP/2: add debug logging of pseudo-headers and cookies
Piotr Sikora
piotrsikora at google.com
Mon Apr 24 22:58:46 UTC 2017
# HG changeset patch
# User Piotr Sikora <piotrsikora at google.com>
# Date 1490516711 25200
# Sun Mar 26 01:25:11 2017 -0700
# Node ID 164b95f24f414359c5b8045415da3de82653c4db
# Parent 2c4dbcd6f2e4c9c2a1eb8dc1f0d39c99975ae208
HTTP/2: add debug logging of pseudo-headers and cookies.
Signed-off-by: Piotr Sikora <piotrsikora at google.com>
diff -r 2c4dbcd6f2e4 -r 164b95f24f41 src/http/v2/ngx_http_v2.c
--- a/src/http/v2/ngx_http_v2.c
+++ b/src/http/v2/ngx_http_v2.c
@@ -1589,6 +1589,10 @@ ngx_http_v2_state_process_header(ngx_htt
rc = ngx_http_v2_pseudo_header(r, header);
if (rc == NGX_OK) {
+ ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
+ "http2 pseudo-header: \":%V: %V\"",
+ &header->name, &header->value);
+
return ngx_http_v2_state_header_complete(h2c, pos, end);
}
@@ -1630,6 +1634,10 @@ ngx_http_v2_state_process_header(ngx_htt
NGX_HTTP_V2_INTERNAL_ERROR);
}
+ ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
+ "http2 http header: \"%V: %V\"",
+ &header->name, &header->value);
+
return ngx_http_v2_state_header_complete(h2c, pos, end);
}
More information about the nginx-devel
mailing list