Merge pull request #7832 from minrk/default-secure-session

remove default_secure, make Session secure by default
This commit is contained in:
Matthias Bussonnier 2015-02-28 12:59:14 -08:00
commit 709126542a
2 changed files with 3 additions and 4 deletions

View File

@ -77,7 +77,7 @@ from IPython.core.application import (
from IPython.core.profiledir import ProfileDir
from IPython.kernel import KernelManager
from IPython.kernel.kernelspec import KernelSpecManager
from IPython.kernel.zmq.session import default_secure, Session
from IPython.kernel.zmq.session import Session
from IPython.nbformat.sign import NotebookNotary
from IPython.utils.importstring import import_item
from IPython.utils import submodule
@ -764,9 +764,6 @@ class NotebookApp(BaseIPythonApplication):
self.ipython_kernel_argv = ["--profile-dir", self.profile_dir.location]
def init_configurables(self):
# force Session default to be secure
default_secure(self.config)
self.kernel_spec_manager = self.kernel_spec_manager_class(
parent=self,
ipython_dir=self.ipython_dir,

View File

@ -179,6 +179,8 @@ class ZMQChannelsHandler(AuthenticatedZMQStreamHandler):
# then request kernel info, waiting up to a certain time before giving up.
# We don't want to wait forever, because browsers don't take it well when
# servers never respond to websocket connection requests.
kernel = self.kernel_manager.get_kernel(self.kernel_id)
self.session.key = kernel.session.key
future = self.request_kernel_info()
def give_up():