From 39626b9f8fffeb1d5ca1dfa03ba9faef6374c344 Mon Sep 17 00:00:00 2001 From: ShahanaFarooqui Date: Tue, 25 Jun 2024 16:53:33 -0700 Subject: [PATCH] clnrest: Fixes `ssl_version` deprecated warning Reference Issue #6931: Fixes `Warning: option `ssl_version` is deprecated and it is ignored. Use ssl_context instead.` Changelog-None. --- plugins/clnrest/clnrest.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/clnrest/clnrest.py b/plugins/clnrest/clnrest.py index f11ee9a88727..3540e295f64d 100755 --- a/plugins/clnrest/clnrest.py +++ b/plugins/clnrest/clnrest.py @@ -157,7 +157,8 @@ def set_application_options(plugin): "loglevel": "warning", "certfile": f"{CERTS_PATH}/client.pem", "keyfile": f"{CERTS_PATH}/client-key.pem", - "ssl_version": ssl.PROTOCOL_TLSv1_2 + "cafile": f"{CERTS_PATH}/ca.pem", + "ssl": ssl.SSLContext(protocol=ssl.PROTOCOL_TLS_SERVER), } return options