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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xd0
call fcn.0052b1a0
mov dword [esp + 0x38], eax
mov edi, eax
lock dec byte [eax + 0x18]
je 0x52ba57
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
add edi, 0x18
mov dword [esp], eax
mov esi, dword [0x6320f0]
test esi, esi
je 0x52b557
mov dword [esp + 0x1c], edi
mov edi, 0x3e8
mov eax, ecx
mul edi
mov edx, ebx
mov ebx, eax
mov eax, edx
seto cl
mul edi
mov edi, edx
add edi, ebx
mov ebx, eax
setb al
or al, cl
jne 0x52b53a
mov eax, dword [ebp + 0x10]
mov ecx, 0x431bde83
mul ecx
shr edx, 0x12
add ebx, edx
adc edi, 0
jb 0x52b53a
imul eax, edx, 0xf4240
xor ecx, ecx
sub dword [esp], eax
setne cl
xor eax, eax
add ebx, ecx
adc edi, 0
setb cl
neg edi
sbb eax, eax
test cl, cl
je 0x52b7ce
mov eax, 0xffffffff
mov edi, dword [esp + 0x1c]
push eax
push 1
push 0x5fe6d7
push edi
call esi
xor eax, eax
xchg byte [edi], al
jmp 0x52ba57
mov ecx, dword [0x599094]
cmp ecx, 0xffffffff
jne 0x52b5a4
mov dword [esp + 0x3c], 0xffffffff
mov eax, dword [0x5990a4]
lea ecx, [esp + 0x3c]
push 0
push 0
push 0xc0000000
push ecx
call eax
test eax, eax
jne 0x52ba6d
mov ecx, dword [esp + 0x3c]
mov eax, 0xffffffff
lock cmpxchg dword [0x599094], ecx
je 0x52b5a4
mov esi, eax
push ecx
call sub.KERNEL32.dll_CloseHandle
mov ecx, esi
mov esi, 0x3b9aca00
mov eax, ebx
mov dword [esp + 0x50], ecx
mul esi
mov ebx, eax
mov eax, dword [ebp + 0xc]
mov ecx, edx
mul esi
mov esi, ebx
add eax, ecx
mov ecx, 0xffffff9c
adc edx, 0
add esi, dword [ebp + 0x10]
adc eax, 0
mov dword [esp + 0x4c], esi
adc edx, 0
setb bl
cmp ecx, esi
mov ecx, 0xffffffff
sbb ecx, eax
mov ecx, 0x31
movzx ebx, bl
sbb ecx, edx
mov ecx, 0
sbb ecx, ebx
jb 0x52b7c7
mov ecx, esi
mov esi, eax
mov dword [esp + 0x1c], edi
mov edi, edx
mov dword [esp + 0x44], eax
mov dword [esp + 0x40], ebx
mov dword [esp + 0x48], edx
add ecx, 0x63
adc esi, 0
mov eax, ecx
mov dword [esp], ecx
adc edi, 0
mov ecx, esi
mov dword [esp + 4], esi
adc ebx, 0
or eax, edi
mov dword [esp + 0x10], edi
or ecx, ebx
mov dword [esp + 0x14], ebx
or eax, ecx
mov eax, dword [esp + 4]
sete byte [esp + 0xc]
bsr edx, edi
bsr esi, ebx
xor edx, 0x1f
xor esi, 0x1f
add edx, 0x20
test ebx, ebx
cmovne edx, esi
bsr esi, dword [esp]
bsr ecx, eax
xor ecx, 0x1f
xor esi, 0x1f
add esi, 0x20
test eax, eax
cmovne esi, ecx
mov ecx, edi
mov edi, 0
add esi, 0x40
or ecx, ebx
mov ebx, 0x79
mov ecx, 0x7f
cmovne esi, edx
mov edx, 0
sub ebx, esi
mov esi, 0
sbb edi, edi
sbb edx, edx
sbb esi, esi
cmp ecx, ebx
mov ecx, 0
sbb ecx, edi
mov ecx, 0
mov dword [esp + 0x18], esi
sbb ecx, edx
mov ecx, 0
sbb ecx, esi
mov esi, 0
setb cl
or cl, byte [esp + 0xc]
mov ecx, eax
mov eax, 0
cmovne ecx, esi
mov esi, dword [esp]
mov dword [esp + 0xc], ecx
cmovne esi, eax
mov dword [esp + 8], esi
jne 0x52b9e2
mov esi, edi
mov ecx, ebx
mov eax, edx
or esi, dword [esp + 0x18]
xor ecx, 0x7f
or ecx, edx
or esi, ecx
je 0x52b9e2
mov dword [esp + 0x20], eax
mov eax, dword [esp]
mov dword [esp + 0xbc], eax
mov eax, dword [esp + 4]
mov dword [esp + 0xc0], eax
mov ecx, dword [esp + 0x10]
mov dword [esp + 0xc4], ecx
mov ecx, dword [esp + 0x14]
mov dword [esp + 0xb8], 0
mov dword [esp + 0xb4], 0
mov dword [esp + 0xb0], 0
mov dword [esp + 0xac], 0
mov dword [esp + 0xc8], ecx
mov ecx, ebx
xor cl, 0x7f
mov ch, cl
shr cl, 3
and cl, 0xf
and ch, 7
neg cl
movsx edx, cl
mov cl, ch
mov eax, dword [esp + edx + 0xc4]
mov dword [esp + 0x24], ebx
mov ebx, dword [esp + edx + 0xc8]
shld ebx, eax, cl
shl eax, cl
not cl
mov dword [esp + 0x34], ebx
mov dword [esp + 0x28], eax
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + edx + 0xc0]
mov esi, dword [esp + edx + 0xbc]
mov edx, eax
shr edx, 1
shr edx, cl
mov cl, ch
shld eax, esi, cl
shl esi, cl
add ebx, 1
adc edi, 0
mov dword [esp + 0xc], eax
mov dword [esp + 0x2c], edi
adc dword [esp + 0x20], 0
mov edi, dword [esp + 0x18]
adc edi, 0
jae 0x52b7d5
mov dword [esp + 0x10], 0
xor edi, edi
jmp 0x52b9ca
mov ecx, ebx
jmp 0x52b9f2
or eax, ebx
jmp 0x52b53f
mov eax, dword [esp]
or dword [esp + 0x28], edx
mov ch, bl
and ch, 7
mov cl, ch
mov dword [esp + 0x8c], eax
mov eax, dword [esp + 4]
mov dword [esp + 0x90], eax
mov eax, dword [esp + 0x10]
mov dword [esp + 0x94], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0xa8], 0
mov dword [esp + 0xa4], 0
mov dword [esp + 0xa0], 0
mov dword [esp + 0x9c], 0
mov dword [esp + 0x98], eax
mov eax, ebx
mov dword [esp + 0x18], edi
mov dword [esp + 0x24], ebx
shr al, 3
and al, 0xf
movzx edx, al
mov eax, esi
mov edi, dword [esp + edx + 0x94]
mov ebx, dword [esp + edx + 0x98]
mov esi, edi
add edi, edi
shrd esi, ebx, cl
mov dword [esp], esi
mov esi, dword [esp + edx + 0x90]
mov dword [esp + 8], eax
mov dword [esp + 4], esi
shr esi, cl
not cl
shl edi, cl
mov cl, ch
or edi, esi
shr ebx, cl
mov esi, dword [esp + 8]
mov dword [esp + 0x14], edi
mov edi, dword [esp + 4]
mov eax, ebx
mov ebx, 0x64
mov edx, dword [esp + edx + 0x8c]
mov dword [esp + 0x10], 0
shrd edx, edi, cl
add ebx, 0xffffffff
mov dword [esp + 0x30], edx
mov edx, 0
mov dword [esp + 0x60], ebx
mov ebx, 0
adc edx, 0xffffffff
mov dword [esp + 0x5c], edx
adc ebx, 0xffffffff
mov edx, 0
adc edx, 0xffffffff
mov dword [esp + 0x58], ebx
mov ebx, dword [esp + 0x20]
xor edi, edi
mov dword [esp + 0x54], edx
mov edx, dword [esp + 0x2c]
nop dword [eax]
mov dword [esp + 0x20], ebx
mov ecx, dword [esp]
mov ebx, dword [esp + 0x14]
mov dword [esp + 0x2c], edx
mov edx, dword [esp + 0x30]
mov dword [esp + 8], edi
mov edi, dword [esp + 0x10]
mov dword [esp + 0x10], 0
shld eax, ecx, 1
shld ecx, ebx, 1
shld ebx, edx, 1
mov dword [esp + 4], eax
mov dword [esp], ecx
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x28]
shld edx, eax, 1
shld eax, ecx, 1
or eax, edi
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0xc]
shld ecx, eax, 1
shld eax, esi, 1
add esi, esi
or ecx, edi
or esi, dword [esp + 8]
or eax, edi
cmp dword [esp + 0x60], edx
mov dword [esp + 0x28], ecx
mov ecx, dword [esp + 0x5c]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 4]
mov dword [esp + 8], esi
mov esi, 0x64
sbb ecx, ebx
mov ecx, dword [esp + 0x58]
sbb ecx, dword [esp]
mov ecx, dword [esp + 0x54]
sbb ecx, eax
sar ecx, 0x1f
mov edi, ecx
and ecx, esi
mov esi, dword [esp + 0x24]
and edi, 1
sub edx, ecx
sbb ebx, 0
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x2c]
sbb dword [esp], 0
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x20]
sbb eax, 0
add esi, 0xffffffff
mov dword [esp + 4], eax
mov eax, dword [esp + 0x18]
adc edx, 0xffffffff
mov dword [esp + 0x24], esi
adc ebx, 0xffffffff
mov ecx, edx
adc eax, 0xffffffff
or esi, ebx
or ecx, eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 4]
or esi, ecx
mov esi, dword [esp + 8]
jne 0x52b8e0
mov eax, dword [esp + 0xc]
shld eax, esi, 1
add esi, esi
or eax, dword [esp + 0x10]
or esi, edi
mov dword [esp + 8], esi
mov dword [esp + 0xc], eax
mov edi, dword [esp + 0x1c]
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x40]
mov esi, dword [esp + 8]
mov ebx, 0
neg esi
sbb ebx, dword [esp + 0xc]
cmp dword [esp + 0x4c], 0xffffff9d
sbb eax, 0xffffffff
mov eax, 0
sbb edx, 0x31
sbb ecx, 0
mov ecx, 0x80000000
cmovb ecx, ebx
cmovae esi, eax
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x68], esi
mov eax, dword [0x5990ac]
lea ecx, [esp + 0x68]
push ecx
push 0
push edi
mov esi, dword [esp + 0x5c]
push esi
call eax
test eax, eax
mov eax, 0
xchg byte [edi], al
je 0x52ba57
cmp al, 1
jne 0x52ba57
mov eax, dword [0x5990ac]
push 0
push 0
push edi
push esi
call eax
mov ecx, dword [esp + 0x38]
lock dec dword [ecx]
jne 0x52ba65
call fcn.00515920
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov dword [esp + 0x64], eax
lea eax, [esp + 0x64]
mov dword [esp + 0x68], 0x601164
mov dword [esp + 0x6c], 1
mov dword [esp + 0x78], 0
mov dword [esp + 0x84], eax
lea eax, [esp + 0x84]
mov dword [esp + 0x88], 0x42baa0
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], 1
lea eax, [esp + 0x68]
push 0x60119c
push eax
call fcn.00425150
add esp, 8
jmp 0x52bada
ud2