myph.git


myph

~ shellcode loader for your evasion needs
git clone https://github.com/matro7sh/myph.git
log | files | refs | archive | README | LICENSE

commit 94d48406f9fb7a7c80c984e981dfac3a0fa31c92
parent db82f5a8774b85293cf086b87a81caa3209e5043
Author: winds0r <[email protected]>
Date: Wed, 6 Dec 2023 23:52:52 +0100

fix(cli): compiling as `exe` does not set the correct env values

Diffstat:
Mcli/parser.go | 4++--

1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/cli/parser.go b/cli/parser.go
@@ -43,9 +43,9 @@ const ASCII_ART = `
     `
 
 func BuildLoader(opts *Options) *exec.Cmd {
+    os.Setenv("GOOS", opts.OS)
+    os.Setenv("GOARCH", opts.Arch)
 	if opts.BuildType == "dll" {
-		os.Setenv("GOOS", opts.OS)
-		os.Setenv("GOARCH", opts.Arch)
 		os.Setenv("CGO_ENABLED", "1")
 		os.Setenv("CC", "x86_64-w64-mingw32-gcc")
 		fmt.Println("[*] Compiling payload as dll...")