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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x294
mov eax, dword [0x4493fc]
xor eax, esp
mov dword [esp + reloc.MSVCRT.dll___dllonexit], eax
mov eax, dword [ebp + 8]
cmp eax, reloc.MSVCRT.dll___dllonexit
push ebx
push esi
mov esi, ecx
mov ebx, edx
push edi
mov dword [esp + 0x14], esi
mov dword [esp + 0x1c], ebx
jl 0x64195b
mov edi, dword [esi]
cmp eax, dword [edi + 4]
jge 0x64195b
cmp dword [esi + 4], reloc.MSVCRT.dll___dllonexit
je 0x6413e3
call fcn.00641215
mov eax, dword [ebp + 8]
cmp eax, dword [esi + reloc.MSVCRT.dll___dllonexit]
mov dword [esi + 4], reloc.MSVCRT.dll___dllonexit
jne 0x64141c
cmp eax, reloc.MSVCRT.dll___dllonexit
je 0x641421
add esi, 8
mov ecx, 0x4b
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
xor ecx, esp
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4
cmp eax, reloc.MSVCRT.dll___dllonexit
jne 0x64147a
mov eax, dword [esi]
mov ecx, dword [eax + 4]
xor eax, eax
mov dword [ebx], ecx
mov byte [ebx + 4], al
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + reloc.MSVCRT.dll___dllonexit], eax
mov dword [ebx + 0x128], eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
xor ecx, esp
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [esi]
cmp eax, dword [ecx + 0x10]
jge 0x64148f
mov esi, ecx
call fcn.00640b45
mov esi, dword [esp + 0x14]
mov eax, dword [ebp + 8]
mov edx, dword [esi]
cmp dword [edx + 0x10], eax
jge 0x6414f0
mov esi, dword [esi]
test esi, esi
je 0x6414e0
cmp dword [esi + 0x18], 0
je 0x6414e0
mov eax, dword [esi + 0x10]
add eax, 1
cmp eax, dword [esi + 4]
je 0x6414e0
mov ecx, dword [esi + 0x50]
add ecx, dword [esi + 0x4c]
mov edx, dword [esi + 0x48]
push 0
lea ecx, [ecx + edx + 0x2e]
add dword [esi + 0x14], ecx
mov dword [esi + 0x10], eax
push 0
lea edx, [esi + 0x78]
push edx
lea eax, [esi + 0x28]
push eax
mov eax, esi
call fcn.006406e5
add esp, 0x10
neg eax
sbb eax, eax
add eax, 1
mov dword [esi + 0x18], eax
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
mov eax, dword [ebp + 8]
cmp dword [edx + 0x10], eax
mov esi, ecx
jl 0x641496
mov eax, dword [esi]
push 0x104
lea ecx, [esp + 0x8c]
push ecx
lea edx, [esp + 0x40]
push 0
push edx
call fcn.006406e5
mov edi, dword [esi]
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x3c]
push edx
call fcn.00640b85
add esp, 0x1c
test eax, eax
je 0x641544
mov eax, 0x700
pop edi
pop esi
pop ebx
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
xor ecx, esp
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi]
mov eax, dword [eax]
cmp byte [eax], 0
je 0x64156b
cmp byte [eax + 1], 0
je 0x6415aa
mov ecx, dword [eax + 0xc]
add ecx, dword [esp + 0x10]
mov edx, dword [eax + 4]
push 0
push 0
push ecx
push edx
call dword [fcn.004392c0]
jmp 0x641572
mov ecx, dword [esp + 0x10]
mov dword [eax + 0x1c], ecx
mov edi, dword [esp + 0x20]
push edi
call fcn.00643d21
mov edx, dword [esi]
add esp, 4
push edi
mov edi, dword [edx]
mov ebx, 1
mov edx, eax
mov dword [esp + 0x14], eax
call fcn.006400f5
add esp, 4
cmp eax, dword [esp + 0x20]
je 0x6415c6
mov eax, dword [esp + 0x10]
push eax
call fcn.00643d26
add esp, 4
mov eax, 0x800
pop edi
pop esi
pop ebx
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
xor ecx, esp
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
mov esi, dword [esp + 0x1c]
mov dword [esi], eax
xor eax, eax
mov cl, byte [esp + eax + 0x88]
mov byte [esp + eax + 0x190], cl
add eax, 1
test cl, cl
jne 0x6415d7
lea edi, reloc.MSVCRT.dll___dllonexit
mov bl, 0x3a
mov al, byte [edi]
test al, al
je 0x641605
cmp byte [edi + 1], bl
jne 0x641605
add edi, 2
jmp 0x6415f5
cmp al, 0x5c
jne 0x64160e
add edi, 1
jmp 0x6415f5
cmp al, 0x2f
jne 0x641617
add edi, 1
jmp 0x6415f5
push 0x4406c4
push edi
call fcn.0065f97b
add esp, 8
test eax, eax
je 0x64162e
lea edi, [eax + 4]
jmp 0x6415f5
push 0x4406cc
push edi
call fcn.0065f97b
add esp, 8
test eax, eax
je 0x641645
lea edi, [eax + 4]
jmp 0x6415f5
push 0x4406d4
push edi
call fcn.0065f97b
add esp, 8
test eax, eax
je 0x64165c
lea edi, [eax + 4]
jmp 0x6415f5
push 0x4406dc
push edi
call fcn.0065f97b
add esp, 8
test eax, eax
je 0x641673
lea edi, [eax + 4]
jmp 0x6415f5
mov ecx, esi
sub ecx, edi
mov eax, edi
lea edx, [ecx + 4]
mov cl, byte [eax]
mov byte [edx + eax], cl
add eax, 1
test cl, cl
jne 0x64167c
mov eax, dword [esp + 0x6c]
mov edi, dword [esp + 0x38]
mov edx, eax
shr edx, 0x17
mov ecx, eax
shr ecx, 0x1e
not dl
and cl, 1
and dl, 1
shr edi, 8
mov byte [esp + 0x1b], 0
mov byte [esp + 0xe], 0
mov byte [esp + 0xf], 1
je 0x6416c5
cmp edi, 7
je 0x6416c5
cmp edi, 0xb
je 0x6416c5
cmp edi, 0xe
jne 0x6416ec
mov ecx, eax
shr ecx, 2
and cl, 1
mov byte [esp + 0xe], cl
mov ebx, eax
mov ecx, eax
mov dl, al
shr ebx, 1
shr ecx, 4
shr eax, 5
and dl, 1
and bl, 1
and cl, 1
and al, 1
jmp 0x6416f4
mov bl, byte [esp + 0x1b]
mov al, byte [esp + 0xf]
test cl, cl
mov dword [esi + reloc.MSVCRT.dll___dllonexit], 0
je 0x64170c
mov dword [esi + reloc.MSVCRT.dll___dllonexit], 0x10
test al, al
je 0x641717
or dword [esi + reloc.MSVCRT.dll___dllonexit], 0x20
test bl, bl
je 0x641722
or dword [esi + reloc.MSVCRT.dll___dllonexit], 2
test dl, dl
je 0x64172d
or dword [esi + reloc.MSVCRT.dll___dllonexit], 1
cmp byte [esp + 0xe], 0
je 0x64173b
or dword [esi + reloc.MSVCRT.dll___dllonexit], 4
mov eax, dword [esp + 0x54]
mov edx, dword [esp + 0x50]
mov dword [esi + 0x128], eax
mov eax, dword [esp + 0x48]
mov ecx, eax
shr ecx, 0x10
mov dword [esi + reloc.MSVCRT.dll___dllonexit], edx
call fcn.00641295
lea ecx, [esp + 0x28]
mov dword [esp + 0x34], edx
push ecx
lea edx, [esp + 0x34]
push edx
mov dword [esp + 0x38], eax
call dword [0x4392ac]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x2c]
xor ebx, ebx
cmp dword [esp + 0x20], 4
mov dword [esi + reloc.MSVCRT.dll___dllonexit], eax
mov dword [esi + reloc.MSVCRT.dll___dllonexit], ecx
mov dword [esi + reloc.MSVCRT.dll___dllonexit], eax
mov dword [esi + reloc.MSVCRT.dll___dllonexit], ecx
mov dword [esi + reloc.MSVCRT.dll___dllonexit], eax
mov dword [esi + reloc.MSVCRT.dll___dllonexit], ecx
jbe 0x641916
mov byte [esp + 0x26], bl
mov eax, dword [esp + 0x10]
mov cl, byte [ebx + eax]
mov dl, byte [eax + ebx + 1]
mov byte [esp + 0x24], cl
mov edi, 0x4406e4
lea esi, [esp + 0x24]
mov ecx, 3
xor eax, eax
mov byte [esp + 0x25], dl
repe cmpsb byte [esi], byte es:[edi]
je 0x6417f4
mov ecx, dword [esp + 0x10]
movzx edx, byte [ebx + ecx + 2]
lea ebx, [ebx + edx + 4]
lea eax, [ebx + 4]
cmp eax, dword [esp + 0x20]
jb 0x6417b2
jmp 0x641912
mov esi, dword [esp + 0x10]
movzx eax, byte [ebx + esi + 4]
mov ecx, eax
mov edx, eax
shr ecx, 1
shr edx, 2
and cl, 1
and dl, 1
add ebx, 5
test al, 1
mov byte [esp + 0xf], cl
mov byte [esp + 0xe], dl
je 0x641871
movzx ecx, byte [ebx + esi + 1]
movzx edx, byte [ebx + esi]
xor eax, eax
mov ah, byte [ebx + esi + 3]
push 0
add ebx, 4
push 0x989680
mov al, byte [ebx + esi - 2]
shl eax, 8
or eax, ecx
shl eax, 8
or eax, edx
cdq
add eax, 0xb6109100
adc edx, 2
push edx
push eax
call fcn.006637a5
mov edi, dword [esp + 0x1c]
mov ecx, edx
sar ecx, 0x1f
mov cl, byte [esp + 0xf]
mov dword [edi + reloc.MSVCRT.dll___dllonexit], edx
mov dl, byte [esp + 0xe]
mov dword [edi + reloc.MSVCRT.dll___dllonexit], eax
jmp 0x641875
mov edi, dword [esp + 0x1c]
test cl, cl
je 0x6418c5
movzx edx, byte [ebx + esi + 1]
movzx ecx, byte [ebx + esi]
xor eax, eax
mov ah, byte [ebx + esi + 3]
push 0
add ebx, 4
push 0x989680
mov al, byte [ebx + esi - 2]
shl eax, 8
or eax, edx
shl eax, 8
or eax, ecx
cdq
add eax, 0xb6109100
adc edx, 2
push edx
push eax
call fcn.006637a5
mov ecx, edx
mov dword [edi + reloc.MSVCRT.dll___dllonexit], edx
mov dl, byte [esp + 0xe]
sar ecx, 0x1f
mov dword [edi + reloc.MSVCRT.dll___dllonexit], eax
test dl, dl
je 0x641912
mov eax, dword [esp + 0x10]
movzx ecx, byte [ebx + eax + 1]
xor edx, edx
mov dh, byte [ebx + eax + 3]
push 0
push 0x989680
mov dl, byte [ebx + eax + 2]
movzx eax, byte [ebx + eax]
shl edx, 8
or edx, ecx
shl edx, 8
or eax, edx
cdq
add eax, 0xb6109100
adc edx, 2
push edx
push eax
call fcn.006637a5
mov ecx, edx
sar ecx, 0x1f
mov dword [edi + reloc.MSVCRT.dll___dllonexit], eax
mov dword [edi + reloc.MSVCRT.dll___dllonexit], edx
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x10]
test eax, eax
je 0x641927
push eax
call fcn.00643d26
add esp, 4
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x14]
mov edx, dword [ebp + 8]
add edi, 8
mov ecx, 0x4b
rep movsd dword es:[edi], dword [esi]
mov dword [eax + reloc.MSVCRT.dll___dllonexit], edx
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
xor ecx, esp
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [esp + reloc.MSVCRT.dll___dllonexit]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 0x10000
call fcn.0065f06f
mov esp, ebp
pop ebp
ret 4