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

password authentication #20

Open
guidov opened this issue Jun 19, 2024 · 2 comments
Open

password authentication #20

guidov opened this issue Jun 19, 2024 · 2 comments

Comments

@guidov
Copy link

guidov commented Jun 19, 2024

If I run the notebook I get this in the logs . I assume that I had set up some password authentication in my jupyter config file.
I get this output in the logs.
[W 2024-06-19 16:16:55.757 ServerApp] wrote error: 'Forbidden'
Traceback (most recent call last):
File "/home/user/miniforge3/lib/python3.11/site-packages/tornado/web.py", line 1788, in _execute
result = method(*self.path_args, **self.path_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/guido/miniforge3/lib/python3.11/site-packages/tornado/web.py", line 3289, in wrapper
url = self.get_login_url()
^^^^^^^^^^^^^^^^^^^^
File "/home/user/miniforge3/lib/python3.11/site-packages/jupyter_server/base/handlers.py", line 763, in get_login_url
raise web.HTTPError(403)
tornado.web.HTTPError: HTTP 403: Forbidden

However I ran 'jupyter' by itself and then a webpage asking for my password popped up and let me run the notebook. When I went back to 'jupyter thread' it then worked. Seemingly the browser remembered the authentication and allowed thread to run.
Is there a way around this, like not loading a default config file in ~/.jupyter.
Thanks

@guidov
Copy link
Author

guidov commented Jun 19, 2024

In addition to the above:
I have a jupyter-lab server running already and using a config file but I don't see how this could interfere:
c.ServerApp.allow_remote_access = True
c.ServerApp.ip = '*'
c.ServerApp.certfile = '/home/user/.jupyter/certificate.pem'
c.ServerApp.keyfile = '/home/user/.jupyter/key.pem'
c.ServerApp.port = 8000
c.ServerApp.root_dir = u'/scratch/user/Dropbox/ipynb'

In the directory:
~/.local/share/jupyter
there is a file called:
notebook_secret
with a hash in it

and in the directory:
~/.jupyter
there is a file called:
jupyter_server_config.json
that looks like this:
{
"IdentityProvider": {
"hashed_password": "xxxxxxxxxxxxxxxx"
}
}

@alishobeiri
Copy link
Owner

Thanks a lot, we haven't dealt too much with password identification so that is something we will need to address. The reason it is likely interfering is we use Jupyter Server as the backend as well. I will take an action item on me to improve the experience for authentication as well.

Wil let you know when it is fixed!

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

No branches or pull requests

2 participants