-
Notifications
You must be signed in to change notification settings - Fork 0
/
structures.go
executable file
·43 lines (36 loc) · 1.73 KB
/
structures.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package main
import "golang.org/x/sys/windows"
const banner = `
██████ ██████ ██ ██████ ██ ███████ ██████ ██████ ██████ ███████
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
██ ███ ██ ██ ██ ██ ██ ██ ███████ ██████ ██ ██ ██ ██ █████
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
██████ ██████ ███████ ██████ ███████ ███████ ██ ██████ ██████ ██
An interactive shell to spoof some LOLBins
try !help
`
const helpcmd = `
!exit -> Exit
!cls -> Clear the screen
!help -> This help message
`
var (
ntdll = windows.NewLazySystemDLL("ntdll.dll")
ntQueryInfoProc = ntdll.NewProc("NtQueryInformationProcess")
kernel32 = windows.NewLazySystemDLL("kernel32.dll")
readProcessMemory = kernel32.NewProc("ReadProcessMemory")
writeProcessMemory = kernel32.NewProc("WriteProcessMemory")
ntResumeThread = ntdll.NewProc("NtResumeThread")
waitForSingleObject = kernel32.NewProc("WaitForSingleObject")
)
const (
PROCESS_BASIC_INFORMATION_CLASS = 0
infinite = 0xFFFFFFFF
)
type PROCESS_BASIC_INFORMATION struct {
Reserved1 uintptr
PebBaseAddress uintptr
Reserved2 [2]uintptr
UniqueProcessId uintptr
Reserved3 uintptr
}