Function at 0x180040550
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xb0
mov rax, qword [0x180081de0]
xor rax, rsp
mov qword [rsp + 0xa0], rax
imul r15d, r9d, 0x4f1
mov ebp, r9d
mov r14, r8
mov rdi, rdx
mov r12, rcx
mov ebx, r9d
cmp r9d, r15d
ja 0x1800405e1
mov rsi, qword [rsp + 0x50]
xor r13d, r13d
nop dword [rax]
cmp ebx, 0x6bd8
ja 0x1800406ee
je 0x1800406b0
mov eax, ebx
sub eax, 0xc
je 0x1800407d6
sub eax, 0x28
je 0x180040771
sub eax, 0xa4
je 0x180040678
sub eax, 0x16
je 0x180040610
cmp eax, 0x16a2
jne 0x1800407c3
mov eax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xa0]
xor rcx, rsp
call fcn.18005fed0
mov rbx, qword [rsp + 0x108]
add rsp, 0xb0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov r8d, 5
mov word [rsp + 0x88], r13w
lea rdx, [0x18007a86a]
lea rcx, [rsp + 0x88]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncat]
mov r8d, 3
lea rdx, [0x18007a88a]
lea rcx, [rsp + 0x92]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
mov r8d, 2
mov word [rsp + 0x98], r13w
lea rdx, [0x18007a8a6]
lea rcx, [rsp + 0x98]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
jmp 0x1800407c3
mov eax, dword [r12]
lea r9, [rsp + 0x48]
mov qword [rsp + 0x28], rdi
lea rdx, [0x18005f790]
mov r8, r14
mov dword [rsp + 0x48], eax
lea rcx, [rsp + 0x50]
mov dword [rsp + 0x20], 0x62
mov dword [rsp + 0x50], r13d
call fcn.18002e710
jmp 0x1800407c3
mov qword [rsp + 0x30], reloc.SHLWAPI.dll_GetAcceptLanguagesA
lea rax, [rsp + 0x88]
mov qword [rsp + 0x28], r13
mov r9d, 0x46
xor r8d, r8d
mov qword [rsp + 0x20], rax
xor edx, edx
mov word [rsp + 0x9c], r13w
xor ecx, ecx
call fcn.1800503f0
mov rsi, rax
jmp 0x1800407c3
cmp ebx, 0xd6c2
je 0x18004079c
cmp ebx, 0x141ac
je 0x180040792
cmp ebx, 0x1ac96
je 0x180040778
cmp ebx, 0x21780
je 0x180040727
cmp ebx, 0x2826a
je 0x1800405e1
jmp 0x1800407c3
mov ecx, dword [r14]
lea rdx, [rsp + 0x58]
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll__fstat64i32]
test eax, eax
jne 0x18004080b
movabs rax, 0x303146464944424d
cmp qword [rdi], rax
jne 0x180040801
mov eax, dword [rdi + 0x18]
mov ecx, dword [rdi + 0x1c]
add rcx, rax
mov eax, dword [rdi + 0x14]
add rax, 0x20
add rcx, rax
movsxd rax, dword [rsp + 0x6c]
cmp rcx, rax
jne 0x180040801
mov dword [rsp + 0x40], r13d
jmp 0x1800407c3
mov ecx, dword [rdi + 0x14]
call rsi
mov ecx, dword [rdi + 0x18]
mov dword [rdi + 0x14], eax
call rsi
mov ecx, dword [rdi + 0x1c]
mov dword [rdi + 0x18], eax
call rsi
mov dword [rdi + 0x1c], eax
jmp 0x1800407c3
mov ecx, dword [rdi + 0x10]
call rsi
mov dword [rdi + 0x10], eax
jmp 0x1800407c3
mov ecx, dword [r14]
mov r8d, 0x20
mov rdx, rdi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__read]
cmp eax, 0x20
jne 0x18004080b
mov ecx, dword [rdi + 8]
call rsi
mov ecx, dword [rdi + 0xc]
mov dword [rdi + 8], eax
call rsi
mov dword [rdi + 0xc], eax
imul eax, ebp, 0x73
add ebx, eax
cmp ebx, r15d
jbe 0x1800405a0
jmp 0x1800405e1
cmp byte [0x180082798], r13b
jne 0x1800407e9
mov byte [rsp + 0x40], r13b
jmp 0x1800405e1
mov rcx, r14
call qword [0x180082768]
mov byte [0x180082799], al
mov byte [rsp + 0x40], al
jmp 0x1800405e1
mov eax, 8
jmp 0x1800405e5
mov eax, 6
jmp 0x1800405e5