예제 #1
0
def conf_parser():
    if pyoptions.args_conf == 'const':
        if os.path.isfile(paths.buildconf_path):
            build_conf_dic(source=paths.buildconf_path)
    else:
        paths.buildconf_path = pyoptions.args_conf
        build_conf_dic(source=paths.buildconf_path)
def conf_parser():
    if pyoptions.args_conf == 'const':
        if os.path.isfile(paths.buildconf_path):
            build_conf_dic()
    elif os.path.isfile(pyoptions.args_conf):
        paths.buildconf_path = pyoptions.args_conf
        build_conf_dic()
    else:
        exit(pyoptions.CRLF +
             cool.red("[-] Please specify the exists configuration file"))
예제 #3
0
             get_passcratch_dic(args.plugins[1], encodeflag=args.encode)
         elif len(args.plugins) == 1:
             exit(CRLF + "[-] Plug %s need other arguments" %
                  cool.red(args.plugins[0]))
         else:
             exit(CRLF + cool.red("[-] Argument option error"))
 elif args.sedb:
     try:
         shell = SEDB()
         shell.cmdloop()
     except Exception as e:
         exit(e)
 elif args.conf != 'default':
     if args.conf == 'const':
         if os.path.isfile(get_conf_path()):
             build_conf_dic()
     elif os.path.isfile(args.conf):
         set_conf_path(args.conf)
         build_conf_dic()
     else:
         exit(CRLF +
              cool.red("[-] Please specify the exists configuration file"))
 elif args.tool:
     if len(args.tool) >= 1:
         if args.tool[0] in tool_range:
             # shredder
             if args.tool[0] == tool_range[0]:
                 if len(args.tool) == 1 and os.listdir(
                         get_result_store_path()):
                     shredder_enter(get_result_store_path())
                 elif len(args.tool) == 1: