mirror of
https://github.com/mozilla/cipherscan.git
synced 2024-11-22 14:23:41 +01:00
Don't expect scripts to be in working directory
This commit is contained in:
parent
983f85d2d4
commit
0e7996181a
@ -456,6 +456,8 @@ def main():
|
||||
help='use nagios-conformant exit codes')
|
||||
args = parser.parse_args()
|
||||
|
||||
mypath = os.path.dirname(os.path.realpath(sys.argv[0]))
|
||||
|
||||
if args.debug:
|
||||
logging.basicConfig(stream=sys.stderr, level=logging.DEBUG)
|
||||
else:
|
||||
@ -473,9 +475,9 @@ def main():
|
||||
logging.debug('Invoking cipherscan with target: ' + args.target)
|
||||
data=''
|
||||
if args.openssl:
|
||||
data = subprocess.check_output(['./cipherscan', '-o', args.openssl, '-j', args.target])
|
||||
data = subprocess.check_output([mypath + '/cipherscan', '-o', args.openssl, '-j', args.target])
|
||||
else:
|
||||
data = subprocess.check_output(['./cipherscan', '-j', args.target])
|
||||
data = subprocess.check_output([mypath + '/cipherscan', '-j', args.target])
|
||||
exit_status=process_results(data, args.level, args.json, args.nagios)
|
||||
else:
|
||||
if os.fstat(args.infile.fileno()).st_size < 2:
|
||||
|
Loading…
Reference in New Issue
Block a user