Function at 0x180012500
Capabilities:
Read file on windows

Disassembly:
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x238
and r9b, 1
mov byte [rsp + 0x67], r9b
and r8b, 1
mov byte [rsp + 0x5d], r8b
mov qword [rsp + 0xf0], rdx
mov qword [rsp + 0xe8], rcx
mov rsi, qword [rsp + 0xe8]
test byte [rsp + 0x5d], 1
je 0x180012569
lea rcx, [rsp + 0x78]
lea rdx, [rsp + 0x80]
lea r8, [rsp + 0xb0]
lea r9, [rsp + 0xa8]
call fcn.18000f120
test al, 1
jne 0x180012567
jmp 0x180012b86
jmp 0x180012569
lea rcx, [rsp + 0x160]
xor edx, edx
mov r8d, 0x68
call sub.ntdll.dll_memset
mov dword [rsp + 0x160], WSAGetLastError
test byte [rsp + 0x67], 1
je 0x1800125a5
mov word [rsp + 0x1a0], 0
mov dword [rsp + 0x19c], 1
test byte [rsp + 0x5d], 1
je 0x1800125ef
mov ecx, dword [rsp + 0x19c]
call fcn.18002f9a0
mov dword [rsp + 0x19c], eax
mov rax, qword [rsp + 0xb0]
mov qword [rsp + 0x1b0], rax
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x1b8], rax
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x1c0], rax
lea rcx, [rsp + 0x90]
xor edx, edx
mov r8d, 0x18
call sub.ntdll.dll_memset
mov byte [rsp + 0x5f], 0
mov rcx, qword [rsp + 0xf0]
call fcn.18004ec10
mov rdi, rax
xor ecx, ecx
mov edx, 0x35cc8d99
call fcn.180044f80
xor ecx, ecx
lea rbp, [rsp + 0x160]
lea rbx, [rsp + 0x90]
xor ecx, ecx
mov rdx, rdi
xor r8d, r8d
xor r9d, r9d
mov dword [rsp + 0x20], 1
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x48], rbx
call rax
cmp eax, 0
jne 0x1800126d5
mov ecx, 0xad2be123
call fcn.18002ced0
xor ecx, ecx
mov edx, eax
call fcn.180044f80
call rax
mov edi, eax
lea rcx, [0x18006a4b0]
lea rdx, [rsp + 0x1e8]
call fcn.180032440
lea rcx, [rsp + 0x148]
mov rdx, rax
mov r8d, edi
call fcn.180052c00
lea rdx, [rsp + 0x148]
mov rcx, rsi
call fcn.18002bfe0
lea rcx, [rsp + 0x148]
call fcn.1800501f0
jmp 0x180012aec
mov edi, dword [rsp + 0xa0]
lea rcx, [0x18006cba0]
lea rdx, [rsp + 0x20e]
call fcn.180032440
lea rcx, [rsp + 0x130]
mov rdx, rax
mov r8d, edi
call fcn.180052c00
lea rdx, [rsp + 0x130]
mov rcx, rsi
call fcn.18002bfe0
lea rcx, [rsp + 0x130]
call fcn.1800501f0
test byte [rsp + 0x5d], 1
jne 0x180012731
mov byte [rsp + 0x5f], 1
jmp 0x180012aec
mov dword [rsp + 0x6c], 0
mov dword [rsp + 0x68], 0
mov ecx, 0xea
call fcn.180044040
mov byte [rsp + 0x5c], al
mov byte [rsp + 0x5e], 0
mov rcx, qword [rsp + 0x78]
call fcn.1800237e0
cmp rax, 0
jbe 0x1800128d4
test byte [rsp + 0x5c], 1
je 0x1800127bf
cmp dword [rsp + 0x6c], 0
jle 0x1800127ba
lea rcx, [rsp + 0x118]
lea rdx, [0x18006d02a]
call fcn.18005cc80
lea rdx, [rsp + 0x118]
mov rcx, rsi
call fcn.18002bfe0
mov bl, al
xor bl, 0xff
lea rcx, [rsp + 0x118]
call fcn.1800501f0
test bl, 1
jne 0x1800127b3
jmp 0x1800127b8
jmp 0x180012acc
jmp 0x1800127ba
mov byte [rsp + 0x5c], 0
mov rdi, qword [rsp + 0x78]
xor ecx, ecx
mov edx, 0x3d22e7fd
call fcn.180044f80
lea rbp, [rsp + 0x74]
mov rcx, rdi
xor edx, edx
xor r8d, r8d
xor r9d, r9d
mov qword [rsp + 0x20], rbp
mov qword [rsp + 0x28], 0
call rax
cmp eax, 0
jne 0x1800127fa
jmp 0x180012acc
cmp dword [rsp + 0x74], 0
jbe 0x1800128cf
lea rcx, [rsp + 0xb8]
call fcn.180050230
mov edx, dword [rsp + 0x74]
lea rcx, [rsp + 0xb8]
call fcn.18005e600
lea rcx, [rsp + 0xb8]
call fcn.18004f840
mov rdi, rax
lea rcx, [rsp + 0xb8]
call fcn.18004ec10
mov rcx, qword [rsp + 0x78]
lea r9, [rsp + 0x8c]
mov rdx, rax
mov r8d, edi
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, 0
jne 0x180012871
mov dword [rsp + 0x60], 4
jmp 0x1800128b1
mov edx, dword [rsp + 0x8c]
lea rcx, [rsp + 0xb8]
call fcn.18005e600
lea rdx, [rsp + 0xb8]
mov rcx, rsi
call fcn.18002bfe0
test al, 1
jne 0x1800128a9
mov ecx, 0x9a5863ef
call fcn.18002ced0
mov dword [rsp + 0x60], eax
jmp 0x1800128b1
mov dword [rsp + 0x60], 0
lea rcx, [rsp + 0xb8]
call fcn.1800501f0
mov eax, dword [rsp + 0x60]
test eax, eax
je 0x1800128cd
jmp 0x1800128c8
jmp 0x180012aca
jmp 0x1800128cf
jmp 0x180012969
test byte [rsp + 0x5c], 1
je 0x180012967
lea rdx, [0x18006d20c]
mov rcx, rsi
mov r8d, 1
call fcn.180032050
mov edi, dword [rsp + 0x6c]
mov ecx, 0x9a5863ea
call fcn.18002ced0
add edi, eax
mov dword [rsp + 0x6c], edi
mov ecx, dword [rsp + 0x68]
call fcn.18003a250
mov dword [rsp + 0x68], eax
cmp dword [rsp + 0x68], 0x2bf20
jl 0x180012965
lea rcx, [0x18006c2d0]
lea rdx, [rsp + 0x1ce]
call fcn.180032440
lea rcx, [rsp + 0x100]
mov rdx, rax
call fcn.18005cc80
lea rdx, [rsp + 0x100]
mov rcx, rsi
call fcn.18002bfe0
lea rcx, [rsp + 0x100]
call fcn.1800501f0
jmp 0x180012acc
jmp 0x180012967
jmp 0x180012969
test byte [rsp + 0x5c], 1
jne 0x180012a64
lea rcx, [rsp + 0xd0]
call fcn.180050230
movabs rcx, 0x8a6786d9a5867eb
call fcn.18003cf50
lea rcx, [rsp + 0xd0]
mov rdx, rax
call fcn.18005e600
lea rcx, [rsp + 0xd0]
call fcn.18004f840
mov rdi, rax
lea rcx, [rsp + 0xd0]
call fcn.18004ec10
mov rcx, rsi
mov rdx, rax
mov r8, rdi
call fcn.18002f820
mov dword [rsp + 0x70], eax
cmp eax, 0
jge 0x1800129de
mov dword [rsp + 0x60], 4
jmp 0x180012a49
cmp dword [rsp + 0x70], 0
jle 0x180012a41
mov ebp, dword [rsp + 0x70]
lea rcx, [rsp + 0xd0]
call fcn.18004ec10
mov rbx, rax
mov rdi, qword [rsp + 0xa8]
mov ecx, 0xafe12c66
call fcn.18002ced0
xor ecx, ecx
mov edx, eax
call fcn.180044f80
lea r9, [rsp + 0xfc]
mov rcx, rdi
mov rdx, rbx
mov r8d, ebp
mov qword [rsp + 0x20], 0
call rax
cmp eax, 0
jne 0x180012a3f
mov dword [rsp + 0x60], 4
jmp 0x180012a49
jmp 0x180012a41
mov dword [rsp + 0x60], 0
lea rcx, [rsp + 0xd0]
call fcn.1800501f0
mov eax, dword [rsp + 0x60]
test eax, eax
je 0x180012a62
jmp 0x180012a60
jmp 0x180012aca
jmp 0x180012a64
test byte [rsp + 0x5e], 1
je 0x180012a6d
jmp 0x180012acc
mov rdi, qword [rsp + 0x90]
xor ecx, ecx
mov edx, 0x3586f06e
call fcn.180044f80
mov rbx, rax
mov ecx, 0x9a58638f
call fcn.18002ced0
mov rcx, rdi
mov edx, eax
call rbx
cmp eax, 0
jne 0x180012a9c
jmp 0x180012acc
call fcn.18005e6b0
mov r8, qword [rsi + 0x18]
mov rcx, rax
mov edx, 0x64
call fcn.18002b8a0
cmp eax, 0
jne 0x180012abc
mov byte [rsp + 0x5e], 1
jmp 0x180012abe
mov al, 1
test al, 1
jne 0x180012754
jmp 0x180012aca
jmp 0x180012acc
mov rsi, qword [rsp + 0x90]
xor ecx, ecx
mov edx, 0x3e51c24f
call fcn.180044f80
mov rcx, rsi
xor edx, edx
call rax
mov byte [rsp + 0x5f], 1
cmp qword [rsp + 0x90], 0
je 0x180012b05
mov rcx, qword [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp qword [rsp + 0x98], 0
je 0x180012b29
mov rsi, qword [rsp + 0x98]
xor ecx, ecx
mov edx, 0x3083b67d
call fcn.180044f80
mov rcx, rsi
call rax
test byte [rsp + 0x5d], 1
je 0x180012b86
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rsi, qword [rsp + 0x80]
xor ecx, ecx
mov edx, 0x3083b67d
call fcn.180044f80
mov rcx, rsi
call rax
mov rsi, qword [rsp + 0xb0]
xor ecx, ecx
mov edx, 0x3083b67d
call fcn.180044f80
mov rcx, rsi
call rax
mov rsi, qword [rsp + 0xa8]
xor ecx, ecx
mov edx, 0x3083b67d
call fcn.180044f80
mov rcx, rsi
call rax
nop
add rsp, 0x238
pop rbx
pop rbp
pop rdi
pop rsi
ret