import sys import time import getpass import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('convict') if options.password is None: options.password = getpass.getpass() try: print 'starting mkdirs' mkdirs = utils.Mkdirs(options) print 'running mkdirs' except: print 'Failed to create configured directories' sys.exit(1) job = ratd.lib.ScanFolder(options) try: while True:
import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib from ratd.lib import ServerVersionCheck # *************************************************************************************************************************************************** # Script returns the following values: # -1 ---> Error connecting to the ATD Server # -2 ---> Error uploading file to the ATD Server # -3 ---> Analysis failed # -4 ---> Error getting report # -5 ---> Error Obtaining vmprofilelist # 0 to 255 ---> Default Profile ID # ************************************************************************************************************************************************** if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('authOnly') if options.password is None: options.password = getpass.getpass() if options.verbosity: utils.copyleftnotice() rb_rtnv = ServerVersionCheck(options) sys.exit(rb_rtnv.rtnv)
from ratd.lib import SampleSubmit EXIT_SUCCESS = 0 EXIT_FAILURE = 1 # *************************************************************************************************************************************************** # Script returns the following values: # -1 ---> Error connecting to the ATD Server # -2 ---> Error uploading file to the ATD Server # -3 ---> Analysis failed # -4 ---> Error getting report # -5 ---> Error Obtaining vmprofilelist # 0 to 5 ---> Severity level (confident of the sample to be malware # ************************************************************************************************************************************************** if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('sample') if options.password is None: options.password = getpass.getpass() if options.verbosity: utils.copyleftnotice() sample = SampleSubmit(options) severity = sample.rtnv md5 = sample.rtv_md5 sys.exit(severity)
import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib from ratd.lib import FetchProfiles # *************************************************************************************************************************************************** # Script returns the following values: # -1 ---> Error connecting to the ATD Server # -2 ---> Error uploading file to the ATD Server # -3 ---> Analysis failed # -4 ---> Error getting report # -5 ---> Error Obtaining vmprofilelist # 0 to 255 ---> Default Profile ID # ************************************************************************************************************************************************** if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('profile') if options.password is None: options.password = getpass.getpass() if options.verbosity: utils.copyleftnotice() rb_rtnv = FetchProfiles(options) sys.exit(rb_rtnv.rtnv)
import sys import time import getpass import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('watch') if options.password is None: options.password = getpass.getpass() if options.verbosity: utils.copyleftnotice() try: mkdirs = utils.Mkdirs(options) except: print 'Failed to create configured directories' sys.exit(1) job = ratd.lib.ScanFolder(options)
import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib from ratd.lib import SearchReports # *************************************************************************************************************************************************** # Script returns the following values: # -1 ---> Error connecting to the ATD Server # -2 ---> Error uploading file to the ATD Server # -3 ---> Analysis failed # -4 ---> Error getting report # -5 ---> Error Obtaining vmprofilelist # 0 to 255 ---> Default Profile ID # ************************************************************************************************************************************************** if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('search') if options.password is None: options.password = getpass.getpass() if options.verbosity: utils.copyleftnotice() rb_rtnv = SearchReports(options) sys.exit(rb_rtnv.rtnv)
#!/usr/bin/env python # A tool designed to quickly summarize the downloaded *.json files in your ENV['reports'] directory. import sys import getpass import ratd.utils as utils import ratd.cliargs from ratd.cliargs import CliArgs import ratd.lib from ratd.lib import Reporter if __name__ == '__main__': # Get the list of parameters passed from command line options = CliArgs('reporter') if options.verbosity: utils.copyleftnotice() report = ratd.lib.Reporter(options) sys.exit(0)