Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC 2616 defines header values as case insensitive, so per default we… #1259

Open
wants to merge 1 commit into
base: 2.3
Choose a base branch
from

Conversation

notz
Copy link

@notz notz commented Mar 17, 2017

… should read/write headers values as case insensitive

Currently only the getValues method use case insensitive per default, all other are case sensitive.

This fixes problems behind a nginx reverse proxy, where "X-Forwarded-Proto" header is set as "X-forwarded-proto" (#1191).
The X-Forwarded-For is working because it's read in restlet with getValues method.

… should read/write headers values as case insensitive

 Currently only the getValues method use case insensitive per default, all other are case sensitive.

 This fixes problems behind a nginx reverse proxy, where "X-Forwarded-Proto" header is set as "X-forwarded-proto".
 The X-Forwarded-For is working because it's read in restlet with getValues method.
@thboileau
Copy link
Contributor

Hi @notz , this is not so easy to change the default read option as this class is also used elsewhere.
I have to check more deeply.
I think we can make sure that the framework internally reads the header in the right way. In the cases you read the headers from your own code, is it possible for you to read using the value in the case-insensitive way?

@notz
Copy link
Author

notz commented Apr 22, 2017 via email

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

Successfully merging this pull request may close these issues.

None yet

3 participants