From bbe98132c7e16f51c44e65138584430238734372 Mon Sep 17 00:00:00 2001 From: Dennis Kaarsemaker Date: Wed, 15 Feb 2017 18:05:50 +0100 Subject: Fix bug in handling multiple interactive queries If repeated interaction is needed, check_auth_interactive_response returns an InteractiveQuery object. Unfortunately a bug caused it not to be recognized, causing autheintication to fail. This fixes said bug by properly looking at the type of the returned object. --- paramiko/auth_handler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paramiko/auth_handler.py b/paramiko/auth_handler.py index 38b23729..cab27a88 100644 --- a/paramiko/auth_handler.py +++ b/paramiko/auth_handler.py @@ -597,7 +597,7 @@ class AuthHandler (object): for i in range(n): responses.append(m.get_text()) result = self.transport.server_object.check_auth_interactive_response(responses) - if isinstance(type(result), InteractiveQuery): + if isinstance(result, InteractiveQuery): # make interactive query instead of response self._interactive_query(result) return -- cgit v1.2.3 From c798ef5dd3b2647f765716b943fe42615d5508dd Mon Sep 17 00:00:00 2001 From: Jeff Forcier Date: Sun, 19 Feb 2017 11:38:57 -0800 Subject: Changelog re #895, closes #895 --- sites/www/changelog.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sites/www/changelog.rst b/sites/www/changelog.rst index a64ef608..36ef443f 100644 --- a/sites/www/changelog.rst +++ b/sites/www/changelog.rst @@ -2,6 +2,9 @@ Changelog ========= +* :bug:`895` Fix a bug in server-mode concerning multiple interactive auth + steps (which were incorrectly responded to). Thanks to Dennis Kaarsemaker for + catch & patch. * :support:`866 backported` (also :issue:`838`) Remove an old test-related file we don't support, and add PyPy to Travis-CI config. Thanks to Pierce Lopez for the final patch and Pedro Rodrigues for an earlier edition. -- cgit v1.2.3