Function at 0x4f90c0
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 0xc]
mov dword [ebp - 8], edi
mov dword [ebp - 4], ebx
mov edi, dword [eax]
cmp edi, 0xffffffff
mov dword [ebp - 0xc], esi
je 0x4f90e8
jle 0x4f9430
cmp edi, 0x68
jg 0x4f942b
inc edi
mov ecx, edi
mov edx, edi
mov esi, edi
test ecx, ecx
js 0x4f9413
cmp ecx, 0x271
jg 0x4f9413
mov ebx, ecx
lea eax, [ecx*4]
shl ebx, 5
sub ebx, eax
mov eax, dword [ebx + 0x57d0d8]
test eax, eax
je 0x4f9408
mov dword [ebp - 0x14], esi
cmp ecx, 0x68
jg 0x4f92c1
cmp dword [ebx + 0x57d0cc], 0
je 0x4f916c
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edx, dword [ebp - 0x14]
mov esi, edx
shl esi, 5
mov ecx, edx
lea ebx, [edx*4]
sub esi, ebx
cmp eax, dword [esi + 0x57d0c8]
jne 0x4f916c
mov eax, 0x28
mov edx, dword [ebp + 0xc]
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov dword [edx], edi
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
cmp dword [0x577aa0], 2
jge 0x4f91b2
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
mov ecx, dword [ecx + 0x57d0c4]
test ecx, ecx
je 0x4f9195
mov eax, 0x98
jmp 0x4f9238
lea eax, [edx*4]
shl edx, 5
sub edx, eax
xor eax, eax
mov dword [edx + 0x57d0c4], 1
jmp 0x4f9238
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea edx, [edx + 0x57d0c4]
push edx
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f91d8
mov eax, 0x98
jmp 0x4f9238
mov edx, dword [ebp - 0x14]
mov ecx, edx
shl ecx, 5
lea eax, [edx*4]
sub ecx, eax
cmp dword [ecx + 0x57d0c0], 0
je 0x4f9751
mov dword [ecx + 0x57d0c4], 0
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x57d0c4]
push ecx
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f9243
mov eax, 0x98
jmp 0x4f926a
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [ebp - 0x14]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x57d0c8], eax
xor eax, eax
mov dword [ecx + 0x57d0cc], 1
test eax, eax
jne 0x4f915a
mov ecx, dword [ebp - 0x14]
mov edx, ecx
shl edx, 5
lea eax, [ecx*4]
sub edx, eax
mov ebx, dword [edx + 0x57d0d8]
test ebx, ebx
jne 0x4f9720
mov dword [edx + 0x57d0cc], 0
mov dword [edx + 0x57d0c8], 0xffffffff
cmp dword [0x577aa0], 2
jge 0x4f93e3
mov dword [edx + 0x57d0c4], 0
jmp 0x4f9408
mov esi, 0x7fffffff
mov ecx, dword [eax + 0x100]
cmp ecx, esi
mov eax, dword [eax + 0x28]
jge 0x4f92d5
mov esi, ecx
test eax, eax
jne 0x4f92c6
mov eax, dword [0x577aa0]
cmp eax, 2
jge 0x4f930f
mov ecx, dword [ebx + 0x57d0c4]
test ecx, ecx
jne 0x4f939d
lea ecx, [edx*4]
shl edx, 5
sub edx, ecx
mov dword [edx + 0x57d0c4], 1
mov edx, dword [ebp - 0x14]
jmp 0x4f939d
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea edx, [edx + 0x57d0c4]
push edx
call fcn.004d87b0
add esp, 4
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x4f9338
mov eax, dword [0x577aa0]
jmp 0x4f939d
mov ecx, edx
lea eax, [edx*4]
shl ecx, 5
sub ecx, eax
cmp dword [ecx + 0x57d0c0], 0
je 0x4f99dd
mov dword [ecx + 0x57d0c4], 0
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x57d0c4]
push ecx
call fcn.004d87b0
add esp, 4
mov eax, dword [0x577aa0]
mov edx, dword [ebp - 0x14]
cmp eax, 1
je 0x4f99ba
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov ebx, dword [edx + 0x57d0d8]
test ebx, ebx
jne 0x4f97b2
mov ebx, dword [0x577aa0]
cmp ebx, 1
je 0x4f9782
mov ecx, dword [ebp - 0x14]
cmp ebx, 2
jge 0x4f93e3
mov dword [edx + 0x57d0c4], 0
jmp 0x4f9408
mov dword [edx + 0x57d0c4], 0
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
push dword [ecx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov ecx, dword [ebp - 0x14]
inc ecx
mov edx, ecx
mov esi, ecx
jns 0x4f90f7
mov edx, dword [ebp + 0xc]
xor eax, eax
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 8]
mov dword [edx], 0xffffffff
mov esp, ebp
pop ebp
ret
lea esi, [edi - 5]
jmp 0x4f9432
mov esi, edi
cmp esi, 0xfffffffa
lea ecx, [esi + 5]
jg 0x4f943c
mov ecx, esi
mov eax, 0xfb93e673
mul ecx
shr edx, 9
imul ebx, edx, 0x209
sub ecx, ebx
mov ebx, dword [0x577aa0]
cmp ebx, 2
lea eax, [ecx + 0x69]
mov dword [ebp - 0x14], eax
jge 0x4f948c
lea ecx, [ecx*4 + 0x1a4]
lea edx, [ecx*8]
sub edx, ecx
mov ecx, dword [edx + 0x57d0c4]
test ecx, ecx
jne 0x4f9526
mov dword [edx + 0x57d0c4], 1
jmp 0x4f9526
lea eax, [ecx*4 + 0x1a4]
lea edx, [eax*8]
sub edx, eax
lea ecx, [edx + 0x57d0c4]
push ecx
call fcn.004d87b0
add esp, 4
test eax, eax
jne 0x4f951d
mov edx, dword [ebp - 0x14]
mov ecx, edx
shl ecx, 5
lea eax, [edx*4]
sub ecx, eax
cmp dword [ecx + 0x57d0c0], 0
je 0x4f9b34
mov ecx, edx
lea eax, [edx*4]
shl ecx, 5
sub ecx, eax
mov dword [ecx + 0x57d0c4], 0
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x57d0c4]
push ecx
call fcn.004d87b0
add esp, 4
mov ebx, dword [0x577aa0]
mov eax, dword [ebp - 0x14]
cmp ebx, 1
je 0x4f9b11
lea edx, [eax*4]
shl eax, 5
sub eax, edx
mov edx, dword [eax + 0x57d0d8]
mov ebx, edx
test edx, edx
je 0x4f955c
cmp esi, dword [ebx + 0x100]
jbe 0x4f9b04
mov ebx, dword [ebx + 0x28]
test ebx, ebx
jne 0x4f9547
test edx, edx
je 0x4f9595
mov dword [ebp - 0x10], edi
mov ecx, 0x7fffffff
mov edi, dword [edx + 0x100]
cmp edi, ecx
mov edx, dword [edx + 0x28]
jge 0x4f9575
mov ecx, edi
test edx, edx
jne 0x4f9566
mov edi, dword [ebp - 0x10]
cmp ecx, 0x7fffffff
je 0x4f9595
mov edi, 5
cmp ecx, 0xfffffffa
jg 0x4f9593
mov edi, 0
add edi, ecx
mov edx, dword [ebp + 0xc]
test ebx, ebx
mov dword [edx], edi
je 0x4f9a0e
cmp esi, dword [ebx + 0x100]
jne 0x4f95b5
mov ebx, dword [ebx + 0x28]
test ebx, ebx
je 0x4f9a0e
cmp dword [ebx + 0xc], 0
je 0x4f95cd
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [ebx + 8]
jne 0x4f95cd
mov esi, 0x28
jmp 0x4f964a
cmp dword [0x577aa0], 2
jge 0x4f95ef
mov eax, dword [ebx + 4]
test eax, eax
je 0x4f95e4
mov eax, 0x98
jmp 0x4f9629
mov dword [ebx + 4], 1
xor eax, eax
jmp 0x4f9629
lea esi, [ebx + 4]
push esi
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f9606
mov eax, 0x98
jmp 0x4f9629
cmp dword [ebx], 0
je 0x4f9aeb
mov dword [ebx + 4], 0
push 0xffffffffffffffff
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push esi
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f9634
mov esi, 0x98
jmp 0x4f9646
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [ebx + 8], eax
xor esi, esi
mov dword [ebx + 0xc], 1
test esi, esi
je 0x4f96b1
mov eax, dword [0x577aa0]
cmp eax, 1
je 0x4f9a91
cmp eax, 2
jge 0x4f9678
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
jmp 0x4f969d
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [ebp + 0xc]
mov eax, esi
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov dword [edx], edi
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov eax, dword [0x577aa0]
cmp eax, 1
je 0x4f9abe
cmp eax, 2
jge 0x4f96df
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
jmp 0x4f9704
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, ebx
mov edx, dword [ebp + 0x10]
call fcn.004f9b70
mov edx, dword [ebp + 8]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 8]
mov dword [edx], ebx
mov ebx, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov eax, ebx
mov edx, dword [ebp + 0x10]
call fcn.004f9b70
mov edx, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp - 8]
mov dword [edx], ebx
mov ecx, dword [ebx + 0x100]
cmp ecx, 0xfffffffa
lea ebx, [ecx + 5]
jg 0x4f9745
mov ebx, ecx
mov dword [esi], ebx
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov edx, dword [ebp - 0x14]
mov ebx, edx
shl ebx, 5
lea ecx, [edx*4]
sub ebx, ecx
mov dword [ebx + 0x57d0c0], eax
mov dword [ebx + 0x57d0c4], 0
jmp 0x4f9200
push dword [edx + 0x57d0d4]
push dword [edx + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov ecx, dword [ebp - 0x14]
mov edx, ecx
shl edx, 5
mov ebx, dword [0x577aa0]
lea eax, [ecx*4]
sub edx, eax
jmp 0x4f93d2
cmp dword [ebx + 0xc], 0
je 0x4f97cd
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [ebx + 8]
jne 0x4f97cd
mov edi, 0x28
jmp 0x4f984a
cmp dword [0x577aa0], 2
jge 0x4f97ef
mov eax, dword [ebx + 4]
test eax, eax
je 0x4f97e4
mov eax, 0x98
jmp 0x4f9829
mov dword [ebx + 4], 1
xor eax, eax
jmp 0x4f9829
lea edi, [ebx + 4]
push edi
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f9806
mov eax, 0x98
jmp 0x4f9829
cmp dword [ebx], 0
je 0x4f99a1
mov dword [ebx + 4], 0
push 0xffffffffffffffff
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push edi
call fcn.004d87b0
add esp, 4
test eax, eax
je 0x4f9834
mov edi, 0x98
jmp 0x4f9846
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [ebx + 8], eax
xor edi, edi
mov dword [ebx + 0xc], 1
test edi, edi
je 0x4f98c2
mov eax, dword [0x577aa0]
cmp eax, 1
je 0x4f9947
cmp eax, 2
jge 0x4f9878
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
jmp 0x4f989d
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, 5
cmp esi, 0xfffffffa
mov ecx, dword [ebp + 0xc]
mov eax, edi
jg 0x4f98b1
mov edx, 0
add esi, edx
mov dword [ecx], esi
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
mov eax, dword [0x577aa0]
cmp eax, 1
je 0x4f9974
cmp eax, 2
jge 0x4f98f0
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
jmp 0x4f9915
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x57d0c4], 0
push dword [edx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, ebx
mov edx, dword [ebp + 0x10]
call fcn.004f9b70
mov edx, dword [ebp + 8]
mov ecx, 5
cmp esi, 0xfffffffa
jg 0x4f9931
mov ecx, 0
mov dword [edx], ebx
add esi, ecx
mov ebx, dword [ebp + 0xc]
mov edi, dword [ebp - 8]
mov dword [ebx], esi
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0d4]
push dword [edx + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov eax, dword [0x577aa0]
jmp 0x4f9858
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0d4]
push dword [edx + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov eax, dword [0x577aa0]
jmp 0x4f98d0
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [ebx], eax
mov dword [ebx + 4], 0
jmp 0x4f9816
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea edx, [edx + 0x57d0d0]
push edx
call fcn.004d8760
add esp, 4
mov edx, dword [ebp - 0x14]
jmp 0x4f93a6
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov edx, dword [ebp - 0x14]
mov ebx, edx
shl ebx, 5
lea ecx, [edx*4]
sub ebx, ecx
mov dword [ebx + 0x57d0c0], eax
mov dword [ebx + 0x57d0c4], 0
jmp 0x4f935d
mov ebx, dword [0x577aa0]
cmp ebx, 1
je 0x4f9a64
mov ecx, dword [ebp - 0x14]
cmp ebx, 2
jge 0x4f9a2d
mov dword [eax + 0x57d0c4], 0
jmp 0x4f9a52
mov dword [eax + 0x57d0c4], 0
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
push dword [ecx + 0x57d0c0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp + 0xc]
inc ecx
mov esi, ecx
lea eax, [edi + 1]
mov dword [edx], eax
mov edx, ecx
jmp 0x4f90ef
push dword [eax + 0x57d0d4]
push dword [eax + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov ecx, dword [ebp - 0x14]
mov eax, ecx
shl eax, 5
mov ebx, dword [0x577aa0]
lea edx, [ecx*4]
sub eax, edx
jmp 0x4f9a1c
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0d4]
push dword [edx + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov eax, dword [0x577aa0]
jmp 0x4f9658
mov edx, dword [ebp - 0x14]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x57d0d4]
push dword [edx + 0x57d0d0]
call fcn.004d8790
add esp, 8
mov eax, dword [0x577aa0]
jmp 0x4f96bf
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [ebx], eax
mov dword [ebx + 4], 0
jmp 0x4f9616
test edx, edx
jne 0x4f955e
jmp 0x4f9595
lea edx, [eax*4]
shl eax, 5
sub eax, edx
lea eax, [eax + 0x57d0d0]
push eax
call fcn.004d8760
add esp, 4
mov eax, dword [ebp - 0x14]
jmp 0x4f952f
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov edx, dword [ebp - 0x14]
mov ebx, edx
shl ebx, 5
lea ecx, [edx*4]
sub ebx, ecx
mov dword [ebx + 0x57d0c0], eax
mov dword [ebx + 0x57d0c4], 0
jmp 0x4f94e5