joyce8/EMBER2024-capa huggingface dataset:
Function at 0x18004eff0
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 [0x18006a040]
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 0x18004f11b
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_Thread32First]
test eax, eax
je 0x18004f112
nop dword [rax]
cmp dword [rsp + 0x20], 0x10
jb 0x18004f0f4
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rsp + 0x2c], eax
jne 0x18004f0f4
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rsp + 0x28], eax
je 0x18004f0f4
mov rdx, qword [rbx]
test rdx, rdx
jne 0x18004f0b2
mov rcx, qword [0x18006adc0]
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 0x18004f112
jmp 0x18004f0e7
mov eax, dword [rbx + 8]
cmp dword [rbx + 0xc], eax
jb 0x18004f0e7
mov rcx, qword [0x18006adc0]
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 0x18004f112
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 0x18004f060
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp qword [rbx], rsi
je 0x18004f173
cmp dword [rbx + 0xc], esi
jbe 0x18004f173
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 0x18004f16c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SuspendThread]
mov r8d, ebp
mov edx, r14d
mov rcx, rdi
call fcn.18004ee40
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [rbx + 0xc]
jb 0x18004f130
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.180055b80
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 0x18004f1a0
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 [0x18006a040]
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 [0x18006c5e0]
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 0x18004f213
mov eax, 0xa
jmp 0x18004f2a6
test esi, esi
je 0x18004f235
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 0x18004f258
mov rax, qword [rbx]
mov word [rax], 0xf9eb
jmp 0x18004f258
mov eax, dword [rbx + 0x18]
test byte [rbx + 0x20], 1
mov dword [rdi], eax
je 0x18004f251
movzx eax, word [rbx + 0x1c]
mov word [rdi + 4], ax
movzx eax, byte [rbx + 0x1e]
mov byte [rdi + 6], al
jmp 0x18004f258
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.180055b80
mov rbx, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret
Function at 0x18004f2d0
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 [0x18006c5ec]
mov ebx, edi
test ecx, ecx
je 0x18004f40b
mov rax, qword [0x18006c5e0]
add rax, 0x20
nop
movzx edx, byte [rax]
shr edx, 1
and edx, 1
cmp edx, esi
jne 0x18004f328
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x18004f300
mov eax, edi
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
cmp ebx, 0xffffffff
je 0x18004f40b
mov r8d, edi
lea rcx, [rsp + 0x20]
test esi, esi
mov edx, 0xffffffff
setne r8b
call fcn.18004eff0
mov r8d, dword [0x18006c5ec]
cmp ebx, r8d
jae 0x18004f398
nop word [rax + rax]
mov eax, ebx
imul rcx, rax, 0x38
mov rax, qword [0x18006c5e0]
movzx edx, byte [rcx + rax + 0x20]
shr edx, 1
and edx, 1
cmp edx, esi
je 0x18004f391
mov edx, esi
mov ecx, ebx
call fcn.18004f1a0
mov edi, eax
test eax, eax
jne 0x18004f398
mov r8d, dword [0x18006c5ec]
inc ebx
cmp ebx, r8d
jb 0x18004f360
cmp qword [rsp + 0x20], 0
je 0x18004f40b
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x18004f3f7
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 0x18004f3e8
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 0x18004f3c0
mov rbp, qword [rsp + 0x40]
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x18006adc0]
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 0x18004f780
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 [0x18006adb8], ebp
je 0x18004f7d7
cmp rbx, 0x20
jae 0x18004f7c0
xor ecx, ecx
jmp 0x18004f7c2
mov ecx, ebp
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x18006adb8], ebp
jne 0x18004f7b6
cmp qword [0x18006adc0], r15
je 0x18004f8d1
test rdi, rdi
jne 0x18004f7f7
mov ecx, esi
call fcn.18004f2d0
mov ebp, eax
jmp 0x18004f8d6
mov ecx, dword [0x18006c5ec]
mov ebx, r15d
test ecx, ecx
je 0x18004f81f
mov r8, qword [0x18006c5e0]
mov rax, r8
nop
cmp rdi, qword [rax]
je 0x18004f829
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x18004f810
mov ebp, 4
jmp 0x18004f8d6
cmp ebx, 0xffffffff
je 0x18004f81f
mov eax, ebx
imul rdx, rax, 0x38
movzx eax, byte [rdx + r8 + 0x20]
shr eax, 1
and eax, ebp
cmp eax, esi
je 0x18004f8c8
mov r8d, ebp
lea rcx, [rsp + 0x20]
mov edx, ebx
call fcn.18004eff0
mov edx, esi
mov ecx, ebx
call fcn.18004f1a0
mov ebp, eax
cmp qword [rsp + 0x20], r15
je 0x18004f8d6
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x18004f8b2
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 0x18004f8a8
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 0x18004f880
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x18006adc0]
call qword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x18004f8d6
neg esi
sbb ebp, ebp
add ebp, 6
jmp 0x18004f8d6
mov ebp, 2
xchg dword [0x18006adb8], 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 0x180050110
Capabilities:
Reference http user-agent string

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 8], rcx
push rdi
sub rsp, 0x70
lea rdi, [0x18006c320]
mov qword [rsp + 0x80], rdi
xor ebx, ebx
mov qword [0x18006c320], rbx
mov qword [0x18006c328], rbx
lea ecx, [rbx + 0x60]
call fcn.180055f3c
mov qword [rax], rax
mov qword [rax + 8], rax
mov qword [rax + 0x10], rax
mov word [rax + 0x18], 0x101
mov qword [0x18006c320], rax
xorps xmm0, xmm0
movups xmmword [0x18006c330], xmm0
mov qword [0x18006c340], rbx
mov qword [0x18006c348], rbx
lea r8d, [rbx + 0x4d]
lea rdx, str.Mozilla_5.0__Windows_NT_6.1__Win64__x64__rv:89.0__Gecko_20100101_Firefox_89.0
lea rcx, [0x18006c330]
call fcn.180009be0
nop
xorps xmm0, xmm0
movups xmmword [0x18006c350], xmm0
mov qword [0x18006c360], rbx
mov qword [0x18006c368], 0xf
mov byte [0x18006c350], bl
movups xmmword [0x18006c370], xmm0
mov qword [0x18006c380], rbx
mov qword [0x18006c388], 0xf
mov byte [0x18006c370], bl
movups xmmword [0x18006c390], xmm0
mov qword [0x18006c3a0], rbx
mov qword [0x18006c3a8], 0xf
mov byte [0x18006c390], bl
movups xmmword [0x18006c3b0], xmm0
mov qword [0x18006c3c0], rbx
mov qword [0x18006c3c8], 0xf
mov byte [0x18006c3b0], bl
movups xmmword [0x18006c3d0], xmm0
mov qword [0x18006c3e0], rbx
mov qword [0x18006c3e8], 0xf
mov byte [0x18006c3d0], bl
movups xmmword [0x18006c3f0], xmm0
mov qword [0x18006c400], rbx
mov qword [0x18006c408], rbx
lea r8d, [rbx + 3]
lea rdx, [0x18005fb60]
lea rcx, [0x18006c3f0]
call fcn.180009be0
nop
xorps xmm0, xmm0
movups xmmword [0x18006c410], xmm0
mov qword [0x18006c420], rbx
mov qword [0x18006c428], 0xf
mov byte [0x18006c410], bl
movups xmmword [0x18006c430], xmm0
mov qword [0x18006c440], rbx
mov qword [0x18006c448], rbx
lea r8d, [rbx + 0xf]
lea rdx, str.www.example.com
lea rcx, [0x18006c430]
call fcn.180009be0
nop
xorps xmm0, xmm0
movups xmmword [rsp + 0x30], xmm0
xorps xmm1, xmm1
movdqa xmmword [rsp + 0x40], xmm1
xor r8d, r8d
lea rdx, [0x18005da83]
lea rcx, [rsp + 0x30]
call fcn.180009be0
nop
xorps xmm0, xmm0
movups xmmword [rsp + 0x50], xmm0
xorps xmm1, xmm1
movdqa xmmword [rsp + 0x60], xmm1
xor r8d, r8d
lea rdx, [0x18005da83]
lea rcx, [rsp + 0x50]
call fcn.180009be0
nop
lea rcx, [0x18006c450]
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x28], rax
lea rdx, [rsp + 0x20]
call fcn.1800085e0
nop
lea r9, [fcn.180005b50]
lea edx, [rbx + 0x40]
lea r8d, [rbx + 1]
lea rcx, [rsp + 0x30]
call fcn.180055f78
mov qword [0x18006c460], rbx
mov rax, rdi
mov rbx, qword [rsp + 0x90]
add rsp, 0x70
pop rdi
ret
Function at 0x2fc554df0
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
sub rsp, 0x38
lea rbp, [rsp + 0x30]
mov qword [rbp + 0x20], rcx
mov qword [rbp + 0x28], rdx
mov qword [rbp + 0x30], r8
mov qword [rbp + 0x38], r9
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov r9, rax
mov r8d, 0x1b
mov edx, 1
lea rax, str.Mingw_w64_runtime_failure:_n
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
mov rbx, qword [rbp - 8]
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov rcx, rax
mov rax, qword [rbp + 0x20]
mov r8, rbx
mov rdx, rax
call fcn.2fc555ed0
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop

Function at 0x2fc5557f2
Capabilities:
Get thread local storage value

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov eax, dword [0x2fc578108]
test eax, eax
je 0x2fc55588a
lea rax, [0x2fc5780e0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
mov rax, qword [0x2fc578110]
mov qword [rbp - 8], rax
jmp 0x2fc55586e
mov rax, qword [rbp - 8]
mov eax, dword [rax]
mov ecx, eax
mov rax, qword [sym.imp.KERNEL32.dll_TlsGetValue]
call rax
mov qword [rbp - 0x10], rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
test eax, eax
jne 0x2fc555862
cmp qword [rbp - 0x10], 0
je 0x2fc555862
mov rax, qword [rbp - 8]
mov rdx, qword [rax + 8]
mov rax, qword [rbp - 0x10]
mov rcx, rax
call rdx
mov rax, qword [rbp - 8]
mov rax, qword [rax + 0x10]
mov qword [rbp - 8], rax
cmp qword [rbp - 8], 0
jne 0x2fc555828
lea rax, [0x2fc5780e0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
jmp 0x2fc55588b
nop
add rsp, 0x30
pop rbp
ret

Function at 0x2fc555990
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov rax, qword [rbp + 0x10]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x2fc5559b8
mov eax, 0
jmp 0x2fc555a06
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x2fc5559e1
mov eax, 0
jmp 0x2fc555a06
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
cmp ax, 0x20b
je 0x2fc555a01
mov eax, 0
jmp 0x2fc555a06
mov eax, 1
add rsp, 0x20
pop rbp
ret
Function at 0x2fc555a0c
Capabilities:
Enumerate pe sections

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov rax, qword [rbp + 0x10]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp + 0x10]
add rax, rdx
mov qword [rbp - 0x18], rax
mov dword [rbp - 0xc], 0
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 0x14]
movzx edx, ax
mov rax, qword [rbp - 0x18]
add rax, rdx
add rax, 0x18
mov qword [rbp - 8], rax
jmp 0x2fc555a8a
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0xc]
mov eax, eax
cmp qword [rbp + 0x18], rax
jb 0x2fc555a81
mov rax, qword [rbp - 8]
mov edx, dword [rax + 0xc]
mov rax, qword [rbp - 8]
mov eax, dword [rax + 8]
add eax, edx
mov eax, eax
cmp qword [rbp + 0x18], rax
jae 0x2fc555a81
mov rax, qword [rbp - 8]
jmp 0x2fc555a9f
add dword [rbp - 0xc], 1
add qword [rbp - 8], 0x28
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 6]
movzx eax, ax
cmp dword [rbp - 0xc], eax
jb 0x2fc555a54
mov eax, 0
add rsp, 0x20
pop rbp
ret
Function at 0x140001480
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov rax, qword [0x14003a3c0]
mov dword [rax], 1
mov rax, qword [0x14003a3d0]
mov dword [rax], 1
mov rax, qword [0x14003a3e0]
mov dword [rax], 1
mov rax, qword [0x14003a3b0]
mov dword [rax], 1
mov rax, qword [0x14003a270]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x1400014de
mov eax, 0
jmp 0x14000158b
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x14000150a
mov eax, 0
jmp 0x14000158b
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
movzx eax, ax
cmp eax, 0x10b
je 0x140001530
cmp eax, 0x20b
je 0x140001557
jmp 0x140001586
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0x5c]
cmp eax, 0xe
ja 0x140001543
mov eax, 0
jmp 0x14000158b
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0xd0]
test eax, eax
setne al
movzx eax, al
jmp 0x14000158b
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x20], rax
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0x6c]
cmp eax, 0xe
ja 0x140001572
mov eax, 0
jmp 0x14000158b
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0xe0]
test eax, eax
setne al
movzx eax, al
jmp 0x14000158b
mov eax, 0
add rsp, 0x20
pop rbp
ret

Function at 0x1400064c0
Capabilities:
Read file on windows

Disassembly:
push r13
push r12
push rbx
sub rsp, 0x20
mov r13, rcx
mov rcx, rdx
mov edx, 1
mov rbx, r8
mov r9, r13
call sym.fread
mov r12, rax
cmp rbx, rax
je 0x1400064f3
mov rcx, r13
call sym.ferror
test eax, eax
jne 0x140006500
mov rax, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
ret
mov rcx, r13
call sym.checkErr__stdZsyncio_u162.part.0
mov rax, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
ret
Function at 0x140006550
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
lea rax, [0x1400373c0]
mov r14, rcx
mov r13, rdx
lea rcx, [rsp + 0x20]
mov edx, 0xfa0
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], 0
call sym.mnewString
mov rax, qword [rsp + 0x20]
mov qword [rsp + 0x40], rax
mov rbx, rax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x48], rax
test rbx, rbx
jle 0x1400066c8
mov rcx, qword [0x14003a250]
lea rdi, [rsp + 0x30]
movabs r15, 0x7fffffffffffffff
movabs rbp, 0x8000000000000000
call sym.__emutls_get_address
mov rsi, rax
nop dword [rax]
mov rax, qword [rsp + 0x48]
mov r9, r13
mov r8d, 0xfa0
mov edx, 1
lea rcx, [rax + 8]
call sym.fread
mov r12, rax
cmp rax, 0xfa0
je 0x140006660
mov rcx, r13
call sym.ferror
test eax, eax
je 0x140006623
mov rcx, r13
call sym.checkErr__stdZsyncio_u162.part.0
cmp byte [rsi], 0
je 0x140006710
mov rcx, qword [rsp + 0x48]
test rcx, rcx
je 0x140006640
test byte [rcx + 7], 0x40
je 0x140006700
movdqa xmm0, xmmword [rsp + 0x30]
mov rax, r14
movups xmmword [r14], xmm0
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
cmp byte [rsi], 0
jne 0x14000662c
mov rdx, qword [rsp + 0x40]
mov rcx, rdi
call sym.prepareAdd
mov rbx, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
test rbx, rbx
jle 0x1400066c8
mov r8, rbx
add r8, 1
jo 0x1400066dd
test r8, r8
js 0x1400066e8
mov rax, qword [rsp + 0x30]
mov rcx, qword [rsp + 0x38]
add rdx, 8
lea rcx, [rcx + rax + 8]
call sym.memcpy
add rbx, qword [rsp + 0x30]
jo 0x1400066dd
mov qword [rsp + 0x30], rbx
mov rbx, qword [rsp + 0x40]
test rbx, rbx
jg 0x1400065e8
nop dword [rax]
xor ecx, ecx
lea rdx, [rbx - 1]
call sym.raiseIndexError2
mov rcx, qword [rsp + 0x48]
jmp 0x140006631
call sym.raiseOverflow
jmp 0x1400066b3
mov r8, r15
xor edx, edx
mov rcx, rbp
call sym.raiseRangeErrorI
jmp 0x1400066b3
call sym.deallocShared
jmp 0x140006640
test r12, r12
js 0x140006788
lea rcx, [rsp + 0x40]
mov rdx, r12
call sym.setLengthStrV2
mov rdx, qword [rsp + 0x40]
lea rcx, [rsp + 0x30]
call sym.prepareAdd
mov rbx, qword [rsp + 0x40]
mov rcx, qword [rsp + 0x48]
test rbx, rbx
jle 0x140006631
mov r8, rbx
add r8, 1
jo 0x1400067cb
test r8, r8
js 0x1400067a6
mov rdx, qword [rsp + 0x38]
mov rax, qword [rsp + 0x30]
lea r9, [rdx + rax + 8]
lea rdx, [rcx + 8]
mov rcx, r9
call sym.memcpy
add rbx, qword [rsp + 0x30]
jo 0x1400067cb
mov qword [rsp + 0x30], rbx
mov rcx, qword [rsp + 0x48]
jmp 0x140006631
movabs r8, 0x7fffffffffffffff
mov rcx, r12
xor edx, edx
call sym.raiseRangeErrorI
mov rcx, qword [rsp + 0x48]
jmp 0x140006631
movabs rcx, 0x8000000000000000
xor edx, edx
movabs r8, 0x7fffffffffffffff
call sym.raiseRangeErrorI
mov rcx, qword [rsp + 0x48]
jmp 0x140006631
call sym.raiseOverflow
jmp 0x14000662c
Function at 0x1400067e0
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rdi
push rsi
push rbx
sub rsp, 0x40
mov r14, rcx
mov r13, rdx
mov r12, r8
test r8, r8
js 0x1400068d0
lea rdi, [rsp + 0x20]
mov rdx, r8
mov rcx, rdi
call sym.mnewString
mov rax, qword [rsp + 0x20]
mov qword [rsp + 0x30], rax
mov rdx, rax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
test rdx, rdx
jle 0x140006920
mov rax, qword [rsp + 0x38]
mov r9, r13
mov r8, r12
mov edx, 1
lea rcx, [rax + 8]
call sym.fread
mov r15, rax
cmp r12, rax
je 0x140006862
mov rcx, r13
call sym.ferror
test eax, eax
jne 0x1400068f0
mov rcx, qword [0x14003a250]
call sym.__emutls_get_address
cmp byte [rax], 0
mov rbx, rax
jne 0x1400068ae
mov rcx, r13
call sym.fgetc
mov rdx, r13
mov ecx, eax
mov esi, eax
call sym.ungetc
cmp byte [rbx], 0
jne 0x1400068ae
test esi, esi
jns 0x140006930
cmp r12, r15
jle 0x1400068ae
test r15, r15
js 0x140006900
lea rcx, [rsp + 0x30]
mov rdx, r15
call sym.setLengthStrV2
movdqa xmm0, xmmword [rsp + 0x30]
mov rax, r14
movups xmmword [r14], xmm0
add rsp, 0x40
pop rbx
pop rsi
pop rdi
pop r12
pop r13
pop r14
pop r15
ret
movabs r8, 0x7fffffffffffffff
xor edx, edx
mov rcx, r12
call sym.raiseRangeErrorI
jmp 0x1400068ae
mov rcx, r13
call sym.checkErr__stdZsyncio_u162.part.0
jmp 0x140006862
movabs r8, 0x7fffffffffffffff
xor edx, edx
mov rcx, r15
call sym.raiseRangeErrorI
jmp 0x1400068ae
sub rdx, 1
xor ecx, ecx
call sym.raiseIndexError2
jmp 0x1400068ae
mov rdx, r13
mov rcx, rdi
call sym.readAllBuffer__stdZsyncio_u511
cmp byte [rbx], 0
mov rsi, qword [rsp + 0x20]
mov r12, qword [rsp + 0x28]
jne 0x14000698f
lea rcx, [rsp + 0x30]
mov rdx, rsi
call sym.prepareAdd
test rsi, rsi
jle 0x14000698f
mov r8, rsi
add r8, 1
jo 0x1400069b1
test r8, r8
js 0x1400069c0
mov rdx, qword [rsp + 0x38]
mov rax, qword [rsp + 0x30]
lea rcx, [rdx + rax + 8]
lea rdx, [r12 + 8]
call sym.memcpy
add rsi, qword [rsp + 0x30]
jo 0x1400069b1
mov qword [rsp + 0x30], rsi
test r12, r12
je 0x1400068ae
test byte [r12 + 7], 0x40
jne 0x1400068ae
mov rcx, r12
call sym.deallocShared
jmp 0x1400068ae
call sym.raiseOverflow
jmp 0x14000698f
movabs r8, 0x7fffffffffffffff
xor edx, edx
movabs rcx, 0x8000000000000000
call sym.raiseRangeErrorI
jmp 0x14000698f

Function at 0x140006ed0
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
sub rsp, 0x28
mov r12, rcx
mov rcx, rdx
mov r13, rdx
call sym.strlen
mov rcx, r13
mov r9, r12
mov edx, 1
mov r8, rax
call sym.fwrite
mov rcx, r12
add rsp, 0x28
pop r12
pop r13
jmp sym.fflush

Function at 0x14000de20
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
push rbx
sub rsp, 0x20
mov rbx, rdx
mov r13, rcx
mov ecx, 2
call qword [sym.__acrt_iob_func]
mov rcx, r13
mov r8, rbx
mov edx, 1
mov r12, rax
mov r9, rax
call sym.fwrite
mov rcx, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
jmp sym.fflush
Function at 0x14000de70
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
push rbx
sub rsp, 0x40
mov rax, qword [0x140043170]
mov r12, rcx
mov rbx, rdx
test rax, rax
je 0x14000df20
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x38], 0
test rcx, rcx
je 0x14000df00
call sym.strlen
lea r13, [rsp + 0x20]
mov rdx, r12
mov rcx, r13
mov r8, rax
call sym.toNimStr
mov r12, qword [rsp + 0x28]
mov rcx, r13
call qword [0x140043170]
test r12, r12
je 0x14000ded9
test byte [r12 + 7], 0x40
je 0x14000df58
lea rcx, [0x140036380]
call sym.__emutls_get_address
cmp byte [rax], 0
jne 0x14000df78
add rsp, 0x40
pop rbx
pop r12
pop r13
ret
mov qword [rsp + 0x20], 0
lea rcx, [rsp + 0x20]
mov qword [rsp + 0x28], 0
call rax
jmp 0x14000ded9
mov ecx, 2
call qword [sym.__acrt_iob_func]
mov rcx, r12
mov r8, rbx
mov edx, 1
mov r13, rax
mov r9, rax
call sym.fwrite
mov rcx, r13
add rsp, 0x40
pop rbx
pop r12
pop r13
jmp sym.fflush
lea rcx, [0x1400363a0]
call sym.__emutls_get_address
mov rdx, r12
mov rcx, rax
call sym.rawDealloc__system_u6951
jmp 0x14000ded9
mov byte [rax], 0
lea rcx, [0x1400362c0]
call sym.__emutls_get_address
xor r8d, r8d
mov rcx, rax
mov rax, qword [rax]
mov rdx, qword [rax + 0x38]
add rsp, 0x40
pop rbx
pop r12
pop r13
jmp sym.eqcopy___stdZtypedthreads_u169

Function at 0x14000f570
Capabilities:
Write file on windows

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x30
lea r13, [0x140043140]
mov rsi, rdx
mov rbx, rcx
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
test rsi, rsi
jle 0x14000f5ff
lea rcx, [0x140036380]
xor r14d, r14d
lea r12, [rsp + 0x20]
call sym.__emutls_get_address
mov rbp, qword [sym.__acrt_iob_func]
mov rdi, rax
jmp 0x14000f5cd
add r14, 1
add rbx, 0x10
cmp rsi, r14
je 0x14000f606
mov ecx, 1
call rbp
movdqu xmm0, xmmword [rbx]
xor r8d, r8d
mov rdx, r12
mov rcx, rax
movaps xmmword [rsp + 0x20], xmm0
call sym.writeWindows__system_u8909
cmp byte [rdi], 0
je 0x14000f5c0
add rsp, 0x30
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov rbp, qword [sym.__acrt_iob_func]
mov ecx, 1
call rbp
mov r8d, 1
mov edx, 1
lea rcx, [0x1400374e1]
mov r9, rax
call sym.fwrite
mov ecx, 1
call rbp
mov rcx, rax
call sym.fflush
mov rcx, r13
add rsp, 0x30
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x14001a030
Capabilities:
Execute command

Disassembly:
push rbx
sub rsp, 0x20
lea rdx, [0x140037fbe]
mov rax, qword [rcx + 8]
add rax, 8
cmp qword [rcx], 0
cmovne rdx, rax
mov rcx, rdx
call sym.system
mov rcx, qword [0x14003a250]
movsxd rbx, eax
call sym.__emutls_get_address
cmp byte [rax], 0
mov eax, 0
cmove rax, rbx
add rsp, 0x20
pop rbx
ret