Verified Commit a07be32f authored by Benjamin "Ziirish" SANS's avatar Benjamin "Ziirish" SANS
Browse files

support upcoming '-V' flag instead of '-v'

parent 12c33cd9
......@@ -78,11 +78,22 @@ class Monitor(object):
# newer than BURP_MINIMAL_VERSION
try:
if self.burpbin:
cmd = [self.burpbin, '-v']
version = subprocess.check_output(
cmd,
universal_newlines=True
).rstrip()
# the '--version' flag changed in burp 2.2.12
cmd = [self.burpbin, '-V']
version = None
try:
version = subprocess.check_output(
cmd,
universal_newlines=True
).rstrip()
except subprocess.CalledProcessError:
pass
if version is None:
cmd = [self.burpbin, '-v']
version = subprocess.check_output(
cmd,
universal_newlines=True
).rstrip()
if version < BURP_MINIMAL_VERSION and \
getattr(self.app, 'strict', True):
self.logger.critical(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment