Function at 0x409180
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x8c
cmp dword [esp + 0xb0], 0x5cf
mov dword [esp + 0x78], 0
mov dword [esp + 0x7c], 0
mov dword [esp + 0x64], 0xffffffd4
jbe 0x409220
mov eax, dword [esp + 0xb4]
mov dword [esp + 0x20], 0x368
mov dword [esp + 4], 0x100
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0xac]
add eax, 0x68
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0xa8]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0xa4]
mov dword [esp + 0x14], eax
lea eax, [esp + 0x78]
mov dword [esp + 0x10], eax
lea eax, [esp + 0x7c]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xac]
lea esi, [eax + 0x4d0]
mov dword [esp + 8], eax
mov dword [esp], esi
call fcn.00401790
mov dword [esp + 0x64], eax
cmp eax, 0xffffff88
jbe 0x409230
mov eax, dword [esp + 0x64]
add esp, 0x8c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0xa0]
mov edx, dword [esp + 0x7c]
mov ebx, dword [esp + 0x78]
mov eax, dword [eax]
mov dword [esp + 0x3c], edx
mov dword [esp + 0x40], eax
movzx eax, al
lea edi, [eax + 1]
mov eax, 0xb
cmp edi, eax
cmovbe eax, edi
mov ebp, eax
cmp ebx, eax
ja 0x409928
jae 0x40937e
mov ecx, eax
mov eax, esi
mov esi, dword [esp + 0xac]
sub ecx, ebx
lea esi, [esi + edx + 0x4d0]
test edx, edx
je 0x40929f
lea esi, [esi]
movzx edx, byte [eax]
test dl, dl
je 0x409918
add edx, ecx
add eax, 1
mov byte [eax - 1], dl
cmp eax, esi
jne 0x409288
cmp ebp, ecx
jbe 0x409359
mov eax, dword [esp + 0xac]
mov edx, dword [esp + 0xac]
mov esi, ebx
sub esi, ebp
mov eax, dword [eax + ebx*4]
mov dword [esp + 0x44], esi
mov dword [edx + ebp*4], eax
lea eax, [ebp - 1]
cmp ecx, eax
jae 0x409359
mov esi, edx
mov edx, dword [edx + ebx*4 - 4]
mov dword [esi + eax*4], edx
lea eax, [ebp - 2]
cmp eax, ecx
jbe 0x409359
mov edx, dword [esi + ebx*4 - 8]
mov dword [esi + eax*4], edx
lea eax, [ebp - 3]
cmp eax, ecx
jbe 0x409359
mov edx, dword [esi + ebx*4 - 0xc]
mov dword [esi + eax*4], edx
lea eax, [ebp - 4]
cmp eax, ecx
jbe 0x409359
mov edx, dword [esi + ebx*4 - 0x10]
mov dword [esi + eax*4], edx
lea eax, [ebp - 5]
cmp eax, ecx
jbe 0x409359
mov edx, dword [esi + ebx*4 - 0x14]
mov dword [esi + eax*4], edx
lea eax, [ebp - 6]
cmp ecx, eax
jae 0x409359
mov edx, dword [esi + ebx*4 - 0x18]
mov dword [esi + eax*4], edx
lea eax, [ebp - 7]
cmp ecx, eax
jae 0x409359
mov edx, dword [esi + ebx*4 - 0x1c]
mov dword [esi + eax*4], edx
lea eax, [ebp - 8]
cmp ecx, eax
jae 0x409359
mov edx, dword [esi + ebx*4 - 0x20]
mov dword [esi + eax*4], edx
lea eax, [ebp - 9]
cmp ecx, eax
jae 0x409359
mov edx, dword [esi + ebx*4 - 0x24]
mov dword [esi + eax*4], edx
lea eax, [ebp - 0xa]
cmp ecx, eax
jae 0x409359
mov edx, dword [esp + 0x44]
mov eax, dword [esi + edx*4 + 4]
mov dword [esi + 4], eax
test ecx, ecx
je 0x40937e
mov eax, dword [esp + 0xac]
shl ecx, 2
mov dword [esp + 4], 0
mov dword [esp + 8], ecx
add eax, 4
mov dword [esp], eax
call sub.cygwin1.dll_memset
mov dword [esp + 0x78], ebp
cmp edi, ebp
jb 0x40992f
mov eax, ebp
mov edx, dword [esp + 0x40]
mov byte [esp + 0x44], al
movzx eax, al
shl eax, 0x10
and edx, 0xff0000ff
or edx, eax
mov eax, dword [esp + 0xa0]
mov dword [eax], edx
mov eax, dword [esp + 0x3c]
lea ecx, [eax - 3]
mov eax, dword [esp + 0xac]
mov edi, dword [eax]
mov dword [eax + 0x34], 0
mov edx, eax
mov eax, dword [eax + 4]
mov dword [edx + 0x38], edi
add eax, edi
cmp ebp, 1
je 0x40945c
mov ebx, edx
mov edx, dword [edx + 8]
mov dword [ebx + 0x3c], eax
add edx, eax
cmp ebp, 2
je 0x40945c
mov eax, dword [ebx + 0xc]
mov dword [ebx + 0x40], edx
add eax, edx
cmp ebp, 3
je 0x40945c
mov edx, dword [ebx + 0x10]
mov dword [ebx + 0x44], eax
add edx, eax
cmp ebp, 4
je 0x40945c
mov eax, dword [ebx + 0x14]
mov dword [ebx + 0x48], edx
add eax, edx
cmp ebp, 5
je 0x40945c
mov edx, dword [ebx + 0x18]
mov dword [ebx + 0x4c], eax
add edx, eax
cmp ebp, 6
je 0x40945c
mov eax, dword [ebx + 0x1c]
mov dword [ebx + 0x50], edx
add eax, edx
cmp ebp, 7
je 0x40945c
mov edx, dword [ebx + 0x20]
mov dword [ebx + 0x54], eax
add edx, eax
cmp ebp, 8
je 0x40945c
mov eax, dword [ebx + 0x24]
mov dword [ebx + 0x58], edx
add eax, edx
cmp ebp, 9
je 0x40945c
mov edx, dword [ebx + 0x28]
mov dword [ebx + 0x5c], eax
add edx, eax
cmp ebp, 0xa
je 0x40945c
mov eax, dword [ebx + 0x2c]
mov dword [ebx + 0x60], edx
add eax, edx
cmp ebp, 0xb
je 0x40945c
mov dword [ebx + 0x64], eax
xor eax, eax
test ecx, ecx
jle 0x409515
mov dword [esp + 0x40], ebp
mov edx, dword [esp + 0xac]
lea esi, [esi]
movzx ebx, byte [edx + eax + 0x4d0]
add ebx, 0xc
mov esi, dword [edx + ebx*4 + 4]
lea ebp, [esi + 1]
mov dword [edx + ebx*4 + 4], ebp
mov byte [edx + esi + 0x3d0], al
movzx ebx, byte [edx + eax + 0x4d1]
add ebx, 0xc
mov esi, dword [edx + ebx*4 + 4]
lea ebp, [esi + 1]
mov dword [edx + ebx*4 + 4], ebp
lea ebx, [eax + 1]
mov byte [edx + esi + 0x3d0], bl
movzx ebx, byte [edx + eax + 0x4d2]
add ebx, 0xc
mov esi, dword [edx + ebx*4 + 4]
lea ebp, [esi + 1]
mov dword [edx + ebx*4 + 4], ebp
lea ebx, [eax + 2]
mov byte [edx + esi + 0x3d0], bl
movzx ebx, byte [edx + eax + 0x4d3]
add ebx, 0xc
mov esi, dword [edx + ebx*4 + 4]
lea ebp, [esi + 1]
mov dword [edx + ebx*4 + 4], ebp
lea ebx, [eax + 3]
add eax, 4
mov byte [edx + esi + 0x3d0], bl
cmp ecx, eax
jg 0x409478
mov eax, dword [esp + 0x3c]
mov ebp, dword [esp + 0x40]
sub eax, 4
shr eax, 2
lea eax, [eax*4 + 4]
cmp dword [esp + 0x3c], eax
jle 0x4095d9
mov ecx, dword [esp + 0xac]
mov esi, dword [esp + 0xac]
movzx edx, byte [ecx + eax + 0x4d0]
add edx, 0xc
mov ecx, dword [ecx + edx*4 + 4]
lea ebx, [ecx + 1]
mov dword [esi + edx*4 + 4], ebx
lea edx, [eax + 1]
mov byte [esi + ecx + 0x3d0], al
cmp dword [esp + 0x3c], edx
jle 0x4095d9
movzx ecx, byte [eax + esi + 0x4d1]
mov ebx, esi
add ecx, 0xc
mov esi, dword [esi + ecx*4 + 4]
mov dword [esp + 0x40], esi
add esi, 1
mov dword [ebx + ecx*4 + 4], esi
mov esi, dword [esp + 0x40]
lea ecx, [eax + 2]
mov byte [ebx + esi + 0x3d0], dl
cmp dword [esp + 0x3c], ecx
jle 0x4095d9
movzx edx, byte [eax + ebx + 0x4d2]
add eax, 3
add edx, 0xc
mov esi, dword [ebx + edx*4 + 4]
mov dword [esp + 0x40], esi
add esi, 1
mov dword [ebx + edx*4 + 4], esi
mov esi, dword [esp + 0x40]
mov byte [ebx + esi + 0x3d0], cl
cmp dword [esp + 0x3c], eax
jle 0x4095d9
movzx edx, byte [ebx + eax + 0x4d0]
mov esi, dword [esp + 0xac]
add edx, 0xc
mov ecx, dword [ebx + edx*4 + 4]
lea ebx, [ecx + 1]
mov dword [esi + edx*4 + 4], ebx
mov byte [esi + ecx + 0x3d0], al
lea eax, [ebp + 1]
mov dword [esp + 0x4c], 0
mov dword [esp + 0x68], eax
movzx eax, byte [esp + 0x44]
mov dword [esp + 0x40], 1
add eax, 1
mov byte [esp + 0x6f], al
lea esi, [esi]
mov edx, dword [esp + 0x40]
mov eax, dword [esp + 0xac]
mov eax, dword [eax + edx*4]
mov ecx, edx
mov dword [esp + 0x44], eax
mov eax, 1
shl eax, cl
movzx ecx, byte [esp + 0x6f]
sar eax, 1
mov dword [esp + 0x3c], eax
sub ecx, edx
cmp eax, 4
je 0x409760
jg 0x4096d0
cmp eax, 1
je 0x4098b0
cmp eax, 2
jne 0x4097e0
mov ebx, dword [esp + 0x44]
test ebx, ebx
jle 0x409906
mov edx, dword [esp + 0xac]
mov eax, dword [esp + 0xa0]
mov ebx, dword [esp + 0x4c]
mov esi, dword [esp + 0xac]
add edx, edi
add edi, dword [esp + 0x44]
mov dword [esp + 0x50], edi
lea eax, [eax + ebx*2 + 4]
add esi, edi
nop
movzx ebx, byte [edx + 0x3d0]
add edx, 1
mov byte [eax], cl
add eax, 4
mov byte [eax - 2], cl
mov byte [eax - 3], bl
mov byte [eax - 1], bl
cmp edx, esi
jne 0x409680
lea esi, [esi]
add dword [esp + 0x40], 1
mov eax, dword [esp + 0x44]
mov edi, dword [esp + 0x50]
imul eax, dword [esp + 0x3c]
add dword [esp + 0x4c], eax
mov eax, dword [esp + 0x40]
cmp eax, dword [esp + 0x68]
jb 0x409600
jmp 0x409220
cmp dword [esp + 0x3c], 8
jne 0x4097e0
mov ebp, dword [esp + 0x44]
test ebp, ebp
jle 0x409906
mov ebx, dword [esp + 0xac]
mov eax, dword [esp + 0xa0]
movzx ebp, cl
mov ecx, dword [esp + 0x4c]
add ebx, edi
add edi, dword [esp + 0x44]
mov dword [esp + 0x50], edi
add edi, dword [esp + 0xac]
lea ecx, [eax + ecx*2 + 4]
mov dword [esp + 0x48], edi
lea esi, [esi]
movzx eax, byte [ebx + 0x3d0]
add ecx, 0x10
add ebx, 1
shl eax, 8
add eax, ebp
mov edi, eax
sar edi, 0x1f
lea esi, [eax + edi]
mov edi, 0x10001
mul edi
imul esi, esi, 0x10001
mov dword [ecx - 0x10], eax
add edx, esi
mov dword [ecx - 8], eax
mov dword [ecx - 0xc], edx
mov dword [ecx - 4], edx
cmp ebx, dword [esp + 0x48]
jne 0x409718
jmp 0x4096a0
mov esi, dword [esp + 0x44]
test esi, esi
jle 0x409906
movzx ebp, cl
mov ecx, dword [esp + 0xac]
mov eax, dword [esp + 0xa0]
mov edx, dword [esp + 0x4c]
add ecx, edi
add edi, dword [esp + 0x44]
mov dword [esp + 0x50], edi
add edi, dword [esp + 0xac]
lea ebx, [eax + edx*2 + 4]
mov dword [esp + 0x48], edi
lea esi, [esi]
movzx eax, byte [ecx + 0x3d0]
add ebx, 8
add ecx, 1
shl eax, 8
add eax, ebp
mov edi, eax
sar edi, 0x1f
lea esi, [eax + edi]
mov edi, 0x10001
mul edi
imul esi, esi, 0x10001
mov dword [ebx - 8], eax
add edx, esi
mov dword [ebx - 4], edx
cmp ecx, dword [esp + 0x48]
jne 0x4097a0
jmp 0x4096a0
mov eax, dword [esp + 0x44]
test eax, eax
jle 0x409906
movzx eax, cl
mov ebx, dword [esp + 0xac]
mov ecx, dword [esp + 0x4c]
mov dword [esp + 0x58], eax
mov eax, dword [esp + 0xa0]
add ebx, edi
add edi, dword [esp + 0x44]
add eax, 4
mov dword [esp + 0x50], edi
add edi, dword [esp + 0xac]
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x54], edi
lea edi, [eax - 1]
mov eax, dword [esp + 0xa0]
and edi, 0xfffffff0
add eax, 0x24
mov dword [esp + 0x60], eax
lea esi, [esi]
movzx eax, byte [ebx + 0x3d0]
mov edx, dword [esp + 0x58]
shl eax, 8
lea ebp, [eax + edx]
mov eax, ebp
cdq
mov eax, 0x10001
lea esi, [ebp + edx]
imul esi, esi, 0x10001
mul ebp
lea ebp, [edi + ecx]
add edx, esi
mov esi, dword [esp + 0x5c]
lea esi, [esi + ecx*2]
mov dword [esp + 0x48], esi
mov esi, dword [esp + 0x60]
lea ebp, [esi + ebp*2]
mov esi, dword [esp + 0x48]
mov dword [esi], eax
add esi, 0x20
mov dword [esi - 0x1c], edx
mov dword [esi - 0x18], eax
mov dword [esi - 0x14], edx
mov dword [esi - 0x10], eax
mov dword [esi - 0xc], edx
mov dword [esi - 8], eax
mov dword [esi - 4], edx
cmp esi, ebp
jne 0x409880
add ecx, dword [esp + 0x3c]
add ebx, 1
cmp dword [esp + 0x54], ebx
jne 0x409840
jmp 0x4096a0
mov edx, dword [esp + 0x44]
test edx, edx
jle 0x409906
mov ebx, dword [esp + 0x4c]
mov eax, dword [esp + 0xa0]
mov edx, dword [esp + 0xac]
lea eax, [eax + ebx*2 + 5]
mov ebx, dword [esp + 0xac]
add edx, edi
add edi, dword [esp + 0x44]
mov dword [esp + 0x50], edi
add ebx, edi
mov edi, ecx
lea esi, [esi]
nop
movzx ecx, byte [edx + 0x3d0]
add edx, 1
add eax, 2
mov byte [eax - 2], cl
mov ecx, edi
mov byte [eax - 3], cl
cmp ebx, edx
jne 0x4098e8
jmp 0x4096a0
mov eax, dword [esp + 0x44]
add eax, edi
mov dword [esp + 0x50], eax
jmp 0x4096a0
add eax, 1
cmp eax, esi
jne 0x409288
jmp 0x40929f
mov ebp, ebx
jmp 0x40937e
mov dword [esp + 0x64], 0xffffffd4
jmp 0x409220