Function at 0x515420
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x596b08
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x5e173c]
xor eax, esp
mov dword [esp + 0x18], eax
push ebx
push esi
push edi
mov eax, dword [0x5e173c]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
mov edi, ecx
mov dword [esp + 0x14], edi
lea ebx, [edi + 0xc]
mov dword [esp + 0x24], ebx
test ebx, ebx
je 0x515475
mov eax, dword [ebx]
test eax, eax
je 0x515475
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [esp + 0x38], 0
xorps xmm0, xmm0
movq qword [esp + 0x18], xmm0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], 0
mov byte [esp + 0x38], 1
mov esi, dword [edi]
mov eax, dword [edi + 4]
cmp esi, eax
je 0x5154da
mov edi, dword [ebp + 8]
mov eax, dword [esp + 0x14]
jmp 0x5154c0
cmp edi, dword [esi]
jne 0x5154d2
push esi
lea ecx, [esp + 0x1c]
call fcn.005161e0
mov eax, dword [esp + 0x14]
add esi, 0x18
cmp esi, dword [eax + 4]
jne 0x5154c0
mov esi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test ebx, ebx
je 0x5154f3
mov eax, dword [ebx]
test eax, eax
je 0x5154ed
push eax
call esi
xor ebx, ebx
mov dword [esp + 0x24], ebx
mov eax, dword [esp + 0x18]
mov edi, eax
cmp eax, dword [esp + 0x1c]
je 0x5155ce
mov ebx, dword [esp + 0x14]
lea esi, [ebx + 0xc]
mov dword [esp + 0x14], esi
test esi, esi
je 0x51551f
mov eax, dword [esi]
test eax, eax
je 0x51551f
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [esp + 0x38], 2
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
cmp eax, ecx
je 0x515595
lea ecx, [ecx]
mov edx, dword [eax]
mov dword [esp + 0x10], edx
test edx, edx
je 0x51553e
cmp edx, dword [edi]
je 0x515547
add eax, 0x18
cmp eax, ecx
jne 0x515530
jmp 0x515595
push eax
call fcn.00515830
test al, al
je 0x515575
test esi, esi
je 0x515568
mov eax, dword [esi]
test eax, eax
je 0x515562
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor esi, esi
mov dword [esp + 0x14], esi
push dword [esp + 0x10]
mov ecx, ebx
call fcn.00515b60
jmp 0x515595
test esi, esi
je 0x51558c
mov eax, dword [esi]
test eax, eax
je 0x515586
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor esi, esi
mov dword [esp + 0x14], esi
mov ecx, dword [esp + 0x10]
call fcn.005111d0
mov byte [esp + 0x38], 1
test esi, esi
je 0x5155b3
mov eax, dword [esi]
test eax, eax
je 0x5155ab
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [esp + 0x14], 0
add edi, 0x18
cmp edi, dword [esp + 0x1c]
jne 0x515507
mov ebx, dword [esp + 0x24]
mov esi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x18]
mov byte [esp + 0x38], 0
test eax, eax
je 0x5155f8
push eax
call fcn.00564de3
add esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x38], 0xffffffff
test ebx, ebx
je 0x515615
mov eax, dword [ebx]
test eax, eax
je 0x51560d
push eax
call esi
mov dword [esp + 0x24], 0
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x18]
xor ecx, esp
call fcn.00564de8
mov esp, ebp
pop ebp
ret 4