Function at 0x408818
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push 0x3bc
mov eax, 0x4a0d1a
call fcn.0047be69
mov esi, ecx
mov dword [ebp - 0x3bc], esi
xor ebx, ebx
mov dword [ebp - 0x3bc], esi
push 7
pop ecx
xor eax, eax
mov dword [ebp - 0x310], ebx
mov dword [ebp - 0x300], ebx
mov dword [ebp - 0x2fc], ecx
mov word [ebp - 0x310], ax
mov dword [ebp - 4], ebx
mov dword [ebp - 0x2e4], ecx
lea ecx, [ebp - 0x2f8]
mov dword [ebp - 0x2f8], ebx
push 0x4c1ae0
mov dword [ebp - 0x2e8], ebx
mov word [ebp - 0x2f8], ax
call fcn.00401fb3
lea eax, [ebp - 0x2f8]
mov byte [ebp - 4], 1
push eax
push 0x80000001
lea ecx, [ebp - 0x39c]
call fcn.00477e40
lea ecx, [ebp - 0x2f8]
mov byte [ebp - 4], 3
call fcn.00402806
push ebx
push 0xf003f
lea ecx, [ebp - 0x39c]
call fcn.004780e0
test eax, eax
jne 0x4088e2
lea eax, [ebp - 0x310]
push eax
push 0x4c1b1c
lea ecx, [ebp - 0x39c]
call fcn.00478000
lea ecx, [ebp - 0x39c]
call fcn.00477fb0
lea ecx, [ebp - 0x39c]
mov byte [ebp - 4], bl
call fcn.00477f00
cmp dword [ebp - 0x300], 0
jbe 0x40891b
lea ecx, [ebp - 0x310]
call fcn.00408e76
test al, al
je 0x40891b
lea eax, [ebp - 0x310]
mov ecx, esi
push eax
call fcn.004036eb
jmp 0x408e5d
push 0x208
lea eax, [ebp - 0x218]
push ebx
push eax
call fcn.0047de30
add esp, 0xc
lea eax, [ebp - 0x218]
push ebx
push 0x1a
push eax
push ebx
call dword [0x4a937c]
lea eax, [ebp - 0x218]
push eax
call dword [0x4a9394]
push 0x4c1b28
lea eax, [ebp - 0x218]
push eax
push eax
call dword [0x4a93a0]
push 0x4c1b34
lea eax, [ebp - 0x218]
mov dword [ebp - 0x3b8], ebx
push eax
lea eax, [ebp - 0x3b8]
push eax
call fcn.00483d26
add esp, 0xc
cmp dword [ebp - 0x3b8], 0
je 0x408a96
push 2
push ebx
push dword [ebp - 0x3b8]
call fcn.0048405b
add esp, 0xc
push dword [ebp - 0x3b8]
call fcn.004846f9
pop ecx
push 0
push 0
push dword [ebp - 0x3b8]
mov ebx, eax
call fcn.0048405b
add esp, 0xc
lea eax, [ebx + 1]
push eax
call fcn.00484704
mov edi, eax
pop ecx
test edi, edi
jne 0x4089e2
push dword [ebp - 0x3b8]
call fcn.00484786
xor ebx, ebx
jmp 0x408a95
lea eax, [ebx + 1]
push eax
push 0
push edi
call fcn.0047de30
add esp, 0xc
push dword [ebp - 0x3b8]
push ebx
push 1
push edi
call fcn.004849f0
add esp, 0x10
cmp eax, ebx
jne 0x408a81
xor ebx, ebx
mov dword [ebp - 0x2e4], 0xf
mov dword [ebp - 0x2f8], ebx
lea ecx, [ebp - 0x2f8]
push edi
mov dword [ebp - 0x2e8], ebx
mov byte [ebp - 0x2f8], bl
call fcn.00406df8
lea eax, [ebp - 0x2f8]
mov byte [ebp - 4], 4
push eax
lea eax, [ebp - 0x368]
push eax
call fcn.004782e0
pop ecx
pop ecx
lea ecx, [ebp - 0x310]
cmp ecx, eax
je 0x408a66
mov byte [ebp - 0x3bc], bl
push dword [ebp - 0x3bc]
push eax
call fcn.00402042
lea ecx, [ebp - 0x368]
call fcn.00402806
lea ecx, [ebp - 0x2f8]
mov byte [ebp - 4], bl
call fcn.00402889
jmp 0x408a83
xor ebx, ebx
push edi
call fcn.00483b93
pop ecx
push dword [ebp - 0x3b8]
call fcn.00484786
pop ecx
cmp dword [ebp - 0x300], 0
jbe 0x408ab2
lea ecx, [ebp - 0x310]
call fcn.00408e76
test al, al
jne 0x408908
lea eax, [ebp - 0x3c8]
push eax
call dword [0x4a9320]
mov ecx, dword [ebp - 0x3c8]
mov eax, dword [ebp - 0x3c4]
sub ecx, 0xd53e8000
push ebx
push 0xa
sbb eax, 0x19db1de
push eax
push ecx
call fcn.0049ee10
push edx
push eax
lea ecx, [ebp - 0x350]
call fcn.00411538
pop ecx
pop ecx
push 0x14
pop edi
mov byte [ebp - 4], 5
cmp dword [ebp - 0x340], edi
jae 0x408b1d
sub edi, dword [ebp - 0x340]
je 0x408b1d
push 1
push 0x4c1b3c
lea ecx, [ebp - 0x350]
call fcn.0040ee19
sub edi, 1
jne 0x408b06
lea edx, [ebp - 0x350]
lea ecx, [ebp - 0x3b4]
call fcn.00408724
push 0xc8
lea eax, [ebp - 0x2e0]
mov byte [ebp - 4], 6
push ebx
push eax
call fcn.0047de30
add esp, 0xc
lea eax, [ebp - 0x320]
push eax
call dword [0x4a9620]
test eax, eax
jne 0x408bc6
movzx eax, byte [ebp - 0x311]
push eax
movzx eax, byte [ebp - 0x312]
push eax
movzx eax, byte [ebp - 0x313]
push eax
movzx eax, byte [ebp - 0x314]
push eax
movzx eax, byte [ebp - 0x315]
push eax
movzx eax, byte [ebp - 0x316]
push eax
movzx eax, byte [ebp - 0x317]
push eax
movzx eax, byte [ebp - 0x318]
push eax
movzx eax, word [ebp - 0x31a]
push eax
movzx eax, word [ebp - 0x31c]
push eax
push dword [ebp - 0x320]
lea eax, [ebp - 0x2e0]
push 0x4c1b40
push 0x64
push eax
call fcn.0040420e
add esp, 0x38
jmp 0x408bd6
push 0x10
pop ecx
mov eax, 0x300030
lea edi, [ebp - 0x2e0]
rep stosd dword es:[edi], eax
xor eax, eax
mov dword [ebp - 0x338], ebx
mov word [ebp - 0x338], ax
lea ecx, [ebp - 0x338]
lea eax, [ebp - 0x2e0]
mov dword [ebp - 0x328], ebx
push eax
mov dword [ebp - 0x324], 7
call fcn.00401fb3
mov byte [ebp - 4], 7
mov eax, 0x7ffffffe
sub eax, dword [ebp - 0x328]
cmp eax, dword [ebp - 0x340]
jb 0x408e70
cmp dword [ebp - 0x324], 8
lea ecx, [ebp - 0x338]
push dword [ebp - 0x340]
cmovae ecx, dword [ebp - 0x338]
lea eax, [ebp - 0x350]
cmp dword [ebp - 0x33c], 8
cmovae eax, dword [ebp - 0x350]
push eax
push dword [ebp - 0x328]
lea eax, [ebp - 0x338]
push ecx
push eax
push dword [ebp - 0x3bc]
lea ecx, [ebp - 0x368]
call fcn.00402215
lea eax, [ebp - 0x3b4]
mov byte [ebp - 4], 8
push eax
lea ecx, [ebp - 0x368]
call fcn.0040ec3d
push eax
lea ecx, [ebp - 0x2f8]
call fcn.004036eb
mov byte [ebp - 0x3bc], bl
lea eax, [ebp - 0x2f8]
push dword [ebp - 0x3bc]
lea ecx, [ebp - 0x310]
push eax
call fcn.00402042
lea ecx, [ebp - 0x2f8]
call fcn.00402806
lea ecx, [ebp - 0x368]
mov byte [ebp - 4], 7
call fcn.00402806
xor eax, eax
mov dword [ebp - 0x2f8], ebx
push 0x4c1ae0
lea ecx, [ebp - 0x2f8]
mov dword [ebp - 0x2e8], ebx
mov dword [ebp - 0x2e4], 7
mov word [ebp - 0x2f8], ax
call fcn.00401fb3
lea eax, [ebp - 0x2f8]
mov byte [ebp - 4], 9
push eax
push 0x80000001
lea ecx, [ebp - 0x39c]
call fcn.00477e40
lea ecx, [ebp - 0x2f8]
mov byte [ebp - 4], 0xb
call fcn.00402806
push 1
push 0xf003f
lea ecx, [ebp - 0x39c]
call fcn.004780e0
test eax, eax
jne 0x408d5b
lea eax, [ebp - 0x310]
push eax
push 0x4c1b1c
lea ecx, [ebp - 0x39c]
call fcn.00478180
lea ecx, [ebp - 0x39c]
call fcn.00477fb0
lea ecx, [ebp - 0x39c]
mov byte [ebp - 4], 7
call fcn.00477f00
push 0x208
lea eax, [ebp - 0x218]
push ebx
push eax
call fcn.0047de30
add esp, 0xc
lea eax, [ebp - 0x218]
push ebx
push 0x1a
push eax
push ebx
call dword [0x4a937c]
lea eax, [ebp - 0x218]
push eax
call dword [0x4a9394]
push 0x4c1b28
lea eax, [ebp - 0x218]
push eax
push eax
call dword [0x4a93a0]
push 0x4c1b9c
lea eax, [ebp - 0x218]
mov dword [ebp - 0x3b8], ebx
push eax
lea eax, [ebp - 0x3b8]
push eax
call fcn.00483d26
add esp, 0xc
cmp dword [ebp - 0x3b8], 0
je 0x408e2e
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x2f8]
push eax
call fcn.004781b0
push dword [ebp - 0x3b8]
cmp dword [ebp - 0x2e4], 0x10
lea eax, [ebp - 0x2f8]
push dword [ebp - 0x2e8]
cmovae eax, dword [ebp - 0x2f8]
push 1
push eax
call fcn.00484d4a
push dword [ebp - 0x3b8]
call fcn.00484786
add esp, 0x1c
lea ecx, [ebp - 0x2f8]
call fcn.00402889
lea eax, [ebp - 0x310]
mov ecx, esi
push eax
call fcn.004036eb
lea ecx, [ebp - 0x338]
call fcn.00402806
lea ecx, [ebp - 0x3b4]
call fcn.00402806
lea ecx, [ebp - 0x350]
call fcn.00402806
lea ecx, [ebp - 0x310]
call fcn.00402806
mov eax, esi
call fcn.0047be18
ret
call fcn.004026b2
int3