Beispiel #1
0
def launch_module(module):
	ok = False
	modulesToLaunch = []
	try:
		# Launch only a specific module
		for i in args:
			if args[i] and i in b:
				modulesToLaunch.append(i)
	except:
		# if no args
		pass

	# Launch all modules
	if not modulesToLaunch:
		modulesToLaunch = module

	for i in modulesToLaunch:
		try:
			Header().title_info(i.capitalize()) 		# print title
			pwdFound = module[i].run(i.capitalize())	# run the module
			print_output(i.capitalize(), pwdFound) 		# print the results

			# return value - not used but needed 
			yield True, i.capitalize(), pwdFound
		except:
			traceback.print_exc()
			print
			error_message = traceback.format_exc()
			yield False, i.capitalize(), error_message
Beispiel #2
0
def launch_module(module):
    ok = False
    modulesToLaunch = []
    try:
        # Launch only a specific module
        for i in args:
            if args[i] and i in b:
                modulesToLaunch.append(i)
    except:
        # if no args
        pass

    # Launch all modules
    if not modulesToLaunch:
        modulesToLaunch = module

    for i in modulesToLaunch:
        try:
            Header().title_info(i.capitalize())  # print title
            pwdFound = module[i].run(i.capitalize())  # run the module
            print_output(i.capitalize(), pwdFound)  # print the results

            # return value - not used but needed
            yield True, i.capitalize(), pwdFound
        except:
            traceback.print_exc()
            print
            error_message = traceback.format_exc()
            yield False, i.capitalize(), error_message
Beispiel #3
0
def launch_module(b):
    ok = False
    modulesToLaunch = []
    # Launch only a specific module
    for i in args:
        if args[i] and i in b:
            modulesToLaunch.append(i)

    # Launch all modules
    if not modulesToLaunch:
        modulesToLaunch = b

    for i in modulesToLaunch:
        Header().title_info(i.capitalize())  # print title
        pwdFound = b[i].run(i.capitalize())  # run the module
        print_output(i.capitalize(), pwdFound)  # print the results
Beispiel #4
0
def launch_module(b):
	ok = False
	modulesToLaunch = []
	# Launch only a specific module
	for i in args:
		if args[i] and i in b:
			modulesToLaunch.append(i)

	# Launch all modules
	if not modulesToLaunch:
		modulesToLaunch = b

	for i in modulesToLaunch:
			Header().title_info(i.capitalize()) 	# print title
			pwdFound = b[i].run(i.capitalize())		# run the module
			print_output(i.capitalize(), pwdFound) 	# print the results
def launch_module(module,
                  need_high_privileges=False,
                  need_system_privileges=False,
                  not_need_to_be_in_env=False,
                  cannot_be_impersonate_using_tokens=False):
    modulesToLaunch = []
    try:
        # Launch only a specific module
        for i in args:
            if args[i] and i in module:
                modulesToLaunch.append(i)
    except:
        # if no args
        pass

    # Launch all modules
    if not modulesToLaunch:
        modulesToLaunch = module

    for i in modulesToLaunch:
        if not_need_to_be_in_env and module[i].need_to_be_in_env:
            continue

        if need_high_privileges ^ module[i].need_high_privileges:
            continue

        if need_system_privileges ^ module[i].need_system_privileges:
            continue

        if cannot_be_impersonate_using_tokens and module[
                i].cannot_be_impersonate_using_tokens:
            continue

        try:
            Header().title_info(i.capitalize())  # print title
            pwdFound = module[i].run(i.capitalize())  # run the module
            print_output(i.capitalize(), pwdFound)  # print the results

            # return value - not used but needed
            yield True, i.capitalize(), pwdFound
        except:
            traceback.print_exc()
            print
            error_message = traceback.format_exc()
            yield False, i.capitalize(), error_message
Beispiel #6
0
def launch_module(module, need_high_privileges=False, need_system_privileges=False, not_need_to_be_in_env=False, cannot_be_impersonate_using_tokens=False):
	modulesToLaunch = []
	try:
		# Launch only a specific module
		for i in args:
			if args[i] and i in module:
				modulesToLaunch.append(i)
	except:
		# if no args
		pass

	# Launch all modules
	if not modulesToLaunch:
		modulesToLaunch = module
	
	for i in modulesToLaunch:
		if not_need_to_be_in_env and module[i].need_to_be_in_env:
			continue

		if need_high_privileges ^ module[i].need_high_privileges:
			continue

		if need_system_privileges ^ module[i].need_system_privileges:
			continue

		if cannot_be_impersonate_using_tokens and module[i].cannot_be_impersonate_using_tokens:
			continue
		
		try:
			Header().title_info(i.capitalize()) 		# print title
			pwdFound = module[i].run(i.capitalize())	# run the module
			print_output(i.capitalize(), pwdFound) 		# print the results
			
			# return value - not used but needed 
			yield True, i.capitalize(), pwdFound
		except:
			traceback.print_exc()
			print
			error_message = traceback.format_exc()
			yield False, i.capitalize(), error_message
Beispiel #7
0
        else:
            user_pwd_temp.append(constant.finalResults)

    constant.finalResults = {}
    constant.finalResults['User'] = "******"

    # Is a child process
    if isChild:
        constant.output = 'json'
        try:
            if "windows" in argv or "all" in argv:
                Secrets().run()

            elif "wifi" in argv or "all" in argv:
                pwdFound = Wifi().run()
                print_output('Wifi', pwdFound)
        except Exception, e:
            print_debug('ERROR', e)
            pass
        stdoutRes.append(constant.finalResults)

        # Write output to a tmp file
        with open(tmpFile, "w+") as f:
            json.dump(stdoutRes, f)

    # Is not a child process
    else:
        # Print the entire output of children results
        parseJsonResult(stdoutRes)

        # Get all privilege passwords
Beispiel #8
0
        else:
            user_pwd_temp.append(constant.finalResults)

    constant.finalResults = {}
    constant.finalResults["User"] = "******"

    # Is a child process
    if isChild:
        constant.output = "json"
        try:
            if "windows" in argv or "all" in argv:
                Secrets().run()

            elif "wifi" in argv or "all" in argv:
                pwdFound = Wifi().run()
                print_output("Wifi", pwdFound)
        except Exception, e:
            print_debug("ERROR", e)
            pass
        stdoutRes.append(constant.finalResults)

        # Write output to a tmp file
        with open(tmpFile, "w+") as f:
            json.dump(stdoutRes, f)

            # Is not a child process
    else:
        # Print the entire output of children results
        parseJsonResult(stdoutRes)

        # Get all privilege passwords