Skip to content

Conversation

@ian-r-rose
Copy link
Collaborator

Finishes the work needed for #70, dask/dask-labextension#58.

This allows the developer to specify a non-localhost URI to be proxied. It should be a non-breaking change for users to LocalProxyHandler. It seems to work well in my testing, but @yuvipanda and @ryanlovett have a much better idea of the range of places where jupyter-server-proxy are deployed.

Copy link
Contributor

@yuvipanda yuvipanda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this!

I want to make sure that we only allow people to do this from subclassed hadnlers, and we make it so they explicitly are aware of the risks. I've left some comments, but will think a little more on how to make it harder to accidentally make this exploitable.

@yuvipanda
Copy link
Contributor

@ian-r-rose this looks good to me! Unfortunately there are no tests :| Can you do a bunch of local testing to see if it works ok? Would be even better if you can add a quick test or two, but I understand if you don't want this to block on that.

@ian-r-rose
Copy link
Collaborator Author

I've tested the LocalProxyHandler with dask-labextension, as well as ian-r-rose/jupyterlab-bokeh-server, and both of those work without changes. I've also tested dask-labextension with ProxyHandler using 127.0.0.1 for the hostname.

I can try to add some tests this evening.

@ian-r-rose
Copy link
Collaborator Author

I assume you also have some of extensions which it might be good to check with @yuvipanda?

@yuvipanda
Copy link
Contributor

@ian-r-rose would <3 if you could add some simple tests :)

@ian-r-rose
Copy link
Collaborator Author

I've added a very basic test, the great majority of the effort for which went into setting up the serverextension.

@yuvipanda yuvipanda merged commit b712eff into jupyterhub:master May 8, 2019
@yuvipanda
Copy link
Contributor

Thanks for all the awesome work, @ian-r-rose! <3

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants