summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--paramiko/auth_transport.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/paramiko/auth_transport.py b/paramiko/auth_transport.py
index ba0cbec8..2a6a1a29 100644
--- a/paramiko/auth_transport.py
+++ b/paramiko/auth_transport.py
@@ -97,7 +97,10 @@ class Transport (BaseTransport):
@since: fearow
"""
- return self.username
+ if self.server_mode:
+ return self.auth_username
+ else:
+ return self.username
def auth_publickey(self, username, key, event):
"""