Function at 0x419510
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4364f8
mov eax, dword fs:[0]
push eax
sub esp, 0x2c
push ebx
push esi
push edi
mov eax, dword [0x46d624]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 8]
xor ebx, ebx
push ebx
push ebx
push 3
push ebx
push 1
push 0x80000000
push eax
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x20], eax
cmp eax, ebx
je 0x4198ba
cmp eax, 0xffffffff
je 0x4198ba
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, eax
mov dword [ebp - 0x28], ecx
cmp ecx, ebx
je 0x4198ba
cmp ecx, 0xffffffff
je 0x4198ba
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x30], ebx
lea edx, [ebp - 0x11]
push edx
push ecx
xor eax, eax
push eax
lea ecx, [ebp - 0x38]
mov byte [ebp - 4], 1
mov byte [ebp - 0x11], bl
call fcn.00404fb0
mov esi, dword [ebp - 0x38]
mov eax, dword [ebp - 0x34]
cmp esi, eax
je 0x41989c
mov edi, eax
sub edi, esi
cmp edi, dword [ebp - 0x28]
jne 0x41989c
cmp esi, ebx
je 0x4198ba
mov ecx, dword [ebp - 0x20]
push ebx
lea eax, [ebp - 0x1c]
push eax
push edi
push esi
push ecx
mov dword [ebp - 0x1c], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x419615
mov edx, dword [ebp - 0x28]
cmp dword [ebp - 0x1c], edx
jne 0x419615
mov eax, dword [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x10
lea ecx, [ebp - 0x38]
push 0x46d02c
push ecx
mov dword [ebp - 0x20], ebx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x419622
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x157ec
lea edx, [ebp - 0x38]
push 0x43cb70
push edx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x419649
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x1a76d
lea eax, [ebp - 0x38]
push 0x452380
push eax
call fcn.00418170
add esp, 0xc
lea ecx, [ebp - 0x38]
cmp eax, ebx
jne 0x419670
call fcn.00404f80
jmp 0x4198ba
push 0x3f
push 0x46cbd8
push ecx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x419691
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x21
lea edx, [ebp - 0x38]
push 0x46cc18
push edx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x4196b5
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x47
lea eax, [ebp - 0x38]
push 0x46cc40
push eax
call fcn.00418170
add esp, 0xc
lea ecx, [ebp - 0x38]
cmp eax, ebx
jne 0x4196d9
call fcn.00404f80
jmp 0x4198ba
push 0x29
push 0x46cc88
push ecx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x4196fa
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x5b
lea edx, [ebp - 0x38]
push 0x46ccb8
push edx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x41971e
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x6f
lea eax, [ebp - 0x38]
push 0x46cd18
push eax
call fcn.00418170
add esp, 0xc
lea ecx, [ebp - 0x38]
cmp eax, ebx
jne 0x419742
call fcn.00404f80
jmp 0x4198ba
push 0x101
push 0x46cd88
push ecx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x419766
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x7f
lea edx, [ebp - 0x38]
push 0x46ce90
push edx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x41978a
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x1d
lea eax, [ebp - 0x38]
push 0x46cf10
push eax
call fcn.00418170
add esp, 0xc
lea ecx, [ebp - 0x38]
cmp eax, ebx
jne 0x4197ae
call fcn.00404f80
jmp 0x4198ba
push 0x49
push 0x46cf30
push ecx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x4197cf
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x33
lea edx, [ebp - 0x38]
push 0x46cf7c
push edx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x4197f3
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
push 0x49
lea eax, [ebp - 0x38]
push str.:_s
push eax
call fcn.00418170
add esp, 0xc
lea ecx, [ebp - 0x38]
cmp eax, ebx
jne 0x419817
call fcn.00404f80
jmp 0x4198ba
push 0x2f
push 0x46cffc
push ecx
call fcn.00418170
add esp, 0xc
cmp eax, ebx
jne 0x419838
lea ecx, [ebp - 0x38]
call fcn.00404f80
jmp 0x4198ba
mov edx, dword [ebp + 0xc]
push ebx
push ebx
push 4
push ebx
push ebx
push 0xc0000000
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x24], eax
cmp eax, ebx
je 0x419615
cmp eax, 0xffffffff
je 0x419615
push ebx
lea ecx, [ebp - 0x1c]
push ecx
push edi
push esi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x419882
mov edx, dword [ebp - 0x28]
mov dword [ebp - 0x18], 1
cmp edx, dword [ebp - 0x1c]
je 0x419885
mov dword [ebp - 0x18], ebx
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x38]
mov dword [ebp - 0x24], ebx
call fcn.00404f80
jmp 0x4198ba
cmp esi, ebx
je 0x4198ba
push esi
call fcn.0042a03b
add esp, 4
jmp 0x4198ba
mov eax, dword [ebp - 0x20]
cmp eax, ebx
je 0x4198cd
cmp eax, 0xffffffff
je 0x4198cd
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x24]
cmp eax, ebx
je 0x4198e0
cmp eax, 0xffffffff
je 0x4198e0
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret