Feat/show detailed custom api response when testing (#2400)

This commit is contained in:
Yeuoly 2024-02-05 18:48:30 +08:00 committed by GitHub
commit bf736bc55d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 61 additions and 15 deletions

View file

@ -30,10 +30,10 @@ class APIBasedExtensionRequestor:
try:
# proxy support for security
proxies = None
if os.environ.get("API_BASED_EXTENSION_HTTP_PROXY") and os.environ.get("API_BASED_EXTENSION_HTTPS_PROXY"):
if os.environ.get("SSRF_PROXY_HTTP_URL") and os.environ.get("SSRF_PROXY_HTTPS_URL"):
proxies = {
'http': os.environ.get("API_BASED_EXTENSION_HTTP_PROXY"),
'https': os.environ.get("API_BASED_EXTENSION_HTTPS_PROXY"),
'http': os.environ.get("SSRF_PROXY_HTTP_URL"),
'https': os.environ.get("SSRF_PROXY_HTTPS_URL"),
}
response = requests.request(