Function at 0x411ded
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
xor ebx, ebx
push edi
mov dword [ebp - 0xc], ebx
call fcn.00412171
cmp dword [ebp + 8], ebx
jne 0x411e0c
mov dword [ebp + 8], section..rdata
mov esi, dword [sym.imp.KERNEL32.dll_CreateFileW]
push ebx
mov edi, pe_nt_image_headers32
push edi
push 3
push ebx
push 1
push 0xc0000000
push dword [ebp + 8]
mov dword [0x41d85c], ebx
call esi
mov dword [0x41d850], eax
cmp eax, 0xffffffff
jne 0x411e7d
push ebx
push edi
push 3
push ebx
push 1
mov ebx, 0x80000000
push ebx
push dword [ebp + 8]
call esi
mov dword [0x41d850], eax
cmp eax, 0xffffffff
jne 0x411e68
push 0
push edi
push 3
push 0
push 3
push ebx
push dword [ebp + 8]
call esi
mov dword [0x41d850], eax
mov dword [0x41d85c], 1
cmp eax, 0xffffffff
je 0x41210e
xor ebx, ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, dword [ebp + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
push 3
pop esi
mov dword [ebp - 8], eax
mov dword [0x41d868], ebx
mov dword [0x41d87c], ecx
cmp eax, esi
jl 0x411eef
push ebx
lea eax, [ebp - 0x10]
push eax
push esi
lea eax, [ebp - 4]
push eax
push dword [0x41d850]
call edi
cmp dword [ebp - 0x10], esi
jne 0x411ee0
push esi
lea eax, [ebp - 4]
push 0x4170dc
push eax
call sub.MSVCRT.dll_memcmp
add esp, 0xc
test eax, eax
jne 0x411ee0
sub dword [ebp - 8], esi
mov dword [0x41d868], 0xfde9
jmp 0x411eef
push ebx
push ebx
push ebx
push dword [0x41d850]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [ebp - 8]
cmp eax, ebx
jle 0x411fc3
add eax, 2
push eax
push ebx
push dword [0x41d3f4]
cmp dword [0x41d868], ebx
jne 0x411f99
mov esi, dword [sym.imp.KERNEL32.dll_HeapAlloc]
call esi
mov dword [ebp + 8], eax
cmp eax, ebx
je 0x411fc3
mov eax, dword [ebp - 8]
lea eax, [eax*4 + 2]
push eax
push ebx
push dword [0x41d3f4]
call esi
mov dword [0x41d860], eax
cmp eax, ebx
je 0x412157
push ebx
lea eax, [ebp - 0x10]
push eax
push dword [ebp - 8]
push dword [ebp + 8]
push dword [0x41d850]
call edi
mov eax, dword [ebp - 0x10]
mov dword [ebp + 0xc], eax
mov eax, dword [ebp - 8]
shl eax, 2
mov dword [ebp - 8], eax
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
lea eax, [ebp - 8]
push eax
push dword [0x41d860]
call fcn.004163c0
push dword [ebp + 8]
mov dword [0x41d868], 0xfde9
push ebx
push dword [0x41d3f4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x411fc3
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [0x41d860], eax
cmp eax, ebx
je 0x412157
push ebx
lea ecx, [ebp - 0x10]
push ecx
push dword [ebp - 8]
push eax
push dword [0x41d850]
call edi
mov eax, dword [ebp - 0x10]
mov dword [ebp - 8], eax
mov eax, dword [0x41d860]
cmp eax, ebx
je 0x412157
mov edx, dword [ebp - 8]
xor ecx, ecx
mov word [eax + edx], cx
mov esi, dword [0x41d860]
mov eax, dword [ebp - 8]
add eax, esi
mov dword [0x41d864], eax
mov edi, 0x41d86c
mov bl, 0xa
cmp esi, eax
jae 0x412157
mov al, byte [esi]
cmp al, 0x20
je 0x412002
cmp al, 9
jne 0x412005
inc esi
jmp 0x411ff8
mov al, byte [esi]
cmp al, 0x3b
jne 0x412043
inc esi
cmp byte [esi], 0x20
jne 0x412012
inc esi
push esi
push 2
push dword [ebp - 0xc]
push edi
call fcn.00411dbd
add esp, 0x10
mov dword [ebp - 0xc], eax
jmp 0x412039
mov al, byte [esi]
cmp al, bl
je 0x4120f2
cmp al, 0xd
je 0x4120f2
inc esi
cmp byte [esi], 0
jne 0x412026
jmp 0x4120f2
cmp al, 0x5b
jne 0x41208b
inc esi
push esi
push 1
push dword [ebp - 0xc]
push edi
call fcn.00411dbd
add esp, 0x10
mov dword [ebp - 0xc], eax
jmp 0x41206b
mov al, byte [esi]
cmp al, 0x5d
je 0x412075
cmp al, bl
je 0x412070
cmp al, 0xd
je 0x412070
inc esi
cmp byte [esi], 0
jne 0x41205c
cmp byte [esi], 0x5d
jne 0x4120f2
mov byte [esi], 0
jmp 0x412082
cmp al, bl
je 0x4120f5
cmp al, 0xd
je 0x4120f6
inc esi
mov al, byte [esi]
test al, al
jne 0x41207a
jmp 0x4120f6
cmp al, bl
je 0x4120f6
cmp al, 0xd
je 0x4120f6
mov edx, esi
jmp 0x4120a6
cmp al, 0x3d
je 0x4120aa
cmp al, 0xd
je 0x4120aa
cmp al, bl
je 0x4120aa
inc esi
mov al, byte [esi]
test al, al
jne 0x412097
lea eax, [esi - 1]
jmp 0x4120bc
mov cl, byte [eax]
cmp cl, 0x20
je 0x4120bb
cmp cl, 9
jne 0x4120c0
dec eax
cmp eax, edx
ja 0x4120af
mov byte [eax + 1], 0
inc esi
mov al, byte [esi]
cmp al, 0x20
je 0x4120c4
cmp al, 9
je 0x4120c4
push esi
push edx
push dword [ebp - 0xc]
push edi
call fcn.00411dbd
add esp, 0x10
mov dword [ebp - 0xc], eax
jmp 0x4120ed
mov al, byte [esi]
cmp al, bl
je 0x4120f2
cmp al, 0xd
je 0x4120f2
inc esi
cmp byte [esi], 0
jne 0x4120e2
mov byte [esi], 0
inc esi
mov al, byte [esi]
cmp al, bl
je 0x4120f5
cmp al, 0xd
je 0x4120f5
cmp esi, dword [0x41d864]
jb 0x411ff8
jmp 0x412157
mov eax, dword [ebp + 0xc]
push dword [ebp + 8]
and dword [0x41d850], 0
mov dword [0x41d87c], eax
mov dword [0x41d868], 0xfde9
call sub.MSVCRT.dll_wcslen
pop ecx
lea eax, [eax + eax + 2]
push eax
push 0
push dword [0x41d3f4]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [0x41d854], eax
test eax, eax
je 0x412157
push dword [ebp + 8]
push eax
call sub.MSVCRT.dll_wcscpy
pop ecx
pop ecx
mov eax, dword [0x41d850]
pop edi
pop esi
pop ebx
leave
ret 8