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

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x8c
mov eax, dword [esp + 0xa4]
and eax, 3
je 0x5737fc
mov edi, dword [esp + 0xa0]
xor esi, esi
xor ecx, ecx
mov dword [esp + 0x7c], esi
mov eax, dword [eax*4 + 0x5ef710]
xor edx, edx
mov dword [esp + 0x70], ecx
mov ebp, dword [edi + 0x10]
mov ebx, eax
mov dword [esp + 0x80], edi
sar ebx, 0x1f
mov dword [esp + 0x78], ebp
mov ebp, edi
add ebp, 0x14
mov dword [esp + 0x74], edx
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], ebx
mov esi, dword [ebp]
xor ebx, ebx
mov eax, dword [esp + 0x68]
mov edi, dword [esp + 0x6c]
mov ecx, dword [esp + 0x68]
mul esi
imul edi, esi
imul ecx, ebx
mov dword [esp + 0x10], eax
mov eax, edx
add eax, edi
add eax, ecx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
add eax, dword [esp + 0x70]
adc edx, dword [esp + 0x74]
xor ebx, ebx
inc dword [esp + 0x7c]
mov dword [esp + 0x74], ebx
mov ebx, dword [esp + 0x78]
mov dword [ebp], eax
add ebp, 4
cmp dword [esp + 0x7c], ebx
mov dword [esp + 0x70], edx
jl 0x57376a
mov ebp, dword [esp + 0x74]
or ebp, edx
je 0x5737ee
mov edx, dword [esp + 0xa0]
cmp dword [edx + 8], ebx
jle 0x573b1a
mov eax, dword [esp + 0x78]
mov ebp, dword [esp + 0x80]
mov ecx, dword [esp + 0x70]
mov dword [ebp + eax*4 + 0x14], ecx
inc eax
mov dword [ebp + 0x10], eax
mov esi, dword [esp + 0x80]
mov dword [esp + 0xa0], esi
mov ebx, dword [esp + 0xa4]
sar ebx, 2
mov dword [esp + 0x20], ebx
je 0x573a22
mov edx, dword [0x6a6aa0]
test edx, edx
mov dword [esp + 0x84], edx
je 0x573abd
test byte [esp + 0x20], 1
je 0x5739fe
mov edi, dword [esp + 0x84]
mov esi, dword [esp + 0xa0]
mov ecx, dword [edi + 0x10]
cmp dword [esi + 0x10], ecx
jge 0x57384f
mov esi, edi
mov edi, dword [esp + 0xa0]
mov ebx, dword [edi + 0x10]
xor eax, eax
mov ebp, dword [esi + 0x10]
mov edx, dword [esi + 4]
mov dword [esp + 0xc], ebx
add ebx, ebp
cmp dword [esi + 8], ebx
mov dword [esp + 0x60], ebx
setl al
add eax, edx
mov dword [esp], eax
call fcn.00572fd0
mov dword [esp + 0x64], eax
add eax, 0x14
lea edx, [eax + ebx*4]
mov dword [esp + 0x24], eax
jmp 0x57388d
mov dword [eax], 0
add eax, 4
cmp eax, edx
jb 0x573884
mov ecx, dword [esp + 0xc]
add esi, 0x14
add edi, 0x14
mov dword [esp + 0x1c], esi
lea ebx, [esi + ebp*4]
mov ebp, dword [esp + 0x24]
mov dword [esp + 0x5c], ebx
lea esi, [edi + ecx*4]
cmp edi, esi
mov dword [esp + 0x58], edi
mov dword [esp + 0x54], esi
mov dword [esp + 0x50], ebp
jae 0x57395d
jmp 0x5738d0
mov edi, dword [esp + 0x58]
mov ebp, dword [edi]
add edi, 4
mov dword [esp + 0x58], edi
test ebp, ebp
je 0x57394a
mov edi, dword [esp + 0x1c]
xor edx, edx
xor eax, eax
mov dword [esp + 0x48], edx
mov esi, dword [esp + 0x50]
mov dword [esp + 0x4c], eax
lea esi, [esi]
lea edi, [edi]
mov eax, dword [edi]
mov ebx, dword [esp + 0x48]
mov ecx, dword [esp + 0x4c]
mul ebp
mov dword [esp + 0x10], eax
xor eax, eax
mov dword [esp + 0x14], edx
mov edx, dword [esi]
add dword [esp + 0x10], edx
adc dword [esp + 0x14], eax
add dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x10]
adc dword [esp + 0x14], ecx
add edi, 4
xor eax, eax
mov dword [esi], ebx
add esi, 4
cmp edi, dword [esp + 0x5c]
mov edx, dword [esp + 0x14]
mov dword [esp + 0x4c], eax
mov dword [esp + 0x48], edx
jb 0x573900
mov dword [esi], edx
add dword [esp + 0x50], 4
mov esi, dword [esp + 0x54]
cmp dword [esp + 0x58], esi
jb 0x5738d0
mov ebp, dword [esp + 0x60]
mov edi, dword [esp + 0x24]
test ebp, ebp
lea edx, [edi + ebp*4]
jle 0x573995
cmp dword [edx - 4], 0
lea eax, [edx - 4]
jne 0x573995
lea esi, [esi]
lea edi, [edi]
dec dword [esp + 0x60]
mov ecx, dword [esp + 0x60]
test ecx, ecx
jle 0x573995
sub eax, 4
mov ebx, dword [eax]
test ebx, ebx
je 0x573980
mov eax, dword [esp + 0xa0]
mov esi, dword [esp + 0x60]
mov edx, dword [esp + 0x64]
test eax, eax
mov dword [edx + 0x10], esi
je 0x5739f3
mov ecx, dword [0x6a6120]
cmp ecx, 2
je 0x573a71
test ecx, ecx
je 0x573d97
cmp ecx, 1
je 0x573a34
cmp ecx, 2
je 0x573a71
mov ebx, dword [esp + 0xa0]
cmp ecx, 2
mov edx, dword [ebx + 4]
mov eax, dword [edx*4 + 0x6a6160]
mov dword [ebx], eax
mov dword [edx*4 + 0x6a6160], ebx
je 0x573aa9
mov ecx, dword [esp + 0x64]
mov dword [esp + 0xa0], ecx
sar dword [esp + 0x20], 1
je 0x573a22
mov ebp, dword [esp + 0x84]
mov esi, dword [ebp]
test esi, esi
je 0x573bd5
mov dword [esp + 0x84], esi
jmp 0x573825
mov eax, dword [esp + 0xa0]
add esp, 0x8c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov ecx, dword [0x6a6120]
sub esp, 4
cmp ecx, 1
jne 0x5739c7
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov ecx, dword [0x6a6120]
sub esp, 4
cmp ecx, 1
je 0x573a34
jmp 0x5739c7
mov dword [esp], 0x6a6130
call sub.KERNEL32.DLL_EnterCriticalSection
mov ecx, dword [0x6a6120]
sub esp, 4
mov ebx, dword [esp + 0xa0]
cmp ecx, 2
mov edx, dword [ebx + 4]
mov eax, dword [edx*4 + 0x6a6160]
mov dword [ebx], eax
mov dword [edx*4 + 0x6a6160], ebx
jne 0x5739f3
mov dword [esp], 0x6a6130
call sub.KERNEL32.DLL_LeaveCriticalSection
sub esp, 4
jmp 0x5739f3
mov eax, dword [0x6a6120]
cmp eax, 2
je 0x573f32
test eax, eax
je 0x573ee0
cmp eax, 1
je 0x573e80
cmp eax, 2
je 0x573f32
mov eax, dword [0x6a6aa0]
test eax, eax
mov dword [esp + 0x84], eax
je 0x573fe4
cmp dword [0x6a6120], 2
jne 0x573825
mov dword [esp], 0x6a6148
call sub.KERNEL32.DLL_LeaveCriticalSection
sub esp, 4
jmp 0x573825
mov ebx, dword [edx + 4]
inc ebx
mov dword [esp], ebx
call fcn.00572fd0
mov ecx, dword [esp + 0xa0]
mov ebp, eax
mov eax, dword [ecx + 0x10]
mov esi, ecx
add esi, 0xc
lea edx, [eax*4]
lea ecx, [edx + 8]
cmp ecx, 7
lea eax, [ebp + 0xc]
ja 0x573ebb
cld
mov edi, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0xa0]
test edx, edx
je 0x573bc9
mov ecx, dword [0x6a6120]
cmp ecx, 2
je 0x573f93
test ecx, ecx
je 0x573f46
cmp ecx, 1
jne 0x573b96
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
sub esp, 4
mov ecx, dword [0x6a6120]
cmp ecx, 1
je 0x573b7c
cmp ecx, 2
je 0x573f93
mov edi, dword [esp + 0xa0]
cmp ecx, 2
mov ebx, dword [esp + 0xa0]
mov esi, dword [edi + 4]
mov edx, dword [esi*4 + 0x6a6160]
mov dword [ebx], edx
mov dword [esi*4 + 0x6a6160], ebx
je 0x573fd0
mov dword [esp + 0x80], ebp
jmp 0x5737d7
mov eax, dword [0x6a6120]
cmp eax, 2
je 0x573c53
test eax, eax
je 0x573e0f
cmp eax, 1
je 0x573c1f
cmp eax, 2
je 0x573c53
mov ecx, dword [esp + 0x84]
mov esi, dword [ecx]
test esi, esi
je 0x573c6f
cmp dword [0x6a6120], 2
jne 0x573a16
mov dword [esp], 0x6a6148
call sub.KERNEL32.DLL_LeaveCriticalSection
sub esp, 4
jmp 0x573a16
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov eax, dword [0x6a6120]
sub esp, 4
cmp eax, 1
jne 0x573bec
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov eax, dword [0x6a6120]
sub esp, 4
cmp eax, 1
je 0x573c1f
jmp 0x573bec
mov dword [esp], 0x6a6148
call sub.KERNEL32.DLL_EnterCriticalSection
sub esp, 4
mov ecx, dword [esp + 0x84]
mov esi, dword [ecx]
test esi, esi
jne 0x573bfe
mov ebx, dword [ecx + 0x10]
mov edx, dword [ecx + 4]
lea ebp, [ebx + ebx]
cmp dword [ecx + 8], ebp
mov dword [esp + 0x40], ebp
setl al
movzx eax, al
add eax, edx
mov dword [esp], eax
call fcn.00572fd0
mov dword [esp + 0x44], eax
add eax, 0x14
lea edx, [eax + ebx*8]
mov dword [esp + 0x28], eax
jmp 0x573ca8
mov dword [eax], 0
add eax, 4
cmp eax, edx
jb 0x573c9f
mov esi, dword [esp + 0x84]
add esi, 0x14
lea ebp, [esi + ebx*4]
mov dword [esp + 0x18], esi
mov ebx, dword [esp + 0x28]
cmp esi, ebp
mov dword [esp + 0x3c], esi
mov dword [esp + 0x38], ebx
jae 0x573d49
mov edi, dword [esp + 0x3c]
add dword [esp + 0x3c], 4
mov ecx, dword [edi]
test ecx, ecx
mov dword [esp + 0x2c], ecx
je 0x573d3e
mov edi, dword [esp + 0x18]
xor eax, eax
xor edx, edx
mov dword [esp + 0x30], eax
mov esi, dword [esp + 0x38]
mov dword [esp + 0x34], edx
mov eax, dword [esp + 0x2c]
mov ebx, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
mul dword [edi]
mov dword [esp + 0x10], eax
mov eax, dword [esi]
mov dword [esp + 0x14], edx
xor edx, edx
add dword [esp + 0x10], eax
adc dword [esp + 0x14], edx
add dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x10]
adc dword [esp + 0x14], ecx
add edi, 4
xor edx, edx
mov dword [esi], ebx
mov eax, dword [esp + 0x14]
add esi, 4
mov dword [esp + 0x34], edx
cmp edi, ebp
mov dword [esp + 0x30], eax
jb 0x573cf4
mov dword [esi], eax
add dword [esp + 0x38], 4
cmp dword [esp + 0x3c], ebp
jb 0x573ccd
mov ebp, dword [esp + 0x40]
mov esi, dword [esp + 0x28]
test ebp, ebp
lea edx, [esi + ebp*4]
jle 0x573d76
cmp dword [edx - 4], 0
lea eax, [edx - 4]
jne 0x573d76
dec dword [esp + 0x40]
mov edi, dword [esp + 0x40]
test edi, edi
jle 0x573d76
sub eax, 4
mov ecx, dword [eax]
test ecx, ecx
je 0x573d61
mov eax, dword [esp + 0x44]
mov edx, dword [esp + 0x40]
mov ebx, dword [esp + 0x84]
mov esi, eax
mov dword [eax + 0x10], edx
mov dword [ebx], eax
mov dword [eax], 0
jmp 0x573bfe
mov dword [esp], 0x6a6120
mov ebp, 1
mov dword [esp + 4], ebp
call sub.KERNEL32.DLL_InterlockedExchange
sub esp, 8
test eax, eax
jne 0x573dff
mov esi, 0x6a6130
mov ebx, 1
mov dword [esp], esi
add esi, 0x18
call sub.KERNEL32.DLL_InitializeCriticalSection
sub esp, 4
dec ebx
jns 0x573dbd
mov dword [esp], 0x572f70
call fcn.004012d0
mov dword [esp], 0x6a6130
mov edi, 2
mov dword [0x6a6120], edi
call sub.KERNEL32.DLL_EnterCriticalSection
mov ecx, dword [0x6a6120]
sub esp, 4
jmp 0x573a86
cmp eax, 2
je 0x573dda
mov ecx, dword [0x6a6120]
jmp 0x5739c2
mov dword [esp], 0x6a6120
mov esi, 1
mov dword [esp + 4], esi
call sub.KERNEL32.DLL_InterlockedExchange
sub esp, 8
test eax, eax
jne 0x573e71
mov esi, 0x6a6130
mov ebx, 1
mov dword [esp], esi
add esi, 0x18
call sub.KERNEL32.DLL_InitializeCriticalSection
sub esp, 4
dec ebx
jns 0x573e35
mov dword [esp], 0x572f70
call fcn.004012d0
mov dword [esp], 0x6a6148
mov edi, 2
mov dword [0x6a6120], edi
call sub.KERNEL32.DLL_EnterCriticalSection
sub esp, 4
jmp 0x573c62
cmp eax, 2
je 0x573e52
mov eax, dword [0x6a6120]
jmp 0x573be7
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov eax, dword [0x6a6120]
sub esp, 4
cmp eax, 1
jne 0x573adc
mov dword [esp], 1
call sub.KERNEL32.DLL_Sleep
mov eax, dword [0x6a6120]
sub esp, 4
cmp eax, 1
je 0x573e80
jmp 0x573adc
test al, 4
je 0x573b4d
mov edi, dword [esp + 0xa0]
lea eax, [ebp + 0x10]
lea ecx, [edx + 4]
mov esi, dword [edi + 0xc]
mov dword [ebp + 0xc], esi
mov esi, edi
add esi, 0x10
jmp 0x573b4d
mov dword [esp], 0x6a6120
mov edi, 1
mov dword [esp + 4], edi
call sub.KERNEL32.DLL_InterlockedExchange
sub esp, 8
test eax, eax
jne 0x573fad
mov esi, 0x6a6130
mov ebx, 1
mov dword [esp], esi
add esi, 0x18
call sub.KERNEL32.DLL_InitializeCriticalSection
sub esp, 4
dec ebx
jns 0x573f0a
mov dword [esp], 0x572f70
call fcn.004012d0
mov ebp, 2
mov dword [0x6a6120], ebp
mov dword [esp], 0x6a6148
call sub.KERNEL32.DLL_EnterCriticalSection
sub esp, 4
jmp 0x573ae5
mov dword [esp], 0x6a6120
mov ecx, 1
mov dword [esp + 4], ecx
call sub.KERNEL32.DLL_InterlockedExchange
sub esp, 8
test eax, eax
jne 0x573fc0
mov esi, 0x6a6130
mov ebx, 1
mov dword [esp], esi
add esi, 0x18
call sub.KERNEL32.DLL_InitializeCriticalSection
sub esp, 4
dec ebx
jns 0x573f6c
mov dword [esp], 0x572f70
call fcn.004012d0
mov eax, 2
mov dword [0x6a6120], eax
mov dword [esp], 0x6a6130
call sub.KERNEL32.DLL_EnterCriticalSection
mov ecx, dword [0x6a6120]
sub esp, 4
jmp 0x573b9f
cmp eax, 2
je 0x573f27
mov eax, dword [0x6a6120]
jmp 0x573ad3
cmp eax, 2
jne 0x573b8b
jmp 0x573f89
mov dword [esp], 0x6a6130
call sub.KERNEL32.DLL_LeaveCriticalSection
sub esp, 4
jmp 0x573bc9
mov dword [esp], 1
call fcn.00572fd0
mov dword [0x6a6aa0], eax
mov dword [eax + 0x14], 0x271
mov dword [eax + 0x10], 1
mov dword [esp + 0x84], eax
mov dword [eax], 0
jmp 0x573af9