joyce8/EMBER2024-capa huggingface dataset:
Function at 0x18001fff0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
test r9d, 0xff000000
je 0x180020181
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x40
movss xmm3, dword [rsp + 0x70]
xorps xmm0, xmm0
comiss xmm3, xmm0
mov edi, r9d
mov rsi, r8
mov rbp, rdx
mov rbx, rcx
jbe 0x180020060
mov eax, dword [rsp + 0x78]
mov dword [rsp + 0x20], eax
call fcn.18001f9b0
mov r8d, dword [rbx + 0x80]
mov r9d, edi
mov rdx, qword [rbx + 0x88]
mov rcx, rbx
call fcn.18001f010
mov dword [rbx + 0x80], 0
jmp 0x18002016d
mov edx, 6
movaps xmmword [rsp + 0x30], xmm6
lea r8d, [rdx - 2]
call fcn.18001df60
movzx edx, word [rbx + 0x4c]
mov rax, qword [rbx + 0x38]
movss xmm1, dword [rsi]
movss xmm2, dword [rbp + 4]
movss xmm3, dword [rbp]
lea ecx, [rdx + 1]
movss xmm6, dword [rax + 4]
movss xmm5, dword [rax]
movss xmm4, dword [rsi + 4]
mov rax, qword [rbx + 0x58]
mov word [rax], dx
mov rax, qword [rbx + 0x58]
mov word [rax + 2], cx
lea ecx, [rdx + 2]
mov rax, qword [rbx + 0x58]
mov word [rax + 4], cx
mov rax, qword [rbx + 0x58]
mov word [rax + 6], dx
add dx, 3
mov rax, qword [rbx + 0x58]
mov word [rax + 8], cx
mov rax, qword [rbx + 0x58]
mov word [rax + 0xa], dx
movsd xmm0, qword [rbp]
mov rax, qword [rbx + 0x50]
movsd qword [rax], xmm0
mov rax, qword [rbx + 0x50]
movss dword [rax + 8], xmm5
movss dword [rax + 0xc], xmm6
mov rax, qword [rbx + 0x50]
mov dword [rax + 0x10], edi
mov rax, qword [rbx + 0x50]
movss dword [rax + 0x14], xmm1
movss dword [rax + 0x18], xmm2
mov rax, qword [rbx + 0x50]
movss dword [rax + 0x1c], xmm5
movss dword [rax + 0x20], xmm6
mov rax, qword [rbx + 0x50]
mov dword [rax + 0x24], edi
movsd xmm0, qword [rsi]
mov rax, qword [rbx + 0x50]
movsd qword [rax + 0x28], xmm0
mov rax, qword [rbx + 0x50]
movss dword [rax + 0x30], xmm5
movss dword [rax + 0x34], xmm6
mov rax, qword [rbx + 0x50]
mov dword [rax + 0x38], edi
mov rax, qword [rbx + 0x50]
movss dword [rax + 0x3c], xmm3
movss dword [rax + 0x40], xmm4
mov rax, qword [rbx + 0x50]
movss dword [rax + 0x44], xmm5
movss dword [rax + 0x48], xmm6
mov rax, qword [rbx + 0x50]
movaps xmm6, xmmword [rsp + 0x30]
mov dword [rax + 0x4c], edi
add qword [rbx + 0x50], 0x50
add dword [rbx + 0x4c], 4
add qword [rbx + 0x58], 0xc
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
Function at 0x180030ad0
Capabilities:
Get system information on windows

Disassembly:
push rsi
push rdi
push r14
push r15
sub rsp, 0x98
mov rax, qword [0x180045040]
xor rax, rsp
mov qword [rsp + 0x80], rax
mov rdi, rcx
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov r14, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x60]
cmp rdi, 0x40000000
jbe 0x180030b1f
lea rax, [rdi - 0x40000000]
cmp r14, rax
cmovb r14, rax
mov rsi, qword [0x180045cb0]
lea r15, [rdi + 0x40000000]
cmp rcx, r15
cmovbe r15, rcx
sub r15, 0xfff
test rsi, rsi
je 0x180030b5d
cmp rsi, r14
jb 0x180030b55
cmp rsi, r15
jae 0x180030b55
cmp qword [rsi + 8], 0
jne 0x180030d27
mov rsi, qword [rsi]
test rsi, rsi
jne 0x180030b40
mov qword [rsp + 0xc8], rbx
mov rbx, rdi
mov qword [rsp + 0xd0], rbp
mov qword [rsp + 0x90], r12
mov r12d, 0x40
cmp rdi, r14
jb 0x180030bf2
nop dword [rax]
nop word [rax + rax]
mov ebp, dword [rsp + 0x78]
mov rax, rbx
xor edx, edx
div rbp
sub rbx, rdx
sub rbx, rbp
cmp rbx, r14
jb 0x180030be9
nop word [rax + rax]
mov r8d, 0x30
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x180030be9
cmp dword [rsp + 0x40], 0x10000
je 0x180030c6b
mov rbx, qword [rsp + 0x28]
cmp rbx, rbp
jb 0x180030be9
sub rbx, rbp
cmp rbx, r14
jae 0x180030bb0
test rsi, rsi
jne 0x180030cd0
cmp rdi, r15
ja 0x180030d0f
nop dword [rax + rax]
mov ebp, dword [rsp + 0x78]
xor edx, edx
mov rax, rdi
mov ebx, ebp
div rbp
mov eax, ebp
sub rax, rdx
add rax, rdi
mov rdi, rax
cmp rax, r15
ja 0x180030d0f
mov r8d, 0x30
lea rdx, [rsp + 0x20]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x180030d0f
cmp dword [rsp + 0x40], 0x10000
je 0x180030ca1
xor edx, edx
lea edi, [rbp - 1]
add rdi, qword [rsp + 0x38]
add rdi, qword [rsp + 0x20]
mov rax, rdi
div rbx
sub rdi, rdx
cmp rdi, r15
jbe 0x180030c22
jmp 0x180030d0f
test rbx, rbx
je 0x180030be9
mov r9d, r12d
mov edx, 0x1000
mov r8d, 0x3000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x180030cd0
cmp rbx, r14
jae 0x180030b90
jmp 0x180030bf2
test rdi, rdi
je 0x180030d0f
mov r9d, r12d
mov edx, 0x1000
mov r8d, 0x3000
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x180030cd0
cmp rdi, r15
jbe 0x180030c00
jmp 0x180030d0f
xor edx, edx
lea rcx, [rsi + 0x40]
mov dword [rsi + 0x10], edx
nop dword [rax]
mov qword [rcx], rdx
mov rax, rcx
mov qword [rsi + 8], rcx
add r12, 0x40
add rcx, 0x40
mov rdx, rax
cmp r12, 0xfc0
jbe 0x180030ce0
mov rax, qword [0x180045cb0]
mov qword [rsi], rax
mov qword [0x180045cb0], rsi
mov r12, qword [rsp + 0x90]
mov rbp, qword [rsp + 0xd0]
mov rbx, qword [rsp + 0xc8]
mov rax, rsi
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.180033650
add rsp, 0x98
pop r15
pop r14
pop rdi
pop rsi
ret
Function at 0x1800316a0
Capabilities:
Enumerate threads
Suspend thread

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x50
mov rax, qword [0x180045040]
xor rax, rsp
mov qword [rsp + 0x40], rax
xor esi, esi
mov r14d, edx
mov rbx, rcx
mov qword [rcx], rsi
mov qword [rcx + 8], rsi
xor edx, edx
mov ebp, r8d
lea ecx, [rsi + 4]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x1800317cb
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_Thread32First]
test eax, eax
je 0x1800317c2
nop dword [rax]
cmp dword [rsp + 0x20], 0x10
jb 0x1800317a4
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rsp + 0x2c], eax
jne 0x1800317a4
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rsp + 0x28], eax
je 0x1800317a4
mov rdx, qword [rbx]
test rdx, rdx
jne 0x180031762
mov rcx, qword [0x180045ae8]
mov r8d, 0x200
mov dword [rbx + 8], 0x80
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rbx], rax
mov rdx, rax
test rax, rax
je 0x1800317c2
jmp 0x180031797
mov eax, dword [rbx + 8]
cmp dword [rbx + 0xc], eax
jb 0x180031797
mov rcx, qword [0x180045ae8]
lea r9d, [rax + rax]
mov r8, rdx
shl r9, 2
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rdx, rax
test rax, rax
je 0x1800317c2
mov eax, dword [rbx + 8]
add eax, eax
mov qword [rbx], rdx
mov dword [rbx + 8], eax
mov ecx, dword [rbx + 0xc]
mov eax, dword [rsp + 0x28]
mov dword [rdx + rcx*4], eax
inc dword [rbx + 0xc]
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_Thread32Next]
test eax, eax
jne 0x180031710
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp qword [rbx], rsi
je 0x180031823
cmp dword [rbx + 0xc], esi
jbe 0x180031823
nop word [rax + rax]
mov r8, qword [rbx]
xor edx, edx
mov eax, esi
lea ecx, [rdx + 0x5a]
mov r8d, dword [r8 + rax*4]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rdi, rax
test rax, rax
je 0x18003181c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SuspendThread]
mov r8d, ebp
mov edx, r14d
mov rcx, rdi
call fcn.1800314f0
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [rbx + 0xc]
jb 0x1800317e0
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.180033650
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
Function at 0x180031850
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x30
mov rax, qword [0x180045040]
xor rax, rsp
mov qword [rsp + 0x28], rax
mov eax, ecx
lea r9, [rsp + 0x20]
imul rbx, rax, 0x38
mov esi, edx
add rbx, qword [0x180045ca0]
mov r8, qword [rbx]
movzx eax, byte [rbx + 0x20]
and al, 1
movzx ecx, al
lea rdi, [r8 - 5]
cmove rdi, r8
mov r8d, 0x40
lea rbp, [rcx*2 + 5]
mov rcx, rdi
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1800318c3
mov eax, 0xa
jmp 0x180031956
test esi, esi
je 0x1800318e5
mov byte [rdi], 0xe9
mov eax, dword [rbx + 8]
sub eax, edi
sub eax, 5
mov dword [rdi + 1], eax
test byte [rbx + 0x20], 1
je 0x180031908
mov rax, qword [rbx]
mov word [rax], 0xf9eb
jmp 0x180031908
mov eax, dword [rbx + 0x18]
test byte [rbx + 0x20], 1
mov dword [rdi], eax
je 0x180031901
movzx eax, word [rbx + 0x1c]
mov word [rdi + 4], ax
movzx eax, byte [rbx + 0x1e]
mov byte [rdi + 6], al
jmp 0x180031908
movzx eax, byte [rbx + 0x1c]
mov byte [rdi + 4], al
mov r8d, dword [rsp + 0x20]
lea r9, [rsp + 0x20]
mov rdx, rbp
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov r8, rbp
mov rdx, rdi
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_FlushInstructionCache]
movzx ecx, sil
shl sil, 2
add cl, cl
xor cl, byte [rbx + 0x20]
and cl, 2
xor cl, byte [rbx + 0x20]
xor sil, cl
and sil, 4
xor sil, cl
mov byte [rbx + 0x20], sil
xor eax, eax
mov rcx, qword [rsp + 0x28]
xor rcx, rsp
call fcn.180033650
mov rbx, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret
Function at 0x180031980
Capabilities:
Resume thread

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
xor edi, edi
mov esi, ecx
mov ecx, dword [0x180045cac]
mov ebx, edi
test ecx, ecx
je 0x180031abb
mov rax, qword [0x180045ca0]
add rax, 0x20
nop
movzx edx, byte [rax]
shr edx, 1
and edx, 1
cmp edx, esi
jne 0x1800319d8
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x1800319b0
mov eax, edi
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
cmp ebx, 0xffffffff
je 0x180031abb
mov r8d, edi
lea rcx, [rsp + 0x20]
test esi, esi
mov edx, 0xffffffff
setne r8b
call fcn.1800316a0
mov r8d, dword [0x180045cac]
cmp ebx, r8d
jae 0x180031a48
nop word [rax + rax]
mov eax, ebx
imul rcx, rax, 0x38
mov rax, qword [0x180045ca0]
movzx edx, byte [rcx + rax + 0x20]
shr edx, 1
and edx, 1
cmp edx, esi
je 0x180031a41
mov edx, esi
mov ecx, ebx
call fcn.180031850
mov edi, eax
test eax, eax
jne 0x180031a48
mov r8d, dword [0x180045cac]
inc ebx
cmp ebx, r8d
jb 0x180031a10
cmp qword [rsp + 0x20], 0
je 0x180031abb
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x180031aa7
mov rbx, qword [rsp + 0x20]
mov qword [rsp + 0x40], rbp
mov ebp, eax
nop dword [rax]
nop dword [rax + rax]
mov r8d, dword [rbx]
xor edx, edx
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rsi, rax
test rax, rax
je 0x180031a98
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rbx, 4
sub rbp, 1
jne 0x180031a70
mov rbp, qword [rsp + 0x40]
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x180045ae8]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x48]
mov eax, edi
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
Function at 0x180031e30
Capabilities:
Resume thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r15
sub rsp, 0x30
xor r15d, r15d
mov esi, edx
mov ebx, r15d
xor eax, eax
mov rdi, rcx
mov ebp, 1
lock cmpxchg dword [0x180045ae0], ebp
je 0x180031e87
cmp rbx, 0x20
jae 0x180031e70
xor ecx, ecx
jmp 0x180031e72
mov ecx, ebp
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x180045ae0], ebp
jne 0x180031e66
cmp qword [0x180045ae8], r15
je 0x180031f81
test rdi, rdi
jne 0x180031ea7
mov ecx, esi
call fcn.180031980
mov ebp, eax
jmp 0x180031f86
mov ecx, dword [0x180045cac]
mov ebx, r15d
test ecx, ecx
je 0x180031ecf
mov r8, qword [0x180045ca0]
mov rax, r8
nop
cmp rdi, qword [rax]
je 0x180031ed9
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x180031ec0
mov ebp, 4
jmp 0x180031f86
cmp ebx, 0xffffffff
je 0x180031ecf
mov eax, ebx
imul rdx, rax, 0x38
movzx eax, byte [rdx + r8 + 0x20]
shr eax, 1
and eax, ebp
cmp eax, esi
je 0x180031f78
mov r8d, ebp
lea rcx, [rsp + 0x20]
mov edx, ebx
call fcn.1800316a0
mov edx, esi
mov ecx, ebx
call fcn.180031850
mov ebp, eax
cmp qword [rsp + 0x20], r15
je 0x180031f86
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x180031f62
mov rbx, qword [rsp + 0x20]
mov esi, eax
nop word [rax + rax]
mov r8d, dword [rbx]
xor edx, edx
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rdi, rax
test rax, rax
je 0x180031f58
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rbx, 4
sub rsi, 1
jne 0x180031f30
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x180045ae8]
call qword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x180031f86
neg esi
sbb ebp, ebp
add ebp, 6
jmp 0x180031f86
mov ebp, 2
xchg dword [0x180045ae0], r15d
mov rbx, qword [rsp + 0x40]
mov eax, ebp
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x58]
add rsp, 0x30
pop r15
ret
Function at 0x1800335c0
Capabilities:
Create thread

Disassembly:
push rbx
sub rsp, 0x30
mov rbx, rcx
test edx, edx
je 0x180033602
cmp edx, 1
jne 0x18003362c
call qword [sym.imp.KERNEL32.dll_DisableThreadLibraryCalls]
xor eax, eax
lea r8, [0x180033560]
mov qword [rsp + 0x28], rax
mov r9, rbx
xor edx, edx
mov dword [rsp + 0x20], eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov eax, 1
add rsp, 0x30
pop rbx
ret
cmp dword [0x180045bf0], 0
je 0x18003362c
call fcn.180031fb0
mov rcx, qword [0x180045be8]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor eax, eax
mov qword [0x180045be8], rax
mov dword [0x180045bf0], eax
mov eax, 1
add rsp, 0x30
pop rbx
ret
Function at 0x140caf108
Capabilities:
Decompress data using aplib

Disassembly:
call 0x140caf28f
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 0x140caf139
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140caf11f
add dl, dl
jne 0x140caf146
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140caf1a6
xor eax, eax
add dl, dl
jne 0x140caf155
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140caf25d
add dl, dl
jne 0x140caf166
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140caf173
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140caf180
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140caf18d
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x140caf19a
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x140caf12e
mov eax, 1
add dl, dl
jne 0x140caf1b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140caf1c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140caf1ab
sub eax, ebx
mov ebx, 1
jne 0x140caf1fc
mov ecx, 1
add dl, dl
jne 0x140caf1de
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140caf1eb
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140caf1d3
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140caf12e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x140caf218
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140caf225
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140caf20d
cmp eax, 0x7d00
jae 0x140caf24b
cmp eax, 0x500
jb 0x140caf246
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140caf12e
cmp eax, 0x7f
ja 0x140caf24e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140caf12e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x140caf282
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 0x140caf12e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x00473630]
xor edx, edx
mov dword [rax], 1
mov rax, qword [0x00473640]
mov dword [rax], 1
mov rax, qword [0x00473650]
mov dword [rax], 1
mov rax, qword [0x00473620]
mov dword [rax], 1
mov rax, qword [0x00473480]
cmp word [rax], 0x5a4d
je 0x4010d0
mov rax, qword [0x00473610]
mov dword [0x00486008], edx
mov eax, dword [rax]
test eax, eax
je 0x4010c2
mov ecx, 2
call sym.__set_app_type
mov rcx, 0xffffffffffffffff
call dbg._encode_pointer
mov rdx, qword [0x00473550]
mov qword [rdx], rax
mov rdx, qword [0x00473540]
mov qword [rdx], rax
mov rax, qword [0x004735d0]
mov edx, dword [rax]
mov rax, qword [sym.imp.msvcrt.dll__fmode]
mov rax, qword [rax]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x00472da0]
cmp dword [rax], 1
je 0x401120
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x401075
movsxd rcx, dword [rax + 0x3c]
add rax, rcx
cmp dword [rax], 0x4550
jne 0x401058
movzx ecx, word [rax + 0x18]
cmp cx, 0x10b
je 0x401133
cmp cx, 0x20b
jne 0x401058
cmp dword [rax + 0x84], 0xe
jbe 0x401058
mov ecx, dword [rax + 0xf8]
xor edx, edx
test ecx, ecx
setne dl
jmp 0x401058
lea rcx, [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401058
mov r8d, dword [rax + 0xe8]
xor edx, edx
test r8d, r8d
setne dl
jmp 0x401058

Function at 0x401a18
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
movsxd rax, dword [rcx + 0x3c]
xor ebp, ebp
lea rbx, [rsp + 0x38]
mov rsi, rcx
mov r12d, edx
mov edi, dword [rcx + rax + 0x88]
add rdi, rcx
mov eax, dword [rdi + 0x20]
mov r13d, dword [rdi + 0x24]
mov r14d, dword [rdi + 0x1c]
add rax, rcx
mov qword [rsp + 0x20], rax
lea rax, [rcx + r13]
add r14, rcx
mov qword [rsp + 0x28], rax
mov eax, dword [rdi + 0x18]
mov r15d, ebp
dec eax
cmp ebp, eax
ja 0x401b1a
mov rax, qword [rsp + 0x20]
test r12d, r12d
mov edx, dword [rax + r15*4]
lea r13, [rsi + rdx]
jne 0x401aae
mov rcx, rbx
call sym.GetGetProcAddressStr__
mov rdx, r13
mov rcx, rbx
call method.std::string.compare_char_const__const
jmp 0x401ac7
cmp r12d, 1
jne 0x401ad9
mov rcx, rbx
call sym.GetCreateThreadStr__
mov rdx, r13
mov rcx, rbx
call method.std::string.compare_char_const__const
mov r13d, eax
mov rcx, rbx
call fcn.00449570
test r13d, r13d
jne 0x401ae5
jmp 0x401b1a
cmp r12d, 4
je 0x401aec
cmp r12d, 6
je 0x401b03
inc ebp
jmp 0x401a62
mov rcx, rbx
call sym.GetVirtualAllocStr__
mov rdx, r13
mov rcx, rbx
call method.std::string.compare_char_const__const
jmp 0x401ac7
mov rcx, rbx
call sym.GetSleepStr__
mov rdx, r13
mov rcx, rbx
call method.std::string.compare_char_const__const
jmp 0x401ac7
mov rax, qword [rsp + 0x28]
movzx eax, word [rax + r15*2]
mov eax, dword [r14 + rax*4]
add rax, rsi
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
Function at 0x401b3c
Capabilities:
Persist via run registry key
Set registry value

Disassembly:
push rsi
push rbx
sub rsp, 0x48
xor r8d, r8d
mov r9d, 2
lea rdx, str.SoftwareMicrosoftWindowsCurrentVersionRun
lea rax, [rsp + 0x38]
mov rsi, rcx
xor ebx, ebx
mov rcx, 0xffffffff80000001
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401bb9
mov rax, qword [rsi]
xor r8d, r8d
mov rcx, qword [rsp + 0x38]
mov r9d, 1
mov rdx, qword [rax - 0x18]
mov qword [rsp + 0x20], rax
lea edx, [rdx + rdx + 2]
mov dword [rsp + 0x28], edx
lea rdx, str.1234
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
mov rcx, qword [rsp + 0x38]
mov rax, qword [sym.imp.ADVAPI32.dll_RegCloseKey]
je 0x401bb5
call rax
jmp 0x401bb9
mov bl, 1
call rax
mov al, bl
add rsp, 0x48
pop rbx
pop rsi
ret

Function at 0x40f130
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
movsxd rbp, dword [0x004860b4]
mov rbx, rcx
mov rsi, rdx
mov rdi, r8
test ebp, ebp
jle 0x40f24a
mov rax, qword [0x004860b8]
xor r9d, r9d
add rax, 8
mov r10, qword [rax]
cmp rbx, r10
jb 0x40f17e
mov rdx, qword [rax + 8]
mov r11d, dword [rdx + 8]
add r10, r11
cmp rbx, r10
jb 0x40f230
add r9d, 1
add rax, 0x18
cmp r9d, ebp
jne 0x40f162
mov rcx, rbx
call dbg.__mingw_GetSectionForAddress
test rax, rax
mov r12, rax
je 0x40f282
lea rbp, [rbp + rbp*2]
shl rbp, 3
mov r13, rbp
add r13, qword [0x004860b8]
mov qword [r13 + 0x10], rax
mov dword [r13], 0
call dbg._GetPEImageBase
mov edx, dword [r12 + 0xc]
mov r8d, 0x30
add rax, rdx
lea rdx, [rsp + 0x20]
mov qword [r13 + 8], rax
mov rax, qword [0x004860b8]
mov rcx, qword [rax + rbp + 8]
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x40f265
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x40f229
sub eax, 0x40
and eax, 0xffffffbf
je 0x40f229
mov r9, rbp
add r9, qword [0x004860b8]
mov r8d, 0x40
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x40f251
add dword [0x004860b4], 1
mov r8, rdi
mov rdx, rsi
mov rcx, rbx
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
jmp sym.memcpy
xor ebp, ebp
jmp 0x40f18b
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
mov rax, qword [0x004860b8]
mov edx, dword [r12 + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbp + 8]
call dbg.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call dbg.__report_error
nop
nop word cs:[rax + rax]

Function at 0x40fe60
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
je 0x40fe70
xor eax, eax
ret
jmp sym._ValidateImageBase.part.0
Function at 0x40fe80
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x40fec1
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov r8d, dword [rax + 0xc]
cmp r8, rdx
mov rcx, r8
ja 0x40feb8
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x40fec3
add rax, 0x28
cmp rax, r9
jne 0x40fea4
xor eax, eax
repz ret

Function at 0x40ff70
Capabilities:
Enumerate pe sections

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rbx, qword [0x00473480]
cmp word [rbx], 0x5a4d
je 0x40ff90
xor eax, eax
add rsp, 0x28
pop rbx
pop rsi
ret
mov rsi, rcx
mov rcx, rbx
call sym._ValidateImageBase.part.0
test eax, eax
je 0x40ff84
sub rsi, rbx
mov rcx, rbx
mov rdx, rsi
add rsp, 0x28
pop rbx
pop rsi
jmp dbg._FindPESection

Function at 0x4101e0
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00486a00]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x004869e0]
test rbx, rbx
je 0x410234
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x41022b
test rsi, rsi
je 0x41022b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x410210
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x00486a00]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax