Skip to content

Commit

Permalink
Merge branch '2.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
bitprophet committed Mar 13, 2018
2 parents c711059 + a66391d commit 1cd44d6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions paramiko/transport.py
Original file line number Diff line number Diff line change
Expand Up @@ -1842,9 +1842,9 @@ def _ensure_authed(self, ptype, message):
Otherwise (client mode, authed, or pre-auth message) returns None.
"""
if (
not self.server_mode
or ptype <= HIGHEST_USERAUTH_MESSAGE_ID
or self.is_authenticated()
not self.server_mode or
ptype <= HIGHEST_USERAUTH_MESSAGE_ID or
self.is_authenticated()
):
return None
# WELP. We must be dealing with someone trying to do non-auth things
Expand All @@ -1855,7 +1855,7 @@ def _ensure_authed(self, ptype, message):
reply.add_byte(cMSG_REQUEST_FAILURE)
# Channel opens let us reject w/ a specific type + message.
elif ptype == MSG_CHANNEL_OPEN:
kind = message.get_text()
kind = message.get_text() # noqa
chanid = message.get_int()
reply.add_byte(cMSG_CHANNEL_OPEN_FAILURE)
reply.add_int(chanid)
Expand Down

0 comments on commit 1cd44d6

Please sign in to comment.