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

Disassembly:
push 0x4fc
mov eax, 0x4924a6
call fcn.00486a2b
mov eax, dword [ebp + 8]
mov dword [ebp - 0x4d8], eax
mov eax, dword [ebp + 0xc]
xor ebx, ebx
push 0x3f
mov dword [ebp - 0x4d4], eax
lea eax, [ebp - 0x53]
push ebx
push eax
mov byte [ebp - 0x54], bl
call fcn.0048635c
mov esi, dword [0x4cdf04]
add esp, 0xc
cmp esi, ebx
jne 0x409954
push str.255.255.255.0
call dword [0x496994]
mov esi, eax
mov dword [0x4cdf04], esi
push 0x3ff
lea eax, [ebp - 0x4cb]
push ebx
push eax
mov byte [ebp - 0x4cc], bl
call fcn.0048635c
mov ecx, dword [ebp - 0x4d4]
mov edx, dword [ebp - 0x4d8]
xor eax, eax
lea edi, [ebp - 0xcc]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov al, byte [0x4f5e80]
add esp, 0xc
lea edi, [ebp - 0x4cc]
mov byte [ebp - 0x4cd], al
mov byte [ebp - 0xc0], bl
mov dword [ebp - 0xc4], esi
call fcn.00409678
movzx eax, byte [ebp - 0xc0]
imul eax, eax, 0x2e8
xor esi, esi
cmp word [ebp - 0xcc], 3
mov byte [eax + 0x4df208], 1
jbe 0x4099ef
movzx eax, word [ebp - 0xcc]
push eax
push 1
call dword [0x496660]
mov esi, eax
movzx eax, word [ebp - 0xcc]
push eax
mov eax, edi
push eax
push esi
call fcn.00486306
add esp, 0x14
mov cl, byte [ebp - 0x4cd]
jmp 0x409a25
movzx eax, cl
imul eax, eax, 0x1c
cmp dword [eax + 0x4de460], ebx
je 0x409a2a
mov dl, byte [ebp - 0xc0]
mov byte [eax + 0x4de45c], dl
mov edx, dword [ebp - 0xc4]
mov dword [eax + 0x4de46c], esi
mov dword [eax + 0x4de468], edx
inc cl
cmp cl, 0x7d
jb 0x4099f7
test cl, cl
mov byte [0x4f5e80], cl
mov byte [ebp - 0x4cd], bl
jbe 0x409ab3
xor esi, esi
imul esi, esi, 0x1c
cmp dword [esi + 0x4de468], ebx
jne 0x409a52
mov eax, dword [0x4cdf04]
mov dword [esi + 0x4de468], eax
mov edi, dword [esi + 0x4de460]
jmp 0x409a93
push edi
call dword [0x4969b0]
mov ecx, dword [esi + 0x4de468]
mov edx, eax
not edx
or edx, ecx
cmp edx, 0xffffffff
je 0x409a79
or ecx, eax
cmp ecx, 0xffffffff
jne 0x409a92
mov ecx, dword [esi + 0x4de470]
mov eax, edi
sub eax, dword [esi + 0x4de460]
mov dword [ecx + eax*8], 0x7fffffff
and dword [ecx + eax*8 + 4], ebx
inc edi
cmp edi, dword [esi + 0x4de464]
jbe 0x409a5a
inc byte [ebp - 0x4cd]
movsx esi, byte [ebp - 0x4cd]
movzx eax, byte [0x4f5e80]
cmp esi, eax
jl 0x409a3c
push 0x49c02c
push 0x4c5610
call dword [0x4964fc]
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x4d4], eax
je 0x409f28
jmp 0x409d85
cmp byte [ebp - 0xba], 0x10
ja 0x409d85
push dword [ebp - 0xb4]
mov edx, 0x4cbeec
push 0x7d
call fcn.0040a1ea
test eax, eax
pop ecx
pop ecx
jne 0x409d85
lea eax, [ebp - 0x54]
push eax
mov al, byte [ebp - 0xba]
lea ecx, [ebp - 0xa4]
call fcn.0040a26a
mov eax, dword [0x4f7360]
mov eax, dword [eax]
mov dword [ebp - 0x4d8], eax
mov eax, 0x4f735c
pop ecx
mov dword [ebp - 0x4dc], eax
mov dword [ebp - 0x4ec], eax
mov eax, dword [0x4f7360]
lea edi, [ebp - 0x4ec]
lea esi, [ebp - 0x4dc]
mov dword [ebp - 0x4e8], eax
call fcn.00420b6a
test al, al
jne 0x409ba7
mov edi, dword [ebp - 0x4dc]
test edi, edi
jne 0x409b65
call dword [0x49652c]
mov esi, dword [ebp - 0x4d8]
cmp esi, dword [edi + 4]
jne 0x409b76
call dword [0x49652c]
mov ebx, dword [esi + 0x28]
test ebx, ebx
je 0x409b9a
push dword [ebx]
lea eax, [ebp - 0x54]
push eax
call dword [0x49655c]
test eax, eax
pop ecx
pop ecx
je 0x409ba7
mov eax, dword [ebx + 0x18]
cmp eax, dword [ebp - 0xb4]
je 0x409ba7
lea esi, [ebp - 0x4dc]
call fcn.00478026
jmp 0x409b35
mov eax, dword [0x4f7360]
lea edi, [ebp - 0x4e4]
lea esi, [ebp - 0x4dc]
mov dword [ebp - 0x4e0], eax
mov dword [ebp - 0x4e4], 0x4f735c
call fcn.00420b6a
test al, al
jne 0x409bf6
push dword [ebx]
lea eax, [ebp - 0x54]
push eax
call dword [0x49655c]
test eax, eax
pop ecx
pop ecx
jne 0x409d85
mov eax, dword [ebx + 0x18]
cmp eax, dword [ebp - 0xb4]
jne 0x409d85
lea ecx, [ebp - 0x54]
call fcn.0040a7b8
push dword [ebp - 0xb4]
mov ebx, eax
call fcn.004095eb
test ebx, ebx
pop ecx
mov byte [ebp - 0x4cd], al
jne 0x409c4b
test al, al
jl 0x409c43
push 0x24
push ebx
mov esi, 0x4c53d4
push esi
call fcn.0048635c
lea eax, [ebp - 0x54]
mov dword [0x4c53d4], eax
add esp, 0xc
mov eax, esi
mov byte [0x4c53f4], 1
call fcn.0040be9e
mov ebx, eax
test ebx, ebx
je 0x409d85
push dword [ebx]
lea ecx, [ebp - 0x508]
call dword [0x496380]
and dword [ebp - 4], 0
lea eax, [ebp - 0x508]
push eax
call fcn.0040c457
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x508]
mov dword [eax], ebx
call dword [0x496384]
mov eax, dword [ebp - 0xb4]
mov ecx, dword [ebx + 0x10]
mov dword [ebx + 0x18], eax
mov al, byte [ebp - 0x4cd]
mov byte [ebx + 0x14], al
mov eax, dword [ebp - 0xac]
mov dword [ebx + 8], eax
mov eax, dword [ebp - 0xa8]
mov dword [ebx + 0xc], eax
movzx eax, byte [ebp - 0xb9]
and eax, 1
or eax, 2
add eax, eax
and ecx, 0xfffffffd
or eax, ecx
mov dword [ebx + 0x10], eax
cmp byte [ebp - 0x94], 0
je 0x409cd2
lea eax, [ebp - 0x94]
push eax
call fcn.0040a9a1
pop ecx
mov dword [ebx + 0x20], eax
mov eax, dword [ebx + 0x18]
test eax, eax
je 0x409d23
push eax
movzx eax, byte [ebx + 0x14]
push eax
call fcn.0040962f
test eax, eax
pop ecx
pop ecx
jl 0x409d23
movsx ecx, byte [ebx + 0x14]
imul ecx, ecx, 0x1c
mov ecx, dword [ecx + 0x4de470]
lea ecx, [ecx + eax*8]
cmp dword [ecx], 0x7fffffff
jne 0x409d08
cmp dword [ecx + 4], 0
je 0x409d13
mov edx, dword [ebx + 8]
mov dword [ecx], edx
mov edx, dword [ebx + 0xc]
mov dword [ecx + 4], edx
movsx ecx, byte [ebx + 0x14]
imul ecx, ecx, 0x1c
mov ecx, dword [ecx + 0x4de474]
mov dword [ecx + eax*4], ebx
cmp byte [ebp - 0x94], 0
je 0x409d85
cmp byte [0x4f5e85], 2
je 0x409d85
mov eax, dword [ebp - 0xa8]
cmp eax, dword [0x4f7384]
jl 0x409d85
jg 0x409d53
mov eax, dword [ebp - 0xac]
cmp eax, dword [0x4f7380]
jbe 0x409d85
mov edi, dword [ebx + 0x18]
call fcn.0040a57b
test al, al
lea eax, [ebp - 0x94]
je 0x409d69
push 3
jmp 0x409d6b
push 4
push dword [ebp - 0xa8]
push dword [ebp - 0xac]
push dword [ebx + 0x18]
push eax
push 0
call fcn.00407445
add esp, 0x18
push dword [ebp - 0x4d4]
lea eax, [ebp - 0xbc]
push 1
push 0x68
push eax
call dword [0x496500]
add esp, 0x10
test eax, eax
jne 0x409ad8
push dword [ebp - 0x4d4]
call dword [0x496504]
mov dword [esp], 0x49c030
push 0x4c5610
call dword [0x4964fc]
and word [0x4f5d60], 0
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x4d4], eax
je 0x409f28
mov eax, dword [0x4f7360]
mov ebx, dword [eax]
mov eax, 0x4f735c
mov dword [ebp - 0x4d8], ebx
mov dword [ebp - 0x4dc], eax
mov dword [ebp - 0x4e4], eax
mov eax, dword [0x4f7360]
lea edi, [ebp - 0x4e4]
lea esi, [ebp - 0x4dc]
mov dword [ebp - 0x4e0], eax
call fcn.00420b6a
test al, al
jne 0x409f1b
mov esi, dword [ebp - 0x4dc]
test esi, esi
jne 0x409e2f
call dword [0x49652c]
cmp ebx, dword [esi + 4]
jne 0x409e3a
call dword [0x49652c]
mov esi, dword [ebx + 0x28]
test esi, esi
je 0x409f05
mov eax, dword [esi + 0xc]
cmp eax, dword [0x4f7384]
jg 0x409e67
jl 0x409e5d
mov eax, dword [esi + 8]
cmp eax, dword [0x4f7380]
ja 0x409e67
test byte [esi + 0x10], 1
jne 0x409f05
push 0x68
lea eax, [ebp - 0xbc]
push 0
push eax
call fcn.0048635c
mov byte [ebp - 0xba], 0x10
mov eax, dword [esi]
add esp, 0xc
lea ebx, [ebp - 0xba]
lea ecx, [ebp - 0xa4]
call fcn.0040a414
mov eax, dword [esi + 0x18]
mov dword [ebp - 0xb4], eax
mov eax, dword [esi + 8]
mov dword [ebp - 0xac], eax
mov eax, dword [esi + 0xc]
mov dword [ebp - 0xa8], eax
mov eax, dword [esi + 0x10]
shr eax, 1
and al, 1
mov byte [ebp - 0xb9], al
mov eax, dword [esi + 0x20]
test eax, eax
je 0x409ed2
push eax
lea eax, [ebp - 0x94]
push eax
call fcn.0040d763
pop ecx
pop ecx
mov ax, word [0x4f5d60]
push dword [ebp - 0x4d4]
inc ax
mov word [0x4f5d60], ax
mov word [ebp - 0xbc], ax
push 1
mov word [esi + 0x16], ax
lea eax, [ebp - 0xbc]
push 0x68
push eax
call dword [0x496508]
add esp, 0x10
lea esi, [ebp - 0x4dc]
call fcn.00478026
mov ebx, dword [ebp - 0x4d8]
jmp 0x409dfb
push dword [ebp - 0x4d4]
call dword [0x496504]
pop ecx
xor eax, eax
call fcn.00486aae
ret