From 8cdf036ac8576ff024a9ab161b6004e86eda2632 Mon Sep 17 00:00:00 2001 From: "pixeebot[bot]" <104101892+pixeebot[bot]@users.noreply.github.com> Date: Wed, 21 Feb 2024 20:13:58 +0000 Subject: [PATCH 1/2] Sandbox URL Creation --- requirements.txt | 1 + sigopt/orchestrate/iam/service.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/requirements.txt b/requirements.txt index 9a60bfe4..27705cb2 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,3 +6,4 @@ pypng>=0.0.20 PyYAML>=5,<7 requests>=2.25.0,<3.0.0 urllib3>=1.26.5,<2.0.0 +security~=1.2.0 diff --git a/sigopt/orchestrate/iam/service.py b/sigopt/orchestrate/iam/service.py index 4f1683f1..7ff5e80a 100644 --- a/sigopt/orchestrate/iam/service.py +++ b/sigopt/orchestrate/iam/service.py @@ -6,10 +6,10 @@ import boto3 import certifi -import requests from OpenSSL import SSL from ..services.aws_base import AwsService +from security import safe_requests class AwsIamService(AwsService): @@ -36,7 +36,7 @@ def describe_eks_role(self, role_name): return self.iam.Role(role_name) def get_thumbprint_from_oidc_issuer(self, oidc_url): - response = requests.get(f"{oidc_url}/.well-known/openid-configuration") + response = safe_requests.get(f"{oidc_url}/.well-known/openid-configuration") response.raise_for_status() keys_url = response.json()["jwks_uri"] parsed_url = urlparse(keys_url) From 15a230e8cc273a813b80b763d9ed20df49974126 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Wed, 21 Feb 2024 20:14:42 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- requirements.txt | 2 +- sigopt/orchestrate/iam/service.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/requirements.txt b/requirements.txt index 27705cb2..ff723b8d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,5 +5,5 @@ packaging>=21.3 pypng>=0.0.20 PyYAML>=5,<7 requests>=2.25.0,<3.0.0 -urllib3>=1.26.5,<2.0.0 security~=1.2.0 +urllib3>=1.26.5,<2.0.0 diff --git a/sigopt/orchestrate/iam/service.py b/sigopt/orchestrate/iam/service.py index 7ff5e80a..06f6a62c 100644 --- a/sigopt/orchestrate/iam/service.py +++ b/sigopt/orchestrate/iam/service.py @@ -7,9 +7,9 @@ import boto3 import certifi from OpenSSL import SSL +from security import safe_requests from ..services.aws_base import AwsService -from security import safe_requests class AwsIamService(AwsService):