Skip to content

Instantly share code, notes, and snippets.

@g-k
Created March 7, 2017 21:01
Show Gist options
  • Save g-k/d43c391a073c467fc75ba06a81538def to your computer and use it in GitHub Desktop.
Save g-k/d43c391a073c467fc75ba06a81538def to your computer and use it in GitHub Desktop.
@@ -372,13 +372,15 @@ def main(argv):
try:
# Wait for ZAP to start
- zap = ZAPv2(proxies={'http': 'http://' + zap_ip + ':' + str(port), 'https': 'http://' + zap_ip + ':' + str(port)})
+ zap = ZAPv2(proxies={'http': 'http://' + 'localhost' + ':' + str(port), 'https': 'http://' + 'localhost' + ':' + str(port)})
+ logging.info('proxies %s' % {'http': 'http://' + zap_ip + ':' + str(port), 'https': 'http://' + zap_ip + ':' + str(port)})
for x in range(0, timeout):
try:
logging.debug ('ZAP Version ' + zap.core.version)
logging.debug ('Took ' + str(x) + ' seconds')
break
- except IOError:
+ except IOError as e:
+ logging.debug('IOError waiting for ZAP to start: %s' % e)
time.sleep(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment