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

Request ignore X-Forwarded-Proto #2680

Closed
demmsnt opened this issue Jan 22, 2018 · 3 comments
Closed

Request ignore X-Forwarded-Proto #2680

demmsnt opened this issue Jan 22, 2018 · 3 comments
Labels

Comments

@demmsnt
Copy link
Contributor

demmsnt commented Jan 22, 2018

Long story short

I use https for my project but i see http in self.request.scheme.

In nginx i describe proxy_set_header X-Forwarded-Proto $scheme;

in self.request headers i see 'X-Forwarded-Proto': 'https'

Unfortunately I did not find where the request points X-Forwarded-Proto to like X-Forwarded-For (also did not find it).

I use Ubuntu 16.04 and nginx.

@asvetlov
Copy link
Member

@demmsnt
Copy link
Contributor Author

demmsnt commented Jan 22, 2018

Yes i use scheme=self.request.headers.get('X-Forwarded-Proto', 'http') now. But this surprised me. Excuse for troubling

@lock
Copy link

lock bot commented Oct 28, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a [new issue] for related bugs.
If you feel like there's important points made in this discussion, please include those exceprts into that [new issue].
[new issue]: https://github.com/aio-libs/aiohttp/issues/new

@lock lock bot added the outdated label Oct 28, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants