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

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x40
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor esi, esi
mov rbx, rax
test rax, rax
jne 0x14016ea14
xor eax, eax
jmp 0x14016ead7
mov rbp, rbx
cmp word [rax], si
je 0x14016ea39
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x14016ea20
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x14016ea1c
mov qword [rsp + 0x38], rsi
sub rbp, rbx
mov qword [rsp + 0x30], rsi
add rbp, 2
sar rbp, 1
mov r8, rbx
mov r9d, ebp
mov dword [rsp + 0x28], esi
xor edx, edx
mov qword [rsp + 0x20], rsi
xor ecx, ecx
call fcn.1401450f4
movsxd r14, eax
test eax, eax
jne 0x14016ea77
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x14016ea0d
mov rcx, r14
call fcn.14010ec68
mov rdi, rax
test rax, rax
jne 0x14016ea90
xor ecx, ecx
call fcn.14010ec2c
jmp 0x14016ea6c
mov qword [rsp + 0x38], rsi
mov r9d, ebp
mov qword [rsp + 0x30], rsi
mov r8, rbx
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call fcn.1401450f4
test eax, eax
jne 0x14016eac1
mov rcx, rdi
call fcn.14010ec2c
jmp 0x14016eacb
xor ecx, ecx
call fcn.14010ec2c
mov rsi, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rsi
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x40
pop r14
ret
Function at 0x1401730b8
Capabilities:
Set environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x20], rdi
push rbp
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xa0
xor r15d, r15d
mov r14, rdx
mov rsi, rcx
mov qword [rbp + 0x17], r15
xor edx, edx
mov qword [rbp + 0x1f], r15
lea rcx, [rbp - 0x39]
mov qword [rbp + 0x27], r15
mov qword [rbp + 0x2f], r15
mov edi, r15d
mov qword [rbp + 0x37], r15
mov byte [rbp + 0x3f], r15b
mov qword [rbp - 0x19], r15
mov qword [rbp - 0x11], r15
mov qword [rbp - 9], r15
mov qword [rbp - 1], r15
mov qword [rbp + 7], r15
mov byte [rbp + 0xf], r15b
call fcn.1400b5f7c
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x140173142
cmp byte [rbp - 0x21], r15b
je 0x14017313d
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x140173178
call fcn.14010fd90
test eax, eax
jne 0x140173164
cmp byte [rbp - 0x21], r15b
je 0x14017315c
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x140173178
cmp byte [rbp - 0x21], r15b
je 0x140173175
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, r15d
lea r8, [rbp + 0x77]
mov rcx, rsi
lea rdx, [rbp + 0x17]
call fcn.140170dd0
test eax, eax
jne 0x140173218
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.1400b5f7c
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x1401731b7
cmp byte [rbp - 0x21], r15b
je 0x1401731ec
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x1401731ec
call fcn.14010fd90
test eax, eax
jne 0x1401731d8
cmp byte [rbp - 0x21], r15b
je 0x1401731d1
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x1401731ec
cmp byte [rbp - 0x21], r15b
je 0x1401731e9
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, r15d
mov r9d, ebx
lea r8, [rbp + 0x77]
lea rdx, [rbp - 0x19]
mov rcx, r14
call fcn.140170dd0
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x140173218
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x14017321b
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x140173229
mov rcx, rdi
call fcn.14010ec2c
cmp byte [rbp + 0x3f], r15b
je 0x140173238
mov rcx, qword [rbp + 0x27]
call fcn.14010ec2c
lea r11, [rsp + 0xa0]
mov eax, ebx
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
Function at 0x1401739e0
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.1401430f8
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.1401430f8
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x140173b30
cmp rax, 0xffffffffffffffff
je 0x140173b30
xor edi, edi
test rbp, rbp
jle 0x140173adb
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.14010ebb4
mov rbx, rax
test rax, rax
jne 0x140173a68
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x140173ad1
mov edx, 0x8000
mov ecx, r14d
call fcn.140173864
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.14016ac0c
cmp eax, 0xffffffff
je 0x140173ab1
cdqe
sub rbp, rax
test rbp, rbp
jg 0x140173a78
mov edx, r15d
mov ecx, r14d
call fcn.140173864
jmp 0x140173ad1
cmp byte [rsi + 0x38], dil
je 0x140173ac8
cmp dword [rsi + 0x34], 5
jne 0x140173ac8
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], SafeArrayGetElemsize
cmp byte [rsi + 0x30], dil
je 0x140173ad1
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.14010ec2c
jmp 0x140173b44
jns 0x140173b44
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.1401430f8
cmp rax, 0xffffffffffffffff
jne 0x140173afc
cmp byte [rsi + 0x30], dil
je 0x140173b44
mov edi, dword [rsi + 0x2c]
jmp 0x140173b44
mov ecx, r14d
call fcn.14014a9c8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x140173b44
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, SafeArrayGetElemsize
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], SafeArrayGetElemsize
jmp 0x140173b44
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x140173b3d
mov eax, dword [rsi + 0x2c]
jmp 0x140173b42
mov eax, SafeArrayPutElement
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.1401430f8
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret
Function at 0x140006640
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x18
xor edx, edx
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x14000668c
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140006684
cmp dword [rcx + 0x3c], edx
jl 0x140006684
cmp dword [rcx + 0x3c], 0x10000000
jae 0x140006684
movsxd rax, dword [rcx + 0x3c]
add rax, rcx
mov qword [rsp], rax
cmp dword [rax], 0x4550
cmovne rax, rdx
mov rdx, rax
mov qword [rsp], rax
jmp 0x14000668c
mov rax, rdx
add rsp, 0x18
ret

Function at 0x1400012e0
Capabilities:
Link many functions at runtime

Disassembly:
sub rsp, 0x28
mov rcx, qword [0x140007748]
lea rdx, str.InitConverter32
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.UninitConverter
mov qword [0x140007730], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.IsFormatCorrect32
mov qword [0x140007738], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.RegisterApp
mov qword [0x140007710], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.ForeignToRtf32
mov qword [0x140007720], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.RtfToForeign32
mov qword [0x140007700], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.SetAppVer
mov qword [0x140007708], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140007748]
lea rdx, str.BiffToMetro
mov qword [0x140007718], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140007728], rax
xor eax, eax
cmp qword [0x140007730], rax
je 0x1400013f9
cmp qword [0x140007738], rax
je 0x1400013f9
cmp qword [0x140007710], rax
je 0x1400013f9
cmp qword [0x140007720], rax
je 0x1400013f9
cmp qword [0x140007700], rax
je 0x1400013f9
cmp qword [0x140007708], rax
je 0x1400013f9
mov eax, 1
add rsp, 0x28
ret

Function at 0x1400024e4
Capabilities:
Accept command line arguments

Disassembly:
sub rsp, 0x448
mov rax, qword [0x140007010]
xor rax, rsp
mov qword [rsp + 0x430], rax
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov rcx, rax
lea rdx, [rsp + 0x20]
call fcn.140002380
mov ecx, dword [rsp + 0x20]
test cl, 6
jne 0x140002523
and ecx, 1
call fcn.1400021f0
jmp 0x14000252d
lea rcx, [rsp + 0x20]
call fcn.140002080
mov rcx, qword [rsp + 0x430]
xor rcx, rsp
call fcn.1400028e0
add rsp, 0x448
ret
Function at 0x140001f30
Capabilities:
Create thread
Log keystrokes via application hook

Disassembly:
push rbx
sub rsp, 0x70
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x60], rax
xor eax, eax
lea r8, [0x140001f10]
mov qword [rsp + 0x28], rax
xor r9d, r9d
xor edx, edx
mov dword [rsp + 0x20], eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
xor r9d, r9d
lea rdx, [0x1400018d0]
xor r8d, r8d
mov ecx, 0xd
call qword [sym.imp.USER32.dll_SetWindowsHookExW]
mov rbx, rax
test rax, rax
jne 0x140001faf
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
lea rdx, str.Failed_to_install_keyboard_hook._n
call fcn.140003c20
mov eax, 0xffffffff
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.140004800
add rsp, 0x70
pop rbx
ret
call qword [sym.imp.KERNEL32.dll_GetConsoleWindow]
mov rcx, rax
xor edx, edx
call qword [sym.imp.USER32.dll_ShowWindow]
xor r9d, r9d
lea rcx, [rsp + 0x30]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
je 0x14000200d
nop word [rax + rax]
lea rcx, [rsp + 0x30]
call qword [sym.imp.USER32.dll_TranslateMessage]
lea rcx, [rsp + 0x30]
call qword [sym.imp.USER32.dll_DispatchMessageW]
xor r9d, r9d
lea rcx, [rsp + 0x30]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jne 0x140001fe0
mov rcx, rbx
call qword [sym.imp.USER32.dll_UnhookWindowsHookEx]
xor eax, eax
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.140004800
add rsp, 0x70
pop rbx
ret

Function at 0x1400023c0
Capabilities:
Write file on windows

Disassembly:
push rbx
push rdi
push r15
sub rsp, 0x20
cmp qword [rcx + 0x68], 0
mov rbx, r8
mov r15, rdx
mov rdi, rcx
je 0x1400023e8
add rsp, 0x20
pop r15
pop rdi
pop rbx
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x40]
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x48], rsi
mov rsi, rbx
mov qword [rsp + 0x58], r14
mov r9, qword [rax]
test r9, r9
je 0x14000240e
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x140002410
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x140002469
test ecx, ecx
jle 0x140002449
cmp rbx, rbp
mov rcx, r9
cmovl rbp, rbx
mov r8, rbp
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rdi + 0x58]
add r15, rbp
sub rbx, rbp
sub dword [rax], ebp
mov rcx, qword [rdi + 0x40]
movsxd rax, ebp
add qword [rcx], rax
test rbx, rbx
jle 0x140002469
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x140002469
mov r8, rbx
mov edx, 1
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
sub rbx, rax
mov r14, qword [rsp + 0x58]
sub rsi, rbx
mov rbp, qword [rsp + 0x40]
mov rax, rsi
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r15
pop rdi
pop rbx
ret
Function at 0x140002490
Capabilities:
Read file on windows

Disassembly:
push rbp
push rsi
push r14
sub rsp, 0x30
mov rbp, r8
mov r14, rdx
mov rsi, rcx
test r8, r8
jg 0x1400024b2
xor eax, eax
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
cmp qword [rcx + 0x68], 0
je 0x1400024c8
add rsp, 0x30
pop r14
pop rsi
pop rbp
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x38]
mov qword [rsp + 0x28], rbx
mov rbx, rbp
mov rdx, qword [rax]
test rdx, rdx
je 0x1400024e4
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x1400024e6
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x140002522
mov qword [rsp + 0x20], rdi
cmp rax, rbp
mov rdi, rbp
mov rcx, r14
cmovb rdi, rax
mov r8, rdi
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rsi + 0x50]
add r14, rdi
sub rbx, rdi
sub dword [rax], edi
mov rcx, qword [rsi + 0x38]
movsxd rax, edi
mov rdi, qword [rsp + 0x20]
add qword [rcx], rax
cmp qword [rsi + 0x80], 0
je 0x1400025be
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x14000255d
mov rcx, qword [rsi + 0x88]
mov rdx, qword [rsi + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rsi + 0x38]
mov qword [rax], rcx
mov rax, qword [rsi + 0x50]
mov dword [rax], edx
cmp rbx, 0xfff
jbe 0x14000259e
nop word [rax + rax]
mov r9, qword [rsi + 0x80]
mov edx, 1
mov r8d, 0xfff
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add r14, rax
sub rbx, rax
cmp rax, 0xfff
jne 0x1400025be
cmp rbx, rax
ja 0x140002570
test rbx, rbx
je 0x1400025be
mov r9, qword [rsi + 0x80]
mov r8, rbx
mov edx, 1
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
sub rbx, rax
sub rbp, rbx
mov rbx, qword [rsp + 0x28]
mov rax, rbp
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
Function at 0x140002a20
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x140002a4d
xor eax, eax
jmp 0x140002bb9
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x140002a87
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x140002a87
lea ecx, [r8 - 1]
mov dword [rax], ecx
mov eax, edi
mov rdx, qword [rbx + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 1]
mov qword [rdx], rcx
mov byte [r8], dil
jmp 0x140002bb9
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x140002bac
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x140002aca
mov rcx, qword [rbx + 0x88]
mov rdx, qword [rbx + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rbx + 0x38]
mov qword [rax], rcx
mov rax, qword [rbx + 0x50]
mov dword [rax], edx
mov rcx, qword [rbx + 0x68]
test rcx, rcx
jne 0x140002af5
mov rdx, qword [rbx + 0x80]
movsx ecx, dil
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x140002bb1
lea rax, [rsp + 0x40]
mov byte [rsp + 0x50], dil
mov qword [rsp + 0x38], rax
lea rdx, [rbx + 0x74]
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x51]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x50]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__char_const____ptr64__char_const____ptr64__char_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140002b64
sub eax, 1
je 0x140002b64
cmp eax, 2
jne 0x140002bac
movsx ecx, byte [rsp + 0x50]
mov rdx, qword [rbx + 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x140002bb1
mov rsi, qword [rsp + 0x40]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x140002b92
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x58]
mov r8, rsi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rsi, rax
jne 0x140002bac
lea rax, [rsp + 0x50]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x48], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x140002bb1
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140004800
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret
Function at 0x140003660
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x60
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x58], rax
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x140003733
cmp byte [rcx + 0x71], 0
je 0x140003733
mov rax, qword [rcx]
mov edx, 0xffffffff
mov qword [rsp + 0x78], rdi
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x14000372f
mov rcx, qword [rbx + 0x68]
lea rax, [rsp + 0x30]
lea rdx, [rbx + 0x74]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x58]
lea r8, [rsp + 0x38]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x1400036f4
sub eax, 1
je 0x1400036f8
cmp eax, 2
jne 0x14000372f
mov byte [rbx + 0x71], 0
mov al, 1
mov rdi, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140004800
add rsp, 0x60
pop rbx
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
sub rdi, rax
je 0x140003726
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x38]
mov r8, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rdi, rax
jne 0x14000372f
cmp byte [rbx + 0x71], 0
sete al
jmp 0x1400036dc
xor al, al
jmp 0x1400036dc
mov al, 1
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140004800
add rsp, 0x60
pop rbx
ret

Function at 0x140005340
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14000538a
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14000538a
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14000538a
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14000538a
cmp dword [rcx + 0x84], 0xe
jbe 0x14000538a
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x14000538c
xor al, al
add rsp, 0x28
ret
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x004cb100]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x004cb110]
mov dword [rax], 1
mov rax, qword [0x004cb120]
mov dword [rax], 1
mov rax, qword [0x004cb0f0]
mov dword [rax], 1
mov rax, qword [0x004caf70]
cmp word [rax], 0x5a4d
jne 0x401067
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x4010c0
mov rax, qword [0x004cb0e0]
mov dword [0x004d600c], ecx
mov eax, dword [rax]
test eax, eax
jne 0x4010b0
mov ecx, 1
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x004cb070]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x004caf00]
cmp dword [rax], 1
je 0x4010f0
xor eax, eax
add rsp, 0x28
ret
mov ecx, 2
call sym.__set_app_type
jmp 0x401084
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x401108
cmp dx, 0x20b
jne 0x401067
cmp dword [rax + 0x84], 0xe
jbe 0x401067
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x401067
lea rcx, [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401067
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x401067

Function at 0x402c70
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 0x402ca3
mov rcx, r13
call sym.ferror
test eax, eax
jne 0x402cb0
mov rax, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
ret
mov rcx, r13
call sym.checkErr_systemZio_141.part.0
nop
nop dword [rax]

Function at 0x403520
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
sub rsp, 0x28
mov r12, rcx
mov rcx, rdx
mov edx, 1
mov r9, r12
call sym.fwrite
mov rcx, r12
movsxd r13, eax
call sym.ferror
test eax, eax
jne 0x403556
mov rax, r13
add rsp, 0x28
pop r12
pop r13
ret
mov rcx, r12
call sym.checkErr_systemZio_141.part.0
nop
nop

Function at 0x403760
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rdi, rcx
mov rsi, rdx
test rdx, rdx
jle 0x4037c8
mov rbp, qword [dbg.__acrt_iob_func]
xor ebx, ebx
xor r12d, r12d
lea r13, [rdx - 1]
nop word [rax + rax]
mov r12, qword [rdi + r12*8]
mov ecx, 1
add rbx, 1
call rbp
xor r8d, r8d
mov rcx, rax
mov rdx, r12
call sym.writeWindows_systemZio_205
cmp rbx, rsi
jge 0x4037cf
mov r12, rbx
jb 0x403790
mov rdx, r13
mov rcx, rbx
call sym.raiseIndexError2
jmp 0x403790
mov rbp, qword [dbg.__acrt_iob_func]
mov ecx, 1
call rbp
mov r8d, 1
mov edx, 1
lea rcx, [0x004ab17c]
mov r9, rax
call sym.fwrite
mov ecx, 1
call rbp
mov rcx, rax
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
jmp sym.fflush
Function at 0x403870
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0x20
xor r12d, r12d
mov r15, rcx
mov ecx, 0xfa0
call sym.mnewString
mov r14, rax
lea rbx, [rax + 0x10]
test rax, rax
je 0x403980
nop dword [rax]
cmp qword [r14], 0
jne 0x4038b4
mov rdx, 0xffffffffffffffff
xor ecx, ecx
call sym.raiseIndexError2
mov r9, r15
mov r8d, 0xfa0
mov edx, 1
mov rcx, rbx
call sym.fread
mov r13, rax
cmp rax, 0xfa0
je 0x403948
mov rcx, r15
call sym.ferror
test eax, eax
jne 0x403a09
test r13, r13
js 0x4039f0
mov rdx, r13
mov rcx, r14
call sym.setLengthStr
mov rbx, rax
test rax, rax
je 0x4039d0
mov rdx, qword [rax]
mov rcx, r12
call sym.resizeString
lea rdx, [rbx + 0x10]
mov r12, rax
mov rax, qword [rax]
lea rcx, [r12 + rax + 0x10]
mov rax, qword [rbx]
lea r8, [rax + 1]
call sym.memcpy
mov rax, qword [rbx]
add qword [r12], rax
mov rax, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
pop r14
pop r15
ret
mov rdx, qword [r14]
mov rcx, r12
call sym.resizeString
mov r8, qword [r14]
mov rdx, rbx
mov r12, rax
mov rax, qword [rax]
add r8, 1
lea rcx, [r12 + rax + 0x10]
call sym.memcpy
mov rax, qword [r14]
add qword [r12], rax
jmp 0x4038a0
mov r12, rax
jmp 0x403995
mov rcx, r12
xor edx, edx
call sym.resizeString
mov r12, rax
mov rdx, 0xffffffffffffffff
xor ecx, ecx
call sym.raiseIndexError2
mov r9, r15
mov edx, 1
mov rcx, rbx
mov r8d, 0xfa0
call sym.fread
mov r13, rax
cmp rax, 0xfa0
jne 0x4038d5
jmp 0x403988
xor edx, edx
mov rcx, r12
add rsp, 0x20
pop rbx
pop r12
pop r13
pop r14
pop r15
jmp sym.resizeString
movabs r8, 0x7fffffffffffffff
xor edx, edx
mov rcx, r13
call sym.raiseRangeErrorI
jmp 0x4038ee
mov rcx, r15
call sym.checkErr_systemZio_141.part.0
nop
nop word cs:[rax + rax]
nop dword [rax]