controller = controller.Controller() # use interactive menu if a language isn't specified if not args.l: controller.MainMenu() sys.exit() # list languages available if "-l" is present but no language specified elif args.l == "list": controller.ListLangs() sys.exit() # if a language is specified but a payload isn't, list available # payload for that language elif args.p == "list" or not args.p: controller.ListPayloads(args.l) sys.exit() # pull out any required options from the command line and # build the proper dictionary so we can set the payload manually options = {} if args.c: options['required_options'] = {} for option in args.c: name, value = option.split("=") options['required_options'][name] = [value, ""] # pull out any msfvenom payloads/options if args.msfpayload: if args.msfoptions: options['msfvenom'] = [args.msfpayload, args.msfoptions]
controller.UpdateVeil(interactive=False) sys.exit() # call the payload folder cleaning for Veil and then exit if args.clean: controller.CleanPayloads(interactive=False) sys.exit() # use interactive menu if a payload isn't specified if not args.p: controller.MainMenu(args=args) sys.exit() # list languages available if "-p" is present but no payload specified elif args.p == "list": controller.ListPayloads() sys.exit() # pull out any required options from the command line and # build the proper dictionary so we can set the payload manually options = {} if args.c: options['required_options'] = {} for option in args.c: name, value = option.split("=") options['required_options'][name] = [value, ""] # pull out any msfvenom shellcode specification and msfvenom options if args.msfpayload: if args.msfoptions: options['msfvenom'] = [args.msfpayload, args.msfoptions]