From 70459a5c6def9d5c8c115cdd8f9691b35170c8db Mon Sep 17 00:00:00 2001 From: jm22dogs Date: Tue, 29 Apr 2025 16:46:09 +0100 Subject: [PATCH 1/2] add AYON_CERT_FILE to try server request --- ayon_api/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ayon_api/utils.py b/ayon_api/utils.py index 5529f121f..8fd5dfcb6 100644 --- a/ayon_api/utils.py +++ b/ayon_api/utils.py @@ -329,7 +329,7 @@ def _try_connect_to_server( try: # TODO add validation if the url lead to AYON server # - this won't validate if the url lead to 'google.com' - requests.get(url, timeout=timeout) + requests.get(url, timeout=timeout, verify=os.getenv("AYON_CERT_FILE")) except BaseException: return False From 412b41587244d0f39e986439226e5b6d7d5d09c9 Mon Sep 17 00:00:00 2001 From: Juan M <166030421+jm22dogs@users.noreply.github.com> Date: Tue, 29 Apr 2025 17:12:21 +0100 Subject: [PATCH 2/2] accept jakub's suggestion Co-authored-by: Jakub Trllo <43494761+iLLiCiTiT@users.noreply.github.com> --- ayon_api/utils.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ayon_api/utils.py b/ayon_api/utils.py index 8fd5dfcb6..b9f5b8aa5 100644 --- a/ayon_api/utils.py +++ b/ayon_api/utils.py @@ -329,7 +329,9 @@ def _try_connect_to_server( try: # TODO add validation if the url lead to AYON server # - this won't validate if the url lead to 'google.com' - requests.get(url, timeout=timeout, verify=os.getenv("AYON_CERT_FILE")) + requests.get( + url, timeout=timeout, verify=os.getenv("AYON_CERT_FILE") + ) except BaseException: return False