Function at 0x10014400
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1003390d
mov eax, dword fs:[0]
push eax
sub esp, 0x2c
mov eax, dword [0x10045014]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov ebx, dword [ebp + 8]
test ebx, ebx
jne 0x10014463
cmp byte [edi + 0x40], bl
jne 0x100145f7
mov edx, dword [str.Failed_to_open_file]
mov ecx, edx
mov byte [edi + 0x40], 1
mov dword [edi + 0x44], 2
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10014453
jmp 0x100145db
mov esi, dword [edi + 0x18]
test esi, esi
je 0x1001447f
nop word [eax + eax]
mov ecx, esi
mov esi, dword [esi + 0x3c]
push 1
mov eax, dword [ecx]
call dword [eax]
test esi, esi
jne 0x10014470
push 2
push 0
push ebx
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 8], 0xffffffff
mov dword [edi + 4], 0xffffffff
call fcn.10021df5
push ebx
call fcn.100215d7
push 0
mov esi, eax
push 0
push ebx
mov dword [ebp - 0x34], esi
call fcn.10021df5
add esp, 0x1c
test esi, esi
jg 0x100144f1
cmp byte [edi + 0x40], 0
jne 0x100145f7
mov edx, dword [str.Error_document_empty.]
mov ecx, edx
mov byte [edi + 0x40], 1
mov dword [edi + 0x44], 0xd
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100144e1
jmp 0x100145db
lea eax, [esi + 0xa]
push eax
mov dword [ebp - 0x30], eax
call fcn.1001ea64
mov esi, eax
add esp, 4
mov dword [ebp - 0x2c], esi
test esi, esi
jne 0x10014540
cmp byte [edi + 0x40], al
jne 0x100145f7
mov edx, dword [str.Memory_allocation_failed.]
mov ecx, edx
mov byte [edi + 0x40], 1
mov dword [edi + 0x44], 3
lea esi, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10014530
jmp 0x100145db
push dword [ebp - 0x30]
push 0
push esi
call fcn.1001b040
push ebx
push dword [ebp - 0x34]
push 1
push esi
call fcn.1002203c
movzx edx, word [esi]
mov eax, 0xfffe
add esp, 0x1c
cmp dx, ax
jne 0x1001458c
mov ecx, esi
nop dword [eax]
test dl, dl
jne 0x1001457d
cmp byte [ecx + 1], dl
je 0x10014691
mov al, byte [ecx + 1]
mov byte [ecx], al
mov byte [ecx + 1], dl
add ecx, 2
mov dl, byte [ecx]
jmp 0x10014570
mov eax, 0xfeff
cmp dx, ax
je 0x10014691
mov eax, dword [ebp - 0x30]
add eax, eax
push eax
mov dword [ebp - 0x30], eax
call fcn.1001ea64
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x100145fe
cmp byte [edi + 0x40], al
jne 0x100145f7
mov edx, dword [str.Memory_allocation_failed.]
mov ecx, edx
mov byte [edi + 0x40], 1
mov dword [edi + 0x44], 3
lea esi, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100145d0
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [edi + 0x48]
call fcn.10002cf0
mov dword [edi + 0x64], 0xffffffff
mov dword [edi + 0x68], 0xffffffff
xor al, al
jmp 0x100147b9
push dword [ebp - 0x30]
push 0
push ebx
call fcn.1001b040
mov eax, dword [ebp - 0x34]
add esp, 0xc
inc eax
push eax
push ebx
push 0xffffffffffffffff
push esi
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jg 0x10014683
cmp byte [edi + 0x40], 0
jne 0x1001466d
mov edx, dword [str.Failed_to_open_file]
mov ecx, edx
mov byte [edi + 0x40], 1
mov dword [edi + 0x44], 2
lea eax, [ecx + 2]
mov dword [ebp - 0x34], eax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10014645
sub ecx, dword [ebp - 0x34]
sar ecx, 1
push ecx
push edx
lea ecx, [edi + 0x48]
call fcn.10002cf0
mov dword [edi + 0x68], 0xffffffff
mov dword [edi + 0x64], 0xffffffff
push esi
call fcn.1001c5f3
push ebx
call fcn.1001c5f3
add esp, 8
xor al, al
jmp 0x100147b9
push esi
call fcn.1001c5f3
add esp, 4
mov dword [ebp - 0x2c], ebx
mov esi, ebx
mov ecx, dword [ebp - 0x2c]
mov ebx, esi
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100146a0
sub ecx, edx
mov dword [ebp - 0x28], 0
xor eax, eax
sar ecx, 1
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
push ecx
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], eax
call fcn.10015330
mov eax, dword [ebp - 0x2c]
movzx eax, word [eax]
test ax, ax
je 0x10014746
mov ecx, eax
cmp cx, 0xa
jne 0x10014701
mov eax, esi
lea ecx, [ebp - 0x28]
sub eax, ebx
sar eax, 1
inc eax
push eax
push ebx
call fcn.10002e00
add esi, 2
mov ebx, esi
jmp 0x1001473c
cmp cx, 0xd
jne 0x10014739
mov eax, esi
sub eax, ebx
sar eax, 1
test eax, eax
jle 0x1001471b
push eax
push ebx
lea ecx, [ebp - 0x28]
call fcn.10002e00
push 0xa
lea ecx, [ebp - 0x28]
call fcn.10006980
xor eax, eax
cmp word [esi + 2], 0xa
sete al
lea esi, [esi + eax*2]
add esi, 2
mov ebx, esi
jmp 0x1001473c
add esi, 2
movzx eax, word [esi]
mov ecx, eax
test ax, ax
jne 0x100146e3
sub esi, ebx
sar esi, 1
je 0x10014756
push esi
push ebx
lea ecx, [ebp - 0x28]
call fcn.10002e00
push dword [ebp - 0x2c]
call fcn.1001c5f3
mov eax, dword [edi]
add esp, 4
cmp dword [ebp - 0x14], 8
mov ecx, edi
mov edx, dword [eax + 8]
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push 0
push 0
push eax
call edx
cmp byte [edi + 0x40], 0
mov edx, dword [ebp - 0x14]
sete bl
cmp edx, 8
jb 0x100147b7
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x100147ad
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100147d7
push edx
push ecx
call fcn.10019349
add esp, 8
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10019013
mov esp, ebp
pop ebp
ret 8
call fcn.1001c7ca
int3