joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140078a84
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
movsxd r15, ecx
lea r9, [0x1400d06a0]
mov rax, r15
mov rbp, r15
and eax, 0x3f
sar rbp, 6
mov ecx, 4
xor esi, esi
mov r14, rdx
lea rdi, [rax + rax*8]
mov rax, qword [r9 + rbp*8]
lea r13d, [rcx + 6]
mov r10, qword [rax + rdi*8 + 0x28]
test r8, r8
je 0x140078adb
cmp word [rdx], r13w
jne 0x140078adb
or byte [rax + rdi*8 + 0x38], cl
jmp 0x140078ae0
and byte [rax + rdi*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rbx, r14
cmp r14, r8
jae 0x140078c05
mov r11d, 0xd
lea r12d, [r11 - 0xb]
movzx ecx, word [rdx]
cmp cx, 0x1a
je 0x140078c26
lea r9, [rdx + 2]
cmp cx, r11w
je 0x140078b19
mov rdx, r9
mov word [rbx], cx
jmp 0x140078b40
cmp r9, r8
jae 0x140078b50
cmp word [r9], r13w
mov rax, r12
mov ecx, 4
cmove rax, rcx
add rdx, rax
mov eax, r13d
cmp word [r9], r13w
cmovne ax, r11w
mov word [rbx], ax
mov rax, r12
add rbx, rax
cmp rdx, r8
jb 0x140078afa
jmp 0x140078c05
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rsi
mov r8d, r12d
lea rdx, [rsp + 0x70]
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140078bfa
cmp dword [rsp + 0x80], esi
je 0x140078bfa
lea r8, [0x1400d06a0]
mov rax, qword [r8 + rbp*8]
test byte [rax + rdi*8 + 0x38], 0x48
je 0x140078bd2
movzx eax, word [rsp + 0x70]
cmp ax, r13w
jne 0x140078ba2
mov word [rbx], r13w
jmp 0x140078c02
mov ecx, 0xd
mov word [rsp + 0x78], ax
mov word [rbx], cx
mov rax, qword [r8 + rbp*8]
lea rcx, [rax + rdi*8]
mov al, byte [rsp + rsi + 0x78]
mov byte [rcx + rsi + 0x3a], al
inc rsi
cmp rsi, r12
jl 0x140078baf
mov rax, qword [r8 + rbp*8]
mov byte [rax + rdi*8 + 0x3c], r13b
jmp 0x140078c02
cmp word [rsp + 0x70], r13w
jne 0x140078bdf
cmp rbx, r14
je 0x140078b9c
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.14007a888
cmp word [rsp + 0x70], r13w
je 0x140078c05
mov ecx, 0xd
mov word [rbx], cx
add rbx, r12
sub rbx, r14
sar rbx, 1
lea eax, [rbx + rbx]
mov rbx, qword [rsp + 0x88]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea r8, [0x1400d06a0]
mov rdx, qword [r8 + rbp*8]
mov al, byte [rdx + rdi*8 + 0x38]
test al, 0x40
jne 0x140078bff
or al, r12b
mov byte [rdx + rdi*8 + 0x38], al
jmp 0x140078c05
Function at 0x14008037c
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x140080178

Function at 0x14008b960
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x14008b976
mov al, 1
jmp 0x14008b9d6
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x14008b987
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x14008b9d4
mov ecx, dword [rcx + 0x18]
nop
call fcn.14008ea14
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14008b9d4
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x14008b9d4
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x14008b9d4
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x14008b9d6
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x14008ddc0
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0x1050
call fcn.140099720
sub rsp, rax
mov rax, qword [0x1400ca010]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.140089ffc
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x14008de0f
mov rax, rbp
jmp 0x14008df17
mov rax, qword [rbx]
mov rcx, r14
sub rax, qword [rbx + 8]
and ecx, 0x3f
cqo
mov rbx, r14
sub rax, rdx
sar rbx, 6
sar rax, 1
mov r9, r15
lea r12, [rcx + rcx*8]
mov rsi, rax
lea rax, [0x140000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0xd06a0]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.14007a880
mov r13, rax
lea rax, [0x140000000]
mov rcx, qword [rax + rbx*8 + 0xd06a0]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x14008df13
mov rcx, qword [rcx + r12*8 + 0x28]
lea r9, [rsp + 0x30]
mov r8d, 0x1000
mov qword [rsp + 0x20], rdi
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14008df13
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.14007a880
test rax, rax
js 0x14008df13
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x14008df13
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x14008df05
lea r8, [0x140000000]
cmp rcx, rdx
jae 0x14008df05
cmp byte [rcx], 0xd
jne 0x14008deeb
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x14008defa
cmp byte [rcx + 1], 0xa
jne 0x14008defa
inc rcx
jmp 0x14008defa
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0xca3f0]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x14008decd
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x14008df17
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.140047410
mov rbx, qword [rsp + 0x1090]
add rsp, 0x1050
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x14008eb24
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.14007a888
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.14007a888
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x14008ec74
cmp rax, 0xffffffffffffffff
je 0x14008ec74
xor edi, edi
test rbp, rbp
jle 0x14008ec1f
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.140088bb4
mov rbx, rax
test rax, rax
jne 0x14008ebac
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x14008ec15
mov edx, 0x8000
mov ecx, r14d
call fcn.1400811f4
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.14008c654
cmp eax, 0xffffffff
je 0x14008ebf5
cdqe
sub rbp, rax
test rbp, rbp
jg 0x14008ebbc
mov edx, r15d
mov ecx, r14d
call fcn.1400811f4
jmp 0x14008ec15
cmp byte [rsi + 0x38], dil
je 0x14008ec0c
cmp dword [rsi + 0x34], 5
jne 0x14008ec0c
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x14008ec15
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.140088c2c
jmp 0x14008ec88
jns 0x14008ec88
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.14007a888
cmp rax, 0xffffffffffffffff
jne 0x14008ec40
cmp byte [rsi + 0x30], dil
je 0x14008ec88
mov edi, dword [rsi + 0x2c]
jmp 0x14008ec88
mov ecx, r14d
call fcn.14008ea14
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x14008ec88
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, 0xd
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
jmp 0x14008ec88
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x14008ec81
mov eax, dword [rsi + 0x2c]
jmp 0x14008ec86
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.14007a888
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret
Function at 0x1400919d8
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor ebp, ebp
mov rbx, rax
test rax, rax
je 0x140091a5f
mov rsi, rbx
cmp word [rax], bp
je 0x140091a1e
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x140091a08
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x140091a04
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.140088c68
mov rdi, rax
test rax, rax
je 0x140091a4c
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.14006d650
mov rbp, rdi
xor ecx, ecx
call fcn.140088c2c
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rbp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x140094688
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov esi, edx
mov ebx, ecx
call fcn.14008a510
mov ecx, ebx
lea r8, [rsp + 0x30]
and ecx, 0x3ff
mov r9d, 2
bts ecx, 0xa
mov edx, 0x20000001
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
xor edx, edx
test eax, eax
je 0x140094729
cmp ebx, dword [rsp + 0x30]
je 0x140094722
test esi, esi
je 0x140094722
mov r10, qword [rdi + 0x98]
mov r9d, edx
movzx r8d, word [r10]
lea rcx, [r10 + 2]
lea eax, [r8 - 0x41]
cmp ax, 0x19
jbe 0x1400946fd
sub r8w, 0x61
cmp r8w, 0x19
ja 0x14009470a
movzx r8d, word [rcx]
inc r9d
add rcx, 2
jmp 0x1400946e7
or rax, 0xffffffffffffffff
inc rax
cmp word [r10 + rax*2], dx
jne 0x14009470e
cmp r9d, eax
setne dl
mov eax, edx
jmp 0x14009472b
mov eax, 1
jmp 0x14009472b
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x180934108
Capabilities:
Decompress data using aplib

Disassembly:
call 0x18093428f
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x180934139
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x18093411f
add dl, dl
jne 0x180934146
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1809341a6
xor eax, eax
add dl, dl
jne 0x180934155
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x18093425d
add dl, dl
jne 0x180934166
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x180934173
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x180934180
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x18093418d
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x18093419a
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x18093412e
mov eax, 1
add dl, dl
jne 0x1809341b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1809341c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1809341ab
sub eax, ebx
mov ebx, 1
jne 0x1809341fc
mov ecx, 1
add dl, dl
jne 0x1809341de
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x1809341eb
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1809341d3
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x18093412e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x180934218
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x180934225
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x18093420d
cmp eax, 0x7d00
jae 0x18093424b
cmp eax, 0x500
jb 0x180934246
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x18093412e
cmp eax, 0x7f
ja 0x18093424e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x18093412e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x180934282
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x18093412e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x180001350
Capabilities:
Link many functions at runtime

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
lea rcx, [0x180051c10]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov qword [rbx + 0x1018], rax
test rax, rax
je 0x180001389
lea rdx, str.WTSGetActiveConsoleSessionId
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x1068], rax
lea rcx, str.Wtsapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rbx + 0x1020], rax
test rax, rax
je 0x1800013b9
lea rdx, str.WTSQueryUserToken
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x1060], rax
lea rcx, [0x180051bb8]
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rbx + 0x1028], rax
test rax, rax
je 0x180001459
lea rdx, [0x180051ba0]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rbx + 0x1028]
lea rdx, [0x180051b90]
mov qword [rbx + 0x1058], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rbx + 0x1028]
lea rdx, str.DuplicateTokenEx
mov qword [rbx + 0x1048], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rbx + 0x1028]
lea rdx, str.GetTokenInformation
mov qword [rbx + 0x1050], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rbx + 0x1028]
lea rdx, [0x180051b48]
mov qword [rbx + 0x1040], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x1070], rax
lea rcx, [0x180051b38]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov qword [rbx + 0x1010], rax
test rax, rax
je 0x1800014a4
lea rdx, str.RtlConvertSidToUnicodeString
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rbx + 0x1010]
lea rdx, str.RtlFreeUnicodeString
mov qword [rbx + 0x1038], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x1030], rax
add rsp, 0x20
pop rbx
ret

Function at 0x180001d40
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov edi, r8d
mov rsi, rdx
mov rbp, rcx
call qword [sym.imp.KERNEL32.dll_LoadResource]
test rax, rax
jne 0x180001d73
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
mov rcx, rax
mov qword [rsp + 0x30], rbx
call qword [sym.imp.KERNEL32.dll_LockResource]
mov rbx, rax
test rax, rax
je 0x180001db7
mov rdx, rsi
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov r11d, eax
add r11, rbx
and edi, 0xf
jbe 0x180001db2
cmp rbx, r11
jae 0x180001db7
add edi, 0xffffffff
movzx eax, word [rbx]
lea rbx, [rbx + rax*2 + 2]
jne 0x180001da0
cmp rbx, r11
jb 0x180001dbb
xor eax, eax
jmp 0x180001dc7
xor eax, eax
cmp word [rbx], ax
cmove rbx, rax
mov rax, rbx
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x180002560
Capabilities:
Get disk information

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x40
mov rax, qword [0x180067480]
xor rax, rsp
mov qword [rsp + 0x30], rax
mov rsi, rcx
mov ebx, 3
mov edi, 0x44
nop dword [rax + rax]
lea rdx, str._c:_
lea rcx, [rsp + 0x20]
mov r8d, edi
call qword [sym.imp.USER32.dll_wsprintfA]
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 4
jne 0x1800025bd
movzx eax, byte [rsp + 0x20]
mov byte [rbx + rsi], al
inc rbx
inc edi
cmp rbx, 0x1a
jl 0x180002590
xor eax, eax
mov rcx, qword [rsp + 0x30]
xor rcx, rsp
call fcn.180031f50
mov rbx, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret

Function at 0x1800025f0
Capabilities:
Check os version

Disassembly:
sub rsp, 0xd8
mov rax, qword [0x180067480]
xor rax, rsp
mov qword [rsp + 0xc0], rax
lea rcx, [rsp + 0x20]
xor edx, edx
mov r8d, 0x9c
call fcn.180031f80
lea rcx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x9c
call qword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x180002663
lea rcx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x94
call qword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x180002663
xor eax, eax
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.180031f50
add rsp, 0xd8
ret
mov eax, dword [rsp + 0x30]
cmp eax, 2
jne 0x180002689
mov eax, 1
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.180031f50
add rsp, 0xd8
ret
cmp eax, 1
jne 0x18000269e
cmp dword [rsp + 0x24], 4
jne 0x18000269e
mov eax, dword [rsp + 0x28]
cmp eax, 0xa
je 0x180002649
or eax, 0xffffffff
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.180031f50
add rsp, 0xd8
ret

Function at 0x180002790
Capabilities:
Acquire debug privileges

Disassembly:
sub rsp, 0x48
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x50]
mov edx, 0x28
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x1800027d4
lea r8, [rsp + 0x58]
lea rdx, str.SeDebugPrivilege
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov rcx, qword [rsp + 0x50]
test eax, eax
jne 0x1800027db
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
add rsp, 0x48
ret
mov rax, qword [rsp + 0x58]
lea r8, [rsp + 0x30]
xor edx, edx
mov qword [rsp + 0x34], rax
xor eax, eax
mov dword [rsp + 0x30], 1
mov qword [rsp + 0x28], rax
lea r9d, [rax + 0x10]
mov dword [rsp + 0x3c], 2
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov rcx, qword [rsp + 0x50]
test eax, eax
je 0x1800027ce
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
add rsp, 0x48
ret
Function at 0x180002a20
Capabilities:
Get common file path

Disassembly:
push rsi
sub rsp, 0x20
mov rsi, rcx
lea rcx, [0x180051d60]
mov qword [rsp + 0x38], 0
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
jne 0x180002a4a
add rsp, 0x20
pop rsi
ret
lea rdx, str.WTSGetActiveConsoleSessionId
mov rcx, rax
mov qword [rsp + 0x30], rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, rax
test rax, rax
je 0x180002a79
lea rcx, str.Wtsapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
jne 0x180002a86
xor eax, eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rsi
ret
lea rdx, str.WTSQueryUserToken
mov rcx, rax
mov qword [rsp + 0x40], rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rdi, rax
test rax, rax
je 0x180002ada
call rbx
lea rdx, [rsp + 0x38]
mov ecx, eax
call rdi
test eax, eax
je 0x180002ada
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_ImpersonateLoggedOnUser]
test eax, eax
je 0x180002ada
mov r9d, 1
mov rdx, rsi
xor ecx, ecx
lea r8d, [r9 + 1]
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
test eax, eax
jne 0x180002aec
mov rdi, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x30]
xor eax, eax
add rsp, 0x20
pop rsi
ret
call qword [sym.imp.ADVAPI32.dll_RevertToSelf]
mov rdi, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x30]
mov eax, 1
add rsp, 0x20
pop rsi
ret
Function at 0x180003440
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
test rdx, rdx
je 0x180003683
mov r11, rsp
push rbx
push rbp
sub rsp, 0x578
mov rax, qword [0x180067480]
xor rax, rsp
mov qword [rsp + 0x560], rax
mov rbp, rcx
or rcx, 0xffffffffffffffff
xor eax, eax
mov qword [r11 + 0x18], rsi
mov qword [r11 - 0x18], rdi
mov rdi, rdx
repne scasb al, byte [rdi]
mov rbx, rdx
not rcx
cmp byte [rcx + rdx - 2], 0x5c
je 0x18000349e
mov rdi, rdx
or rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
movzx eax, word [0x180051d48]
mov word [rdi - 1], ax
mov rcx, rdx
lea rdx, [rsp + 0x360]
sub rdx, rbx
nop dword [rax]
movzx eax, byte [rcx]
inc rcx
mov byte [rdx + rcx - 1], al
test al, al
jne 0x1800034b0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x360]
repne scasb al, byte [rdi]
mov eax, dword [0x180051e4c]
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x360]
mov dword [rdi - 1], eax
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x18000365a
cmp dword [0x18011c224], 0
jne 0x180003651
cmp byte [rsp + 0x4c], 0x2e
je 0x180003632
test byte [rsp + 0x20], 0x10
je 0x1800035eb
lea rcx, [rsp + 0x161]
xor edx, edx
mov r8d, 0x1ff
mov byte [rsp + 0x160], 0
call fcn.180031f80
lea rcx, [rsp + 0x160]
sub rcx, rbx
mov rdx, rbx
nop word [rax + rax]
movzx eax, byte [rdx]
inc rdx
mov byte [rcx + rdx - 1], al
test al, al
jne 0x180003550
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x160]
repne scasb al, byte [rdi]
xor ecx, ecx
lea rdx, [rsp + 0x4c]
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x180003580
lea rdx, [rsp + 0x160]
mov rcx, rbp
call fcn.180003440
lea rdx, [0x180051e48]
lea rcx, [rsp + 0x4c]
call fcn.18003a25c
test eax, eax
je 0x180003632
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x160]
repne scasb al, byte [rdi]
lea rax, [rsp + 0x160]
not rcx
cmp byte [rcx + rax - 2], 0x5c
jne 0x1800035db
mov byte [rcx + rax - 2], 0
lea rcx, [rsp + 0x160]
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
jmp 0x180003632
lea rcx, [rsp + 0x161]
xor edx, edx
mov r8d, 0x1ff
mov byte [rsp + 0x160], 0
call fcn.180031f80
lea r9, [rsp + 0x4c]
lea rdx, [0x180051e40]
lea rcx, [rsp + 0x160]
mov r8, rbx
call fcn.1800335dc
lea rcx, [rsp + 0x160]
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
lea rdx, [rsp + 0x20]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x180003651
cmp dword [0x18011c224], 0
je 0x180003504
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rsi, qword [rsp + 0x5a0]
mov rdi, qword [rsp + 0x570]
mov rcx, qword [rsp + 0x560]
xor rcx, rsp
call fcn.180031f50
add rsp, 0x578
pop rbp
pop rbx
repz ret
Function at 0x180003449
Capabilities:
Delete directory
Delete file
Enumerate files on windows

Disassembly:
test rdx, rdx
je 0x180003683
mov r11, rsp
push rbx
push rbp
sub rsp, 0x578
mov rax, qword [0x180067480]
xor rax, rsp
mov qword [rsp + 0x560], rax
mov rbp, rcx
or rcx, 0xffffffffffffffff
xor eax, eax
mov qword [r11 + 0x18], rsi
mov qword [r11 - 0x18], rdi
mov rdi, rdx
repne scasb al, byte [rdi]
mov rbx, rdx
not rcx
cmp byte [rcx + rdx - 2], 0x5c
je 0x18000349e
mov rdi, rdx
or rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
movzx eax, word [0x180051d48]
mov word [rdi - 1], ax
mov rcx, rdx
lea rdx, [rsp + 0x360]
sub rdx, rbx
nop dword [rax]
movzx eax, byte [rcx]
inc rcx
mov byte [rdx + rcx - 1], al
test al, al
jne 0x1800034b0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x360]
repne scasb al, byte [rdi]
mov eax, dword [0x180051e4c]
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x360]
mov dword [rdi - 1], eax
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x18000365a
cmp dword [0x18011c224], 0
jne 0x180003651
cmp byte [rsp + 0x4c], 0x2e
je 0x180003632
test byte [rsp + 0x20], 0x10
je 0x1800035eb
lea rcx, [rsp + 0x161]
xor edx, edx
mov r8d, 0x1ff
mov byte [rsp + 0x160], 0
call fcn.180031f80
lea rcx, [rsp + 0x160]
sub rcx, rbx
mov rdx, rbx
nop word [rax + rax]
movzx eax, byte [rdx]
inc rdx
mov byte [rcx + rdx - 1], al
test al, al
jne 0x180003550
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x160]
repne scasb al, byte [rdi]
xor ecx, ecx
lea rdx, [rsp + 0x4c]
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x180003580
lea rdx, [rsp + 0x160]
mov rcx, rbp
call fcn.180003440
lea rdx, [0x180051e48]
lea rcx, [rsp + 0x4c]
call fcn.18003a25c
test eax, eax
je 0x180003632
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x160]
repne scasb al, byte [rdi]
lea rax, [rsp + 0x160]
not rcx
cmp byte [rcx + rax - 2], 0x5c
jne 0x1800035db
mov byte [rcx + rax - 2], 0
lea rcx, [rsp + 0x160]
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
jmp 0x180003632
lea rcx, [rsp + 0x161]
xor edx, edx
mov r8d, 0x1ff
mov byte [rsp + 0x160], 0
call fcn.180031f80
lea r9, [rsp + 0x4c]
lea rdx, [0x180051e40]
lea rcx, [rsp + 0x160]
mov r8, rbx
call fcn.1800335dc
lea rcx, [rsp + 0x160]
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
lea rdx, [rsp + 0x20]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x180003651
cmp dword [0x18011c224], 0
je 0x180003504
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rsi, qword [rsp + 0x5a0]
mov rdi, qword [rsp + 0x570]
mov rcx, qword [rsp + 0x560]
xor rcx, rsp
call fcn.180031f50
add rsp, 0x578
pop rbp
pop rbx
repz ret