From 5d65b5d1c1a7723548712a65e119e4ac790d10bf Mon Sep 17 00:00:00 2001 From: "Nicholas S. Castellano" Date: Sun, 16 Aug 2020 14:39:59 -0400 Subject: [PATCH] Add web proxy support using https_proxy environment variable --- checkov/common/bridgecrew/platform_integration.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/checkov/common/bridgecrew/platform_integration.py b/checkov/common/bridgecrew/platform_integration.py index 2b8b2deb2da..6a6e50d9f34 100644 --- a/checkov/common/bridgecrew/platform_integration.py +++ b/checkov/common/bridgecrew/platform_integration.py @@ -17,7 +17,11 @@ UNAUTHORIZED_MESSAGE = 'User is not authorized to access this resource with an explicit deny' DEFAULT_REGION = "us-west-2" -http = urllib3.PoolManager() + +try: + http = urllib3.ProxyManager(os.environ['https_proxy']) +except KeyError: + http = urllib3.PoolManager() class BcPlatformIntegration(object):