Skip to content

Jupyter notebook SSL does not allow keyfile with PEM pass phrase #2595

Open
@charlie718y

Description

Trying to enable Notebook SSL,

  1. Creating a .pem and .key file,
  2. To secure the .key file, I put a pass phrase on the .key file.
  3. Update notebook config file to point to the certfile and keyfile,
    NotebookApp.certfile
    NotebookApp.keyfile

An exception is encountered when using browser to access the notebook webserver,

Enter PEM pass phrase:
[E 15:24:43.503 NotebookApp] Exception in callback (<socket._socketobject object at 0x7f9bdc28a360>, <function null_wrapper at 0x7f9bdc0bb758>)
Traceback (most recent call last):
File "/var/install/lib/python2.7/site-packages/tornado/ioloop.py", line 888, in start
handler_func(fd_obj, events)
File "/var/install/lib/python2.7/site-packages/tornado/stack_context.py", line 277, in null_wrapper
return fn(*args, **kwargs)
File "/var/install/lib/python2.7/site-packages/tornado/netutil.py", line 276, in accept_handler
callback(connection, address)
File "/var/install/lib/python2.7/site-packages/tornado/tcpserver.py", line 264, in _handle_connection
do_handshake_on_connect=False)
File "/var/install/lib/python2.7/site-packages/tornado/netutil.py", line 517, in ssl_wrap_socket
context = ssl_options_to_context(ssl_options)
File "/var/install/lib/python2.7/site-packages/tornado/netutil.py", line 494, in ssl_options_to_context
context.load_cert_chain(ssl_options['certfile'], ssl_options.get('keyfile', None))
IOError: [Errno 22] Invalid argument

Activity

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

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions