diff --git a/utils/script.py b/utils/script.py index 25a8b9e1de14c19e95bcc5e5ae765f095ea31701..346fa504681a7cf97b35b18dcefc467b47dadda7 100644 --- a/utils/script.py +++ b/utils/script.py @@ -8,6 +8,7 @@ import json import base64 from sys import argv, exit import socket +import os def get_version(): with Gmp(connection, transform=transform) as gmp: @@ -244,13 +245,6 @@ class report_formats: xml = "a994b278-1f62-11e1-96ac-406186ea4fc5" def get_report_formats(): - # |------------- ID -----------------| |--- NAME ---| - # 5057e5cc-b825-11e4-9d0e-28d24461215b Anonymous XML - # c1645568-627a-11e3-a660-406186ea4fc5 CSV Results - # 77bd6c4a-1f62-11e1-abf0-406186ea4fc5 ITG - # c402cc3e-b531-11e1-9163-406186ea4fc5 PDF - # a3810a62-1f62-11e1-9219-406186ea4fc5 TXT - # a994b278-1f62-11e1-96ac-406186ea4fc5 XML with Gmp(connection, transform=transform) as gmp: gmp.authenticate(auth_name, auth_passwd) res = gmp.get_report_formats() @@ -401,8 +395,8 @@ def import_dep_info(file_path, endpoints_to_scan): ################ MAIN ####################################### -auth_name = "xxxx" -auth_passwd = "xxxxxxxx" +auth_name = os.getenv('GMP_USER') +auth_passwd = os.getenv('GMP_PASSWORD') logging.basicConfig(filename='debug.log', level=logging.DEBUG) local_ip = socket.gethostbyname(socket.gethostname()) connection = TLSConnection(hostname=local_ip)