【问题标题】:ipython notebook server SSL erroripython笔记本服务器SSL错误
【发布时间】:2015-07-27 10:48:53
【问题描述】:

我的服务器有一个 SSL 证书(它是一个 .crt 包),但是在尝试将它与 ipython 笔记本服务器一起使用时我不断收到错误

我在 Windows 中设置了 nginx。通过反向代理设置对 ipython 的访问。我在这里关注了这个帖子:How to configure IPython behind nginx in a subpath?

我按照how to set up a notebook server 上的说明进行操作。我也在使用 /ipython 前缀。我更改了证书的位置,这是一个.crt 文件而不是.pem,其他一切都保持不变(除了密码)。

每当我尝试访问 www.domain.com/ipython 时,都会收到此错误:

[W 03:43:22.463 NotebookApp] SSL Error on 916 ('127.0.0.1', 1586): [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:581)

[E 03:43:22.463 NotebookApp] Uncaught exception
    Traceback (most recent call last):
      File "C:\Python27\lib\site-packages\tornado\http1connection.py", line 693,
 in _server_request_loop
        ret = yield conn.read_response(request_delegate)
      File "C:\Python27\lib\site-packages\tornado\gen.py", line 870, in run
        value = future.result()
      File "C:\Python27\lib\site-packages\tornado\concurrent.py", line 215, in result
        raise_exc_info(self._exc_info)
      File "C:\Python27\lib\site-packages\tornado\gen.py", line 876, in run
        yielded = self.gen.throw(*exc_info)
      File "C:\Python27\lib\site-packages\tornado\http1connection.py", line 168, in _read_message
        quiet_exceptions=iostream.StreamClosedError)
      File "C:\Python27\lib\site-packages\tornado\gen.py", line 870, in run
        value = future.result()
      File "C:\Python27\lib\site-packages\tornado\concurrent.py", line 215, in result
        raise_exc_info(self._exc_info)
      File "<string>", line 3, in raise_exc_info
    SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:581)

如果我使用自签名证书,一切都可以在本地计算机上运行,​​但它不能远程运行。并且使用签名证书在本地或远程都不起作用,并给我上面的错误。任何想法可能是什么问题?

【问题讨论】:

    标签: ssl nginx ipython reverse-proxy


    【解决方案1】:

    这个问题已经解决了。我盲目地遵循 ipython 文档中的说明,没有意识到我应该让 nginx 处理所有 SSL 连接,并且 ipython 不应该首先设置为使用 SSL

    【讨论】:

      猜你喜欢
      • 2015-05-12
      • 2018-12-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-05-23
      • 2014-04-13
      • 2014-10-17
      • 1970-01-01
      相关资源
      最近更新 更多