|
|
75e6b1 |
--- paramiko-2.1.1/paramiko/auth_handler.py 2016-12-12 19:12:48.000000000 -0500
|
|
|
75e6b1 |
+++ paramiko-2.1.1_patched/paramiko/auth_handler.py 2018-10-22 08:59:45.397822283 -0400
|
|
|
75e6b1 |
@@ -603,13 +603,25 @@
|
|
|
75e6b1 |
return
|
|
|
75e6b1 |
self._send_auth_result(self.auth_username, 'keyboard-interactive', result)
|
|
|
75e6b1 |
|
|
|
75e6b1 |
- _handler_table = {
|
|
|
75e6b1 |
+ _server_handler_table = {
|
|
|
75e6b1 |
MSG_SERVICE_REQUEST: _parse_service_request,
|
|
|
75e6b1 |
- MSG_SERVICE_ACCEPT: _parse_service_accept,
|
|
|
75e6b1 |
MSG_USERAUTH_REQUEST: _parse_userauth_request,
|
|
|
75e6b1 |
+ MSG_USERAUTH_INFO_RESPONSE: _parse_userauth_info_response,
|
|
|
75e6b1 |
+ }
|
|
|
75e6b1 |
+
|
|
|
75e6b1 |
+ _client_handler_table = {
|
|
|
75e6b1 |
+ MSG_SERVICE_ACCEPT: _parse_service_accept,
|
|
|
75e6b1 |
MSG_USERAUTH_SUCCESS: _parse_userauth_success,
|
|
|
75e6b1 |
MSG_USERAUTH_FAILURE: _parse_userauth_failure,
|
|
|
75e6b1 |
MSG_USERAUTH_BANNER: _parse_userauth_banner,
|
|
|
75e6b1 |
MSG_USERAUTH_INFO_REQUEST: _parse_userauth_info_request,
|
|
|
75e6b1 |
- MSG_USERAUTH_INFO_RESPONSE: _parse_userauth_info_response,
|
|
|
75e6b1 |
}
|
|
|
75e6b1 |
+
|
|
|
75e6b1 |
+ # NOTE: prior to the fix for #1283, this was a static dict instead of a
|
|
|
75e6b1 |
+ # property. Should be backwards compatible in most/all cases.
|
|
|
75e6b1 |
+ @property
|
|
|
75e6b1 |
+ def _handler_table(self):
|
|
|
75e6b1 |
+ if self.transport.server_mode:
|
|
|
75e6b1 |
+ return self._server_handler_table
|
|
|
75e6b1 |
+ else:
|
|
|
75e6b1 |
+ return self._client_handler_table
|