Skip to content

Commit

Permalink
Update revshell.go
Browse files Browse the repository at this point in the history
  • Loading branch information
BetterDefender authored Aug 8, 2023
1 parent 28d3a9e commit 159bccc
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions revshell.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,17 @@ import (
"fmt"
"os"
"strings"
// "runtime"
"github.com/fatih/color"
)

func main() {
// if runtime.GOOS == "windows" {
// // 禁用颜色
// color.NoColor = true
// }

color.NoColor = true
// red := "\u001b[31m" // 红色
green := "\u001b[32m" // 绿色
// yellow := "\u001b[33m" // 黄色
Expand Down Expand Up @@ -205,7 +213,7 @@ var dictionary = map[string][]string{
fmt.Println(asciiArt)
fmt.Println(brightYellow + "Usage: \n"+ green + "./revshell [IPADDR] [PORT] [LANGUAGE]\n")
fmt.Println(brightMagenta + "Example: \n"+ green + "./revshell 192.168.1.1 1234 bash\n")
fmt.Println(brightCyan + "Supported languages: \n" + green + "bash|sh|nc|ruby|php|python|rcat|perl|socat|node|telnet|zsh|lua|golang|vlang|awk|crystal")
fmt.Println(brightCyan + "Supported languages: \n" + green + "bash|sh|nc|ruby|php|python|rcat|perl|socat|node|telnet|zsh|lua|golang|vlang|awk|crystal" + resett)
return
}

Expand All @@ -218,7 +226,7 @@ var dictionary = map[string][]string{
for _, command := range commands {
replaced := strings.ReplaceAll(command, "[IPADDR]", ipAddr)
replaced = strings.ReplaceAll(replaced, "[PORT]", port)
fmt.Println(green + replaced)
fmt.Println(green + replaced + resett)
}
} else {
fmt.Println("Language not found in the dictionary.")
Expand Down

0 comments on commit 159bccc

Please sign in to comment.