ipython笔记本收听所有IP地址?

use*_*609 7 python ipython-notebook jupyter jupyter-notebook

当我启动IPython/Jupyter Notebook时,我收到以下警告:

WARNING: The notebook server is listening on all IP addresses and not using encryption. This is not recommended.
WARNING: The notebook server is listening on all IP addresses and not using authentication. This is highly insecure and not recommended.
Run Code Online (Sandbox Code Playgroud)

"收听所有IP地址"是什么意思?我该如何解决这个问题?

kin*_*ase 8

这意味着任何人都知道您的 IP 和您在 jupyter 中使用的端口将能够访问您的 jupyter notebook。例如,如果您通过路由器连接到 Internet,其他计算机可以通过:http://[your_ip]:8888访问您的笔记本电脑来访问您的笔记本电脑。8888 是 jupyter 的默认端口。

如果要停止绑定所有 IP,可以在控制台中指定要绑定的 IP:

jupyter notebook --ip=x.x.x.x
Run Code Online (Sandbox Code Playgroud)

xxxx 是你要绑定的IP。

  • 一个很酷的选择是使用 `0.0.0.0`,但是在浏览器 URL 输入中看到它很有趣。 (2认同)