Skip to content

Commit

Permalink
catch authentication errors and disconnect potential client cleanly w…
Browse files Browse the repository at this point in the history
…ith a message

git-svn-id: https://xpra.org/svn/Xpra/trunk@5312 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Jan 30, 2014
1 parent e3d0082 commit 4648a08
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/xpra/server/proxy_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,12 @@ def start_proxy(self, client_proto, c, auth_caps):
#find the target server session:
def disconnect(msg):
self.send_disconnect(client_proto, msg)
sessions = client_proto.authenticator.get_sessions()
try:
sessions = client_proto.authenticator.get_sessions()
except Exception, e:
log.error("failed to get the list of sessions: %s", e)
disconnect("authentication error")
return
if sessions is None:
disconnect("no sessions found")
return
Expand Down

0 comments on commit 4648a08

Please sign in to comment.