Dear nginx developers, 
 
This is JinNyung Kim, a developer at Naver Korea corporation. 
(http://www.naver.com)
I'm writing in regards to spaces in header field in nginx. 
Actually when I modified use from apache-tomcat to nginx-tomcat last Tuesday, I 
had a trouble with spaces in authorization header. 
I know the field name including spaces is not permitted, but it's problem that 
apache didn't ignore this and passed to tomcat.
So, I need spaces in headers option and think that this will be helpful for the 
people who modify use from apache to nginx like me. 
Also, I developed the logging option in error.log.
 
spaces_in_headers will likely act underscores_in_headers. 
 
spaces_in_headers  default off
log_spaces_in_headers default off
 
When I request this two commands, nginx ignore the Authorization header in the 
second command.
But this patch trims trailing spaces in header fields. (I couldn't check the 
spdy request)
 
> curl -H "Authorization: test" http://x.x.x/SimpleHttp;
> curl -H "Authorization   : test" http://x.x.x/SimpleHttp;
 
When log_spaces_in_headers option is set to on, you can see this log in 
error.log.
 
2015/09/03 16:30:24 [error] 9107#0: *18 [Spaces in Header] Authorization=test  
while reading client request headers, client: 0.0.0.0, server: x.x.x., request: 
"GET /SimpleHttp HTTP/1.1", host: "1.1.1.1"
 
 
 
I look forward to hearing from you about whether patch is accepted or not. 
 
Thank you for reading my email.
 
Yours Sincerely
JinNyung Kim
 





Attachment: nginx.patch
Description: Binary data

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel

Reply via email to