Skip to content
This repository has been archived by the owner on Sep 28, 2021. It is now read-only.

Request#header(String) should be case insensitive for HTTP requests #71

Closed
udoprog opened this issue Dec 18, 2015 · 5 comments
Closed
Milestone

Comments

@udoprog
Copy link
Contributor

udoprog commented Dec 18, 2015

See http://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html
From 4.2 Message Headers: "Field names are case-insensitive."

This will otherwise cause problems when interacting with proxies or clients that perform pre-emptive all-to-lowercase/uppercase example here before the request hits the Apollo-based service.

@pettermahlen
Copy link
Member

What exactly is the problem in the Apollo code base?

@udoprog
Copy link
Contributor Author

udoprog commented Dec 18, 2015

Request#header(String) is not case-insensitive, which should probably be handled by ApolloRequestHandler in the jetty-http-server module returning using a map that is all-lowercase, and providing a request object with alternative implementation that String#toLowerCase()'s the key before looking it up.

@pettermahlen
Copy link
Member

Right, of course, it was in the title. We should define whether Request itself considers headers to be case-sensitive or not, I think. I don't have any strong opinions about that, but I think I would like to make it case-insensitive like for HTTP.

@pettermahlen
Copy link
Member

Addressed in #93

@pettermahlen
Copy link
Member

Fixed via #96

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants