From 367d276d8b7c544e1cf3d70f88a3ac2574b37f0f Mon Sep 17 00:00:00 2001 From: Andreas Griffin <116060138+andreasgriffin@users.noreply.github.com> Date: Sat, 9 Nov 2024 18:50:14 +0100 Subject: [PATCH] Fix code scanning alert no. 1: Use of insecure SSL/TLS version Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --- bitcoin_safe/gui/qt/network_settings/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bitcoin_safe/gui/qt/network_settings/main.py b/bitcoin_safe/gui/qt/network_settings/main.py index 4466bc4..419f7c6 100644 --- a/bitcoin_safe/gui/qt/network_settings/main.py +++ b/bitcoin_safe/gui/qt/network_settings/main.py @@ -93,6 +93,7 @@ def get_electrum_server_version(host: str, port: int, use_ssl: bool = True, time ssock: Optional[socket.socket] = None if use_ssl: context = ssl.create_default_context() + context.minimum_version = ssl.TLSVersion.TLSv1_2 ssock = context.wrap_socket(sock, server_hostname=host) else: ssock = sock