summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--server/piztor/server.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/server/piztor/server.py b/server/piztor/server.py
index d175d99..d9e8bc3 100644
--- a/server/piztor/server.py
+++ b/server/piztor/server.py
@@ -679,6 +679,13 @@ class ChangePasswordHandler(RequestHandler):
uauth.set_password(new_pass)
self.session.commit()
logger.info("Password changed successfully!")
+
+ pt = RequestHandler.push_tunnels
+ uid = uauth.uid
+ pt[uid].close()
+ del pt[uid]
+ uauth.regen_token()
+
return self.pack(struct.pack("!B", _StatusCode.sucess))