joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4a0a50
Capabilities:
Query or enumerate registry value

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x258
cmp byte [rcx + 0x1d0], 0
mov r13, rcx
mov r12, rdx
je 0x4a0a90
xor eax, eax
add rsp, 0x258
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
lea rax, str.CurrentJoystickSettings
mov edx, 0x100
mov rsi, qword [sym.imp.msvcrt.dll__snprintf]
lea rbx, [rsp + 0x50]
mov qword [rsp + 0x28], rax
lea rbp, [rsp + 0x48]
lea rax, [rcx + 0x70]
mov rcx, rbx
lea r9, str.SystemCurrentControlSetControlMediaResourcesJoystick
mov qword [rsp + 0x20], rax
lea r8, str._s_s_s
call rsi
xor r8d, r8d
mov qword [rsp + 0x20], rbp
mov r9d, 1
mov rdx, rbx
mov rcx, 0xffffffff80000002
mov rdi, qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
call rdi
test eax, eax
jne 0x4a0a72
mov eax, dword [r13 + 0x1c8]
lea rdx, str.OEMName
mov rcx, rbx
mov dword [rsp + 0x44], 0x100
mov qword [rsp + 0x20], rdx
lea r15, [rsp + 0x44]
mov edx, 0x100
lea r8, str.Joystick_d_s
lea r9d, [rax + 1]
call rsi
lea r10, [rsp + 0x150]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], r10
mov rdx, rbx
mov rcx, qword [rsp + 0x48]
mov qword [rsp + 0x38], r10
mov r14, qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov qword [rsp + 0x28], r15
call r14
mov rcx, qword [rsp + 0x48]
mov dword [rsp + 0x34], eax
mov r13, qword [sym.imp.ADVAPI32.dll_RegCloseKey]
call r13
mov eax, dword [rsp + 0x34]
test eax, eax
jne 0x4a0a72
mov r10, qword [rsp + 0x38]
lea r9, str.SystemCurrentControlSetControlMediaPropertiesPrivatePropertiesJoystickOEM
mov edx, 0x100
mov rcx, rbx
lea r8, str._s_s
mov qword [rsp + 0x20], r10
call rsi
xor r8d, r8d
mov qword [rsp + 0x20], rbp
mov r9d, 1
mov rdx, rbx
mov rcx, 0xffffffff80000002
call rdi
test eax, eax
jne 0x4a0a72
xor r9d, r9d
xor r8d, r8d
mov rcx, qword [rsp + 0x48]
mov qword [rsp + 0x28], r15
lea rdx, str.OEMName
mov dword [rsp + 0x44], pe_nt_image_headers64
mov qword [rsp + 0x20], r12
call r14
mov rcx, qword [rsp + 0x48]
mov ebx, eax
call r13
xor eax, eax
test ebx, ebx
sete al
jmp 0x4a0a74

Function at 0x4a1a10
Capabilities:
Log keystrokes via polling

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov ecx, 0xa0
mov rsi, qword [sym.imp.USER32.dll_GetKeyState]
mov ebx, 1
call rsi
test ax, ax
js 0x4a1a3b
mov ecx, 0xa1
call rsi
movsx ebx, ax
shr ebx, 0x1f
mov ecx, 0xa2
call rsi
test ax, ax
jns 0x4a1a62
mov ecx, 0xa4
or ebx, 2
call rsi
test ax, ax
jns 0x4a1a80
or ebx, 4
mov eax, ebx
add rsp, 0x28
pop rbx
pop rsi
ret
mov ecx, 0xa3
call rsi
mov edx, ebx
mov ecx, 0xa4
or edx, 2
test ax, ax
cmovs ebx, edx
call rsi
test ax, ax
js 0x4a1a56
mov ecx, 0xa5
call rsi
mov edx, ebx
or edx, 4
test ax, ax
cmovs ebx, edx
mov eax, ebx
add rsp, 0x28
pop rbx
pop rsi
ret
Function at 0x4a1ad0
Capabilities:
Write file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rbx, qword [0x005d2990]
mov qword [rsp + 0x68], rdx
mov rsi, rcx
mov qword [rsp + 0x70], r8
mov qword [rsp + 0x78], r9
cmp qword [rbx + 0xd0], 0
je 0x4a1b15
lea rdx, [rsp + 0x68]
mov qword [rsp + 0x28], rdx
call qword [rbx + 0xd0]
nop
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rax, [rsp + 0x68]
mov ecx, 2
mov rdi, qword [fcn.004c4ca0]
mov qword [rsp + 0x28], rax
call rdi
mov r8d, 9
mov edx, 1
lea rcx, str.freeglut
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbp, qword [rbx + 0xa0]
test rbp, rbp
je 0x4a1b6c
mov ecx, 2
call rdi
lea rdx, str.__s_:
mov r8, rbp
mov rcx, rax
call sub.msvcrt.dll_fprintf
mov rbp, qword [rsp + 0x28]
mov ecx, 2
call rdi
mov rdx, rsi
mov rcx, rax
mov r8, rbp
call sub.msvcrt.dll_vfprintf
mov ecx, 2
call rdi
mov ecx, 0xa
mov rdx, rax
call sub.msvcrt.dll_fputc
cmp byte [rbx + 0x1c], 0
jne 0x4a1baa
mov ecx, 1
call sub.msvcrt.dll_exit
call fcn.0049f720
jmp 0x4a1ba0

Function at 0x4a1bc0
Capabilities:
Write file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
mov rbx, qword [0x005d2990]
mov qword [rsp + 0x58], rdx
mov rsi, rcx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
cmp qword [rbx + 0xd8], 0
je 0x4a1c03
lea rdx, [rsp + 0x58]
mov qword [rsp + 0x28], rdx
call qword [rbx + 0xd8]
nop
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
lea rax, [rsp + 0x58]
mov ecx, 2
mov rdi, qword [fcn.004c4ca0]
mov qword [rsp + 0x28], rax
call rdi
mov r8d, 9
mov edx, 1
lea rcx, str.freeglut
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rbx + 0xa0]
test rbx, rbx
je 0x4a1c5a
mov ecx, 2
call rdi
lea rdx, str.__s_:
mov r8, rbx
mov rcx, rax
call sub.msvcrt.dll_fprintf
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call rdi
mov rdx, rsi
mov rcx, rax
mov r8, rbx
call sub.msvcrt.dll_vfprintf
mov ecx, 2
call rdi
mov ecx, 0xa
mov rdx, rax
call sub.msvcrt.dll_fputc
nop
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret

Function at 0x4a7aa0
Capabilities:
Hide graphical window

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rsi, qword [0x005d2990]
cmp byte [rsi + 0x1c], 0
je 0x4a7ae0
mov rbx, qword [0x005d29c0]
mov rax, qword [rbx + 0x30]
test rax, rax
je 0x4a7b03
mov rcx, qword [rax + 0x18]
xor edx, edx
call qword [sym.imp.USER32.dll_ShowWindow]
mov rax, qword [rbx + 0x30]
mov byte [rax + 0x54], 0
add rsp, 0x28
pop rbx
pop rsi
ret
lea rdx, str.glutHideWindow
lea rcx, [0x005b7bd8]
call fcn.004a1ad0
mov rbx, qword [0x005d29c0]
mov rax, qword [rbx + 0x30]
test rax, rax
jne 0x4a7ac3
cmp dword [rsi + 0x94], 2
je 0x4a7ac3
lea rdx, str.glutHideWindow
lea rcx, str._ERROR:__Function___s__called_with_no_current_window_defined.
call fcn.004a1ad0
mov rax, qword [rbx + 0x30]
jmp 0x4a7ac3
Function at 0x4a7b30
Capabilities:
Hide graphical window

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rsi, qword [0x005d2990]
cmp byte [rsi + 0x1c], 0
je 0x4a7b75
mov rbx, qword [0x005d29c0]
mov rax, qword [rbx + 0x30]
test rax, rax
je 0x4a7b98
mov rcx, qword [rax + 0x18]
mov edx, 6
mov byte [rax + 0x55], 0
call qword [sym.imp.USER32.dll_ShowWindow]
mov rax, qword [rbx + 0x30]
mov byte [rax + 0x54], 0
add rsp, 0x28
pop rbx
pop rsi
ret
lea rdx, str.glutIconifyWindow
lea rcx, [0x005b7bd8]
call fcn.004a1ad0
mov rbx, qword [0x005d29c0]
mov rax, qword [rbx + 0x30]
test rax, rax
jne 0x4a7b53
cmp dword [rsi + 0x94], 2
je 0x4a7b53
lea rdx, str.glutIconifyWindow
lea rcx, str._ERROR:__Function___s__called_with_no_current_window_defined.
call fcn.004a1ad0
mov rax, qword [rbx + 0x30]
jmp 0x4a7b53

Function at 0x4a86a0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
movaps xmmword [rsp + 0x40], xmm6
movaps xmmword [rsp + 0x50], xmm7
movaps xmmword [rsp + 0x60], xmm8
movaps xmmword [rsp + 0x70], xmm9
mov rax, qword [0x005d2990]
cmp byte [rax + 0x1c], 0
mov rsi, rcx
mov rbx, rdx
je 0x4a8850
mov rcx, rsi
call fcn.004a84d0
test rbx, rbx
mov rsi, rax
je 0x4a86f2
test rax, rax
je 0x4a86f2
cmp byte [rbx], 0
jne 0x4a8714
movaps xmm6, xmmword [rsp + 0x40]
movaps xmm7, xmmword [rsp + 0x50]
movaps xmm8, xmmword [rsp + 0x60]
movaps xmm9, xmmword [rsp + 0x70]
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov ecx, 1
pxor xmm6, xmm6
pxor xmm8, xmm8
call qword [sym.imp.OPENGL32.dll_glPushClientAttrib]
mov rdi, qword [sym.imp.OPENGL32.dll_glPixelStorei]
xor edx, edx
mov ecx, 0xcf0
call rdi
xor edx, edx
mov ecx, 0xcf1
call rdi
xor edx, edx
mov ecx, 0xcf2
call rdi
xor edx, edx
mov ecx, 0xcf3
call rdi
xor edx, edx
mov ecx, 0xcf4
call rdi
mov edx, 1
mov ecx, 0xcf5
call rdi
mov rdi, qword [sym.imp.OPENGL32.dll_glBitmap]
movss xmm9, dword [0x005b7f00]
add rbx, 1
movzx ecx, byte [rbx - 1]
test cl, cl
je 0x4a87e3
cmp cl, 0xa
mov edx, dword [rsi + 0xc]
je 0x4a8810
mov rax, qword [rsi + 0x10]
pxor xmm0, xmm0
add rbx, 1
movss xmm3, dword [rsi + 0x1c]
movss xmm2, dword [rsi + 0x18]
mov rbp, qword [rax + rcx*8]
movzx ecx, byte [rbp]
lea rax, [rbp + 1]
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x30], rax
cvtsi2ss xmm0, ecx
movss dword [rsp + 0x20], xmm0
call rdi
movzx eax, byte [rbp]
pxor xmm0, xmm0
movzx ecx, byte [rbx - 1]
cvtsi2ss xmm0, eax
test cl, cl
addss xmm6, xmm0
jne 0x4a8784
movaps xmm6, xmmword [rsp + 0x40]
movaps xmm7, xmmword [rsp + 0x50]
movaps xmm8, xmmword [rsp + 0x60]
movaps xmm9, xmmword [rsp + 0x70]
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.OPENGL32.dll_glPopClientAttrib]
neg edx
pxor xmm0, xmm0
xor ecx, ecx
xorps xmm6, xmm9
cvtsi2ss xmm0, edx
movss dword [rsp + 0x20], xmm6
movaps xmm3, xmm8
xor edx, edx
mov qword [rsp + 0x30], 0
pxor xmm2, xmm2
pxor xmm6, xmm6
movss dword [rsp + 0x28], xmm0
call qword [sym.imp.OPENGL32.dll_glBitmap]
jmp 0x4a8778
lea rdx, str.glutBitmapString
lea rcx, [0x005b7e00]
call fcn.004a1ad0
jmp 0x4a86d8
Function at 0x4b3410
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x00c87e04]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x4b3598
mov rax, qword [0x00c87e08]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x4b345c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x4b34e5
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x4b3440
mov rcx, rbx
call fcn.004b40b0
test rax, rax
mov r12, rax
je 0x4b35cd
mov rax, qword [0x00c87e08]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call fcn.004b41e0
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x00c87e08]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x4b35b0
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x4b34de
sub eax, 0x40
and eax, 0xffffffbf
jne 0x4b3540
add dword [0x00c87e04], 1
cmp edi, 8
jae 0x4b3513
test dil, 4
jne 0x4b3584
test edi, edi
je 0x4b3508
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x4b359f
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov eax, edi
sub edi, 1
mov rdx, qword [rbp + rax - 8]
cmp edi, 8
mov qword [rbx + rax - 8], rdx
jb 0x4b3508
and edi, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov rcx, qword [rbp + rdx]
cmp eax, edi
mov qword [rbx + rdx], rcx
jb 0x4b352c
jmp 0x4b3508
add rsi, qword [0x00c87e08]
mov r8d, 0x40
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r9, rsi
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x4b34de
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.00586bf0
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x4b3508
xor esi, esi
jmp 0x4b3467
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x4b3508
mov rax, qword [0x00c87e08]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call fcn.00586bf0
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call fcn.00586bf0
nop
nop dword [rax]

Function at 0x4b3d20
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00c880e0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x00c880c0]
test rbx, rbx
je 0x4b3d74
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 0x4b3d6b
test rsi, rsi
je 0x4b3d6b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x4b3d50
lea rcx, [0x00c880e0]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x4b40b0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x005d2640]
cmp word [r8], 0x5a4d
mov rdx, rcx
jne 0x4b411d
mov rcx, r8
call fcn.004b3f90
test eax, eax
je 0x4b411d
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x4b411d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x4b4114
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x4b411f
add rax, 0x28
cmp rax, r9
jne 0x4b4100
xor eax, eax
add rsp, 0x28
ret

Function at 0x4b4810
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x4b4841
xor edx, edx
mov ecx, eax
mov dword [0x00c88130], eax
call fcn.004c5340
test eax, eax
sete al
movzx eax, al
mov dword [0x0058bcf8], eax
add rsp, 0x28
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4b482e

Function at 0x4b4950
Capabilities:
Set thread local storage value

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov edi, 1
mov rax, qword [rdx]
mov rbp, qword [rcx + 0x10]
mov r12, qword [rcx + 0x18]
test rax, rax
mov rsi, rcx
mov rbx, rdx
mov r15, r8
je 0x4b4a50
mov r13, qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x4b49ac
mov qword [0x00c88138], r14
mov rax, qword [rbx]
add edi, 1
mov rax, qword [rax]
test rax, rax
mov qword [rbx], rax
je 0x4b4a50
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
mov r14, qword [rax + 0x30]
mov qword [rsp + 0x28], r12
mov qword [rsp + 0x20], rbx
call rbp
test eax, eax
jne 0x4b4a70
test r14, r14
je 0x4b49ff
mov qword [rsp + 0x20], rbx
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
call r14
cmp eax, 7
je 0x4b4a95
cmp eax, 8
jne 0x4b4a70
mov rax, qword [rbx]
mov r14, qword [rax]
mov eax, dword [0x0058bcf8]
test eax, eax
js 0x4b4a40
test eax, eax
je 0x4b4990
mov rdx, r14
mov ecx, dword [0x00c88130]
call r13
test eax, eax
jne 0x4b4997
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4b4997
call fcn.004b4850
mov eax, dword [0x0058bcf8]
jmp 0x4b4a0f
mov qword [rsp + 0x28], r12
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0x1a
mov qword [rsp + 0x20], rbx
mov ecx, 1
call rbp
test eax, eax
je 0x4b4a90
mov eax, 2
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov eax, 5
mov dword [r15], edi
jmp 0x4b4a75
Function at 0x4b4aa0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov eax, dword [0x0058bcf8]
test eax, eax
mov rbx, rcx
js 0x4b4b20
test eax, eax
jne 0x4b4ad3
mov rax, qword [0x00c88138]
mov qword [0x00c88138], rbx
mov qword [rbx], rax
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov edi, dword [0x00c88130]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
call rsi
mov ebp, eax
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, ebp
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov qword [rbx], rdi
mov rdx, rbx
mov ecx, dword [0x00c88130]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x4b4aca
mov rax, rsi
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
call fcn.004b4850
mov eax, dword [0x0058bcf8]
jmp 0x4b4ab5

Function at 0x4b4b30
Capabilities:
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
mov eax, dword [0x0058bcf8]
mov rbx, qword [rcx]
test eax, eax
js 0x4b4b72
test eax, eax
jne 0x4b4b53
mov qword [0x00c88138], rbx
add rsp, 0x20
pop rbx
ret
mov rdx, rbx
mov ecx, dword [0x00c88130]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x4b4b4d
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
call fcn.004b4850
mov eax, dword [0x0058bcf8]
jmp 0x4b4b42

Function at 0x4b4c40
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x40
mov eax, dword [0x0058bcf8]
test eax, eax
mov rbx, rcx
js 0x4b4cc0
test eax, eax
mov rsi, qword [0x00c88138]
jne 0x4b4cd6
test rsi, rsi
mov qword [rsp + 0x38], rsi
je 0x4b4cb1
lea rdi, [rsp + 0x38]
mov rax, rsi
mov rax, qword [rax + 0x30]
test rax, rax
je 0x4b4c9f
mov qword [rsp + 0x20], rdi
mov r9, rbx
mov r8, qword [rbx]
mov edx, 1
mov ecx, 1
call rax
cmp eax, 6
je 0x4b4d00
cmp eax, 8
jne 0x4b4d33
mov rax, qword [rsp + 0x38]
mov rax, qword [rax]
test rax, rax
mov qword [rsp + 0x38], rax
jne 0x4b4c71
mov eax, 5
add rsp, 0x40
pop rbx
pop rsi
pop rdi
ret
call fcn.004b4850
mov eax, dword [0x0058bcf8]
mov rsi, qword [0x00c88138]
test eax, eax
je 0x4b4c5f
mov esi, dword [0x00c88130]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x4b4c5f
mov rax, qword [rsp + 0x38]
lea r8, [rsp + 0x34]
mov rdx, rdi
mov rcx, rbx
mov qword [rbx + 0x10], 0
mov qword [rsp + 0x38], rsi
mov qword [rbx + 0x18], rax
call fcn.004b4760
cmp eax, 7
jne 0x4b4cb6
mov rcx, rdi
call fcn.004b48e0
mov eax, 3
jmp 0x4b4cb6
Function at 0x4b4e80
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
cmp qword [rcx + 0x10], 0
mov rbx, rcx
je 0x4b4ed0
mov edx, dword [0x0058bcf8]
test edx, edx
js 0x4b4ee0
test edx, edx
mov rsi, qword [0x00c88138]
jne 0x4b4ef6
mov qword [rsp + 0x28], rsi
lea rsi, [rsp + 0x28]
mov rcx, rbx
lea r8, [rsp + 0x24]
mov rdx, rsi
call fcn.004b4950
cmp eax, 7
jne 0x4b4f19
mov rcx, rsi
call fcn.004b48e0
nop dword [rax]
call fcn.004b4c40
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
call fcn.004b4850
mov edx, dword [0x0058bcf8]
mov rsi, qword [0x00c88138]
test edx, edx
je 0x4b4ea6
mov esi, dword [0x00c88130]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x4b4ea6
call sub.msvcrt.dll_abort
nop
nop
mov rax, qword [rcx + 8]
test rax, rax
je 0x4b4f34
mov rdx, rcx
mov ecx, 1
jmp rax
ret
Function at 0x4c7740
Capabilities:
Read file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov r9, qword [rcx + 0x40]
mov rsi, rdx
mov rbx, rcx
mov edx, 1
mov rcx, rsi
call sub.msvcrt.dll_fread
mov edx, 0xffffffff
test rax, rax
jle 0x4c776c
movzx edx, byte [rsi + rax - 1]
mov dword [rbx + 0x48], edx
add rsp, 0x28
pop rbx
pop rsi
ret
Function at 0x52fbf0
Capabilities:
Read file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov r12, qword [sym.imp.msvcrt.dll__errno]
mov rbp, rcx
mov rdi, rdx
mov esi, r8d
jmp 0x52fc18
call r12
cmp dword [rax], 4
jne 0x52fc36
mov rcx, rbp
call fcn.0052fa60
mov r8d, esi
mov rdx, rdi
mov ecx, eax
call sub.msvcrt.dll__read
movsxd rbx, eax
cmp rbx, 0xffffffffffffffff
je 0x52fc10
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret

Function at 0x585910
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
lea rcx, [0x0058ec20]
jmp 0x4b5140

Function at 0x586bf0
Capabilities:
Write file on windows

Disassembly:
lea rcx, [0x00401540]
jmp fcn.00401510
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 fcn.004c4ca0
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.004c4ca0
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop
nop
nop
nop
nop
nop
nop
jmp 0x401530
Function at 0x14006472c
Capabilities:
Get hostname

Disassembly:
mov qword [rsp + 0x10], rbx
mov dword [rsp + 8], ecx
push rbp
push rsi
push rdi
mov rbp, rsp
sub rsp, 0x40
mov rbx, rdx
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x20], xmm0
xor esi, esi
mov qword [rbp - 0x10], rsi
mov dword [rbp + 0x30], esi
lea r8, [rbp + 0x30]
xor edx, edx
lea ecx, [rsi + 3]
call qword [sym.imp.KERNEL32.dll_GetComputerNameExW]
nop dword [rax + rax]
test eax, eax
je 0x140064774
lea edi, [rsi + 0xd]
jmp 0x14006482f
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
cmp eax, 0xea
jne 0x14006482f
mov word [rbp + 0x20], si
mov edx, dword [rbp + 0x30]
mov r8, qword [rbp - 0x18]
mov rcx, r8
mov rdi, qword [rbp - 0x20]
sub rcx, rdi
sar rcx, 1
cmp rdx, rcx
jae 0x1400647b4
lea rax, [rdi + rdx*2]
mov qword [rbp - 0x18], rax
jmp 0x1400647f5
jbe 0x1400647f5
mov rax, qword [rbp - 0x10]
sub rax, rdi
sar rax, 1
cmp rdx, rax
jbe 0x1400647d8
lea r8, [rbp + 0x20]
lea rcx, [rbp - 0x20]
call fcn.140040de4
mov rdi, qword [rbp - 0x20]
jmp 0x1400647f5
sub rdx, rcx
je 0x1400647f1
movzx eax, si
mov rdi, r8
mov rcx, rdx
rep stosw word [rdi], ax
lea r8, [r8 + rdx*2]
mov rdi, qword [rbp - 0x20]
mov qword [rbp - 0x18], r8
lea r8, [rbp + 0x30]
mov rdx, rdi
mov ecx, 3
call qword [sym.imp.KERNEL32.dll_GetComputerNameExW]
nop dword [rax + rax]
test eax, eax
jne 0x140064821
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
jmp 0x14006482f
mov rdx, qword [rbp - 0x20]
mov rcx, rbx
call fcn.1400038e4
mov edi, esi
lea rcx, [rbp - 0x20]
call fcn.14001e814
mov eax, edi
mov rbx, qword [rsp + 0x68]
add rsp, 0x40
pop rdi
pop rsi
pop rbp
ret

Function at 0x140065290
Capabilities:
Terminate process

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
mov ecx, 1
mov dword [0x1400b1340], eax
call fcn.140065730
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_UnhandledExceptionFilter]
cmp dword [0x1400b1340], 0
jne case.default.0x1400652e6
mov ecx, 1
call fcn.140065730
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
mov edx, 0xc0000409
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_TerminateProcess]
test byte [rdx + rdi*2], dl
push rdx
invalid
Function at 0x140004db0
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov ebx, ecx
test r8d, r8d
jne 0x140004c3b
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140004c3b
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140004c3b
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140004c3b
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140004c3b
cmp dword [rcx + 0x84], 0xe
jbe 0x140004c3b
cmp dword [rcx + 0xf8], 0
je 0x140004c3b
mov ecx, ebx
call fcn.140004cdc
lea rax, [rbp + 0x18]
mov byte [rbp + 0x28], 0
mov qword [rbp - 0x20], rax
lea r9, [rbp - 0x2c]
lea rax, [rbp + 0x20]
mov qword [rbp - 0x18], rax
lea r8, [rbp - 0x20]
lea rax, [rbp + 0x28]
mov qword [rbp - 0x10], rax
lea rdx, [rbp - 0x28]
mov eax, 2
lea rcx, [rbp - 0x30]
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
call fcn.140004ab8
cmp dword [rbp + 0x20], 0
je 0x140004c88
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.140004c90
int3
xor r8d, r8d
xor edx, edx
jmp 0x140004bd4
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x14000b0c0]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x14000b0d0]
mov dword [rax], 1
mov rax, qword [0x14000b0e0]
mov dword [rax], 1
mov rax, qword [0x14000b080]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x14000b0b0]
mov dword [0x14000e00c], 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 [0x14000b1a0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x14000b180]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x14000b030]
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 [dbg._matherr]
call dbg.__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