if not os.path.isdir(paths.results_path): os.makedirs(paths.results_path) except WindowsError: exit(pyoptions.CRLF + cool.red("[-] Cannot create result file: %s " % paths.results_path)) if __name__ == '__main__': print("{}".format(cool.green(pydictor_art_text))) init() if pyoptions.args_base: get_base_dic(pyoptions.args_base) elif pyoptions.args_char: get_char_dic(pyoptions.args_char) elif pyoptions.args_chunk: get_chunk_dic(pyoptions.args_chunk) elif pyoptions.args_extend: get_extend_dic(pyoptions.args_extend) elif pyoptions.args_plug: plug_parser() elif pyoptions.args_sedb: try: sedb_tricks() shell = SEDB() shell.cmdloop() except Exception as e: exit(e) elif pyoptions.args_conf != 'default': conf_parser() elif pyoptions.args_pattern != 'default': pattern_parser()
print(CRLF + cool.red("[-] Cannot create %s, default %s" % (args.output, get_result_store_path()))) if os.path.isdir(tmppath): set_result_store_path(tmppath) if args.base: get_base_dic(args.len[0], args.len[1], args.base, args.encode, args.head, args.tail) elif args.customchar: get_char_dic(args.len[0], args.len[1], args.customchar, args.encode, args.head, args.tail) elif args.chunk: chunk = [] for item in args.chunk: if item != '': chunk.append(item) get_chunk_dic(chunk, args.encode, args.head, args.tail) elif args.plugins: if args.plugins[0] not in plug_range: exit("[!] Choose plug from ({0}, {1}, {2}, {3})".format( cool.fuchsia(plug_range[0]), cool.fuchsia(plug_range[1]), cool.fuchsia(plug_range[2]), cool.fuchsia(plug_range[3]))) else: # id card plugin if len(args.plugins) == 1 and args.plugins[0] == plug_range[0]: get_idcard_post(plug_range[0], args.encode, args.head, args.tail, args.sex) elif len(args.plugins) == 1 and args.plugins[0] == plug_range[1]: get_idcard_post(plug_range[1], args.encode, args.head, args.tail, args.sex) # extend_enter plugin elif len(args.plugins) == 2 and args.plugins[0] == plug_range[2]: