-
Notifications
You must be signed in to change notification settings - Fork 803
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
Admin access to users server lead to 403 (workaround exist) #1700
Comments
Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗 |
@0nebody this is discussed in jupyterhub/jupyterhub#2284, you can find some solutions in the comments. |
In #1813 I've added a configuration option allowing us to influence the ConfigurableHTTPProxy running in the proxy pod which can be used to workaround this temporarily when merged. I don't understand the HTTP Headers well enough x-forwarded-port to properly evaluate what makes sense in general =/ But, @0nebody you saying that if the CHP proxy receive already TLS terminated HTTPS traffic which is now just HTTP, it should when it proxies it onwards always be configured with @manics, this relates to our discussion in #1811! I don't understand the HTTP header well enough to really grasp this yet though. |
This looks like a bug to me. Example:
In this situation Nginx should be configured to add a In the case where CHP is directly receiving traffic:
CHP should add a A single HTTP request can only be made with one protocol, so what's causing CHP to pass |
The ['for', 'port', 'proto'].forEach(function(header) {
req.headers['x-forwarded-' + header] =
(req.headers['x-forwarded-' + header] || '') +
(req.headers['x-forwarded-' + header] ? ',' : '') +
values[header];
}); This makes sense for the I was under the impression that Then there's this relevant Tornado PR: tornadoweb/tornado#2162 |
The upstream issue is fixed in jupyterhub/jupyterhub#2284 . I think we can get away with not dealing with the peculiarities of multiple forwarded-headers here. |
As the upstream issue is fixed and we have bumped to version 1.3.0 (or earlier?) that contains that fix, I'll go ahead and close this issue. |
Bug description
As an admin when I attempt to access another users notebook I receive a 403 error.
Expected behaviour
I expect to be able to access the users notebook.
Actual behaviour
I am redirected to a 403 page.
How to reproduce
Your personal set up
This occurs when when proxy.https.type is set to offload and a load balancer is responsible for SSL termination.
The headers sent from the proxy to the container are:
When HTTPS is offloaded the proxy should not attempt to add x-forward headers. Adding
--no-x-forward
flag to the proxy fixes the issue.The text was updated successfully, but these errors were encountered: