Function at 0x42582c
Capabilities:
Resolve function by parsing pe exports
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x491e00
mov eax, dword fs:[0]
push eax
sub esp, 0x60
mov eax, dword [0x4bea34]
xor eax, esp
mov dword [esp + 0x58], eax
push ebx
push esi
push edi
mov eax, dword [0x4bea34]
xor eax, esp
push eax
lea eax, [esp + 0x70]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
cmp si, 0xffff
mov edi, ecx
mov dword [esp + 0x28], edi
jne 0x425896
xor ax, ax
mov ecx, dword [esp + 0x70]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x58]
xor ecx, esp
call fcn.00470af5
mov esp, ebp
pop ebp
ret 4
mov eax, dword [edi + 0x24]
mov ecx, dword [eax]
test ecx, ecx
je 0x4258bf
mov eax, dword [edi + 0x34]
mov edx, dword [eax]
lea edx, [ecx + edx*2]
cmp ecx, edx
jae 0x4258bf
dec dword [eax]
mov edi, dword [edi + 0x24]
mov eax, dword [edi]
lea ecx, [eax + 2]
mov dword [edi], ecx
mov word [eax], si
mov ax, si
jmp 0x425876
mov eax, dword [edi + 0x4c]
test eax, eax
jne 0x4258cc
or ax, 0xffff
jmp 0x425876
cmp dword [edi + 0x3c], 0
jne 0x4258eb
push eax
push esi
call fcn.00475a5d
pop ecx
cmp ax, 0xffff
pop ecx
movzx eax, si
jne 0x425876
mov eax, 0xffff
jmp 0x425876
movzx eax, si
lea esi, [esp + 0x4c]
mov dword [esp + 0x14], eax
call fcn.00426035
and dword [esp + 0x78], 0
mov eax, dword [esp + 0x60]
mov dword [esp + 0x18], eax
lea eax, [esp + 0x34]
mov ecx, esi
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
mov ebx, eax
add ebx, dword [esp + 0x18]
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x4c]
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
mov ecx, dword [edi + 0x3c]
lea esi, [esp + 0x1c]
push esi
push ebx
mov dword [esp + 0x20], eax
push dword [esp + 0x20]
mov eax, dword [ecx]
lea esi, [esp + 0x2c]
push esi
lea esi, [esp + 0x26]
push esi
lea edx, [edi + 0x44]
lea esi, [esp + 0x28]
push esi
push edx
mov dword [esp + 0x40], edx
call dword [eax + 0x14]
jmp 0x425a3d
cmp eax, 1
jg 0x425a5c
lea eax, [esp + 0x3c]
lea ecx, [esp + 0x4c]
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
mov ebx, dword [esp + 0x1c]
sub ebx, eax
je 0x4259b6
push dword [edi + 0x4c]
lea eax, [esp + 0x48]
push ebx
push 1
lea ecx, [esp + 0x58]
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
push eax
call fcn.00474ed4
add esp, 0x10
cmp ebx, eax
jne 0x425a45
lea eax, [esp + 0x14]
cmp dword [esp + 0x20], eax
mov byte [edi + 0x42], 1
jne 0x425a7f
test ebx, ebx
ja 0x4259e5
cmp dword [esp + 0x60], 0x20
jae 0x425a45
push 0
push 8
pop ebx
lea edi, [esp + 0x50]
call fcn.0041c34b
mov edi, dword [esp + 0x28]
mov eax, dword [esp + 0x60]
mov dword [esp + 0x18], eax
lea eax, [esp + 0x34]
lea ecx, [esp + 0x4c]
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
mov ebx, eax
add ebx, dword [esp + 0x18]
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x4c]
call fcn.004188bf
mov esi, eax
call fcn.00418f2c
mov ecx, dword [edi + 0x3c]
mov edx, dword [ecx]
lea esi, [esp + 0x1c]
push esi
push ebx
push eax
lea eax, [esp + 0x2c]
push eax
lea eax, [esp + 0x26]
push eax
lea eax, [esp + 0x28]
push eax
push dword [esp + 0x3c]
call dword [edx + 0x14]
test eax, eax
jge 0x425966
or si, 0xffff
push 0
push 1
lea ecx, [esp + 0x54]
call fcn.00401e14
jmp 0x4258ba
cmp eax, 3
jne 0x425a45
push dword [edi + 0x4c]
push dword [esp + 0x18]
call fcn.00475a5d
mov esi, 0xffff
cmp ax, si
pop ecx
pop ecx
je 0x425a4a
movzx esi, word [ebp + 8]
jmp 0x425a4a
mov si, word [ebp + 8]
jmp 0x425a4a