From 78196f209cf9d6035729be43fa28f00d18c4212c Mon Sep 17 00:00:00 2001 From: EndMove Date: Sat, 26 Feb 2022 18:26:12 +0100 Subject: [PATCH 1/2] Update Python client (fix bugs) --- controller/AppController.py | 3 ++- net/UnicastConnection.py | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/controller/AppController.py b/controller/AppController.py index 7b3376a..21acc5e 100644 --- a/controller/AppController.py +++ b/controller/AppController.py @@ -31,9 +31,10 @@ class AppController: if message_id == Protocol.PARSE_SIGNOK: self.window_controller.switch_connected_mode() self.show_message("Connection done", False) + self.on_filelist() elif message_id == Protocol.PARSE_SIGNERROR: self.show_message("Error during SIGN_IN / SIGN_UP", True) - self.on_filelist() + self.connection.close() except Exception as ex: print(ex) traceback.print_exc() diff --git a/net/UnicastConnection.py b/net/UnicastConnection.py index a11ea9a..e854269 100644 --- a/net/UnicastConnection.py +++ b/net/UnicastConnection.py @@ -107,5 +107,11 @@ class UnicastConnection: def close(self): self.sock.close() + self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + self.is_connected = False + self.is_tls = False + self.ssock = None + self.ca_path = None + self.ssl_info = None From ba002a4392b303b6adbd72bc3e16d2313412b1ae Mon Sep 17 00:00:00 2001 From: EndMove Date: Sat, 5 Mar 2022 15:05:52 +0100 Subject: [PATCH 2/2] Add default login value --- gui/MainWindow.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gui/MainWindow.py b/gui/MainWindow.py index 16dfef2..e73ae59 100644 --- a/gui/MainWindow.py +++ b/gui/MainWindow.py @@ -11,10 +11,14 @@ class MainWindow: self.root.title("SecCon - © Louis SWINNEN 2022") self.root.config(bd=5) self.host = tk.StringVar() + self.host.set("127.0.0.1") self.passw = tk.StringVar() + self.passw.set("aaaaa") self.login = tk.StringVar() + self.login.set("aa") self.tls = tk.BooleanVar() self.port = tk.IntVar() + self.port.set(8500) self.draw_window() def start_main_loop(self):