Function at 0x42656c
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], esi
mov edi, ecx
cmp dword [0x530840], 0
mov dword [ebp - 0x10], edx
mov esi, eax
mov eax, 0
mov dword [ebp - 0x20], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], eax
je 0x427068
cmp esi, 0xfffffffb
jl 0x4268d2
cmp dword [0x525800], 2
jge 0x4265b9
cmp dword [ebp + 0x14], 6
je 0x4268e1
cmp esi, 0xfffffffb
je 0x426ed8
mov eax, 0x3ee4f99d
mov dword [ebp - 0x34], edi
lea ebx, [esi + 5]
imul ebx
mov dword [ebp - 4], ebx
mov ecx, ebx
mov dword [ebp - 0x30], ebx
sar edx, 7
sar ecx, 0x1f
sub edx, ecx
imul edx, edx, 0x209
neg edx
add edx, ebx
mov ebx, dword [ebp + 0x14]
mov dword [ebp - 0x28], edx
lea eax, [edx + 0x69]
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 4]
cmp ecx, 0x69
jge 0x426791
lea eax, [ecx*4]
mov edx, ecx
shl edx, 5
sub edx, eax
cmp dword [edx + 0x5312ec], 0
je 0x426649
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [ebp - 4]
lea edi, [ecx*4]
mov edx, ecx
shl edx, 5
sub edx, edi
cmp eax, dword [edx + 0x5312e8]
jne 0x426649
mov eax, 0x28
mov ebx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov esp, ebp
pop ebp
ret
cmp dword [0x525800], 2
jge 0x426680
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
mov edx, dword [ecx + 0x5312e4]
test edx, edx
je 0x426672
mov eax, 0x98
jmp 0x4266f7
mov dword [ecx + 0x5312e4], 1
xor eax, eax
jmp 0x4266f7
lea eax, [edx + 0x5312e4]
push eax
call fcn.004257e0
pop ecx
test eax, eax
je 0x426698
mov eax, 0x98
jmp 0x4266f7
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
cmp dword [edx + 0x5312e0], 0
je 0x426ac4
mov dword [edx + 0x5312e4], 0
mov edx, dword [ebp - 4]
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x5312e4]
push ecx
call fcn.004257e0
pop ecx
test eax, eax
je 0x426702
mov eax, 0x98
jmp 0x426729
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [ebp - 4]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x5312e8], eax
mov dword [ecx + 0x5312ec], 1
xor eax, eax
test eax, eax
jne 0x42663c
mov eax, dword [ebp - 4]
lea edx, [eax*4]
shl eax, 5
sub eax, edx
mov edx, dword [eax + 0x5312f8]
test edx, edx
je 0x42676a
movzx ecx, byte [edx + 0x159]
test cl, 0x20
jne 0x426760
test cl, 0x18
je 0x426760
cmp ebx, 6
je 0x42676a
cmp dword [edx + 0x18], 0
je 0x426aaf
lea ecx, [ebp - 0x20]
lea edx, [ebp - 8]
lea eax, [eax + 0x5312e0]
push eax
push edx
push ebx
push ecx
push esi
call fcn.0042a550
add esp, 0x14
cmp eax, 0xfffffffd
je 0x4265f5
jmp 0x4268f7
mov eax, dword [ebp - 0x24]
mov ecx, dword [0x525800]
mov dword [ebp - 4], eax
cmp ecx, 2
jge 0x4267d5
mov edx, dword [ebp - 0x28]
lea edi, [edx*4 + 0x1a4]
lea edx, [edi*8]
sub edx, edi
mov edi, dword [edx + 0x5312e4]
test edi, edi
jne 0x42686f
mov dword [edx + 0x5312e4], 1
mov eax, dword [ebp - 4]
jmp 0x42686f
mov eax, dword [ebp - 0x28]
lea edx, [eax*4 + 0x1a4]
lea ecx, [edx*8]
sub ecx, edx
lea edi, [ecx + 0x5312e4]
push edi
call fcn.004257e0
pop ecx
test eax, eax
jne 0x426866
mov ecx, dword [ebp - 4]
lea eax, [ecx*4]
mov edx, ecx
shl edx, 5
sub edx, eax
cmp dword [edx + 0x5312e0], 0
je 0x426ea9
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
mov dword [ecx + 0x5312e4], 0
mov edx, dword [ebp - 4]
push 0xffffffffffffffff
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
lea ecx, [edx + 0x5312e4]
push ecx
call fcn.004257e0
pop ecx
mov ecx, dword [0x525800]
mov eax, dword [ebp - 4]
cmp ecx, 1
je 0x426e88
lea edx, [eax*4]
shl eax, 5
sub eax, edx
mov edx, dword [eax + 0x5312f8]
mov dword [ebp - 0x20], edx
xor edi, edi
test edx, edx
je 0x4268ab
cmp esi, dword [edx + 0xf0]
jle 0x426e73
mov edi, edx
mov edx, dword [edx + 0x28]
mov dword [ebp - 0x20], edx
test edx, edx
jne 0x426893
lea edx, [ebp - 0xc]
lea ecx, [ebp - 8]
lea eax, [eax + 0x5312e0]
push eax
push ecx
push ebx
push edx
push esi
call fcn.0042a550
add esp, 0x14
cmp eax, 0xfffffffd
je 0x4265f5
jmp 0x426af3
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov eax, 0x20
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x2c], 2
lea eax, [ebp - 0x2c]
push eax
call fcn.00424f60
pop ecx
jmp 0x4265b9
mov ebx, dword [ebp - 0x30]
mov edi, dword [ebp - 0x34]
test eax, eax
jne 0x42663c
cmp dword [ebp - 0x20], 0
je 0x4269be
mov eax, dword [ebp - 0x20]
mov dword [0x5305e0], 1
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x10]
cmp edx, 6
mov dword [ecx], eax
jne 0x42692e
mov edx, 8
test edi, edi
je 0x426935
mov dword [edi + 4], eax
mov dword [eax + 0x64], edi
cmp edx, 0xd
je 0x42695d
cmp edx, 0x10
je 0x42695d
cmp edx, 0xa
jne 0x426953
mov eax, dword [ebp - 0x20]
or byte [eax + 0x162], 2
jmp 0x42695d
mov eax, dword [ebp - 0x20]
and byte [eax + 0x162], 0xfd
mov eax, dword [ebp - 0x20]
mov byte [eax + 0x14c], dl
mov ecx, dword [ebp - 0x20]
and byte [ecx + 0x162], 0xf7
mov ebx, dword [ebp - 0x20]
and byte [ebx + 0x162], 0xef
cmp dword [ebp - 8], 0
je 0x4269af
mov eax, dword [ebp - 0x20]
call fcn.00427940
mov ebx, eax
test ebx, ebx
je 0x4269af
mov eax, esi
xor edx, edx
call fcn.00425db0
mov edx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov eax, ebx
mov ebx, dword [ebp - 0x1c]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
xor eax, eax
mov esp, ebp
pop ebp
ret
mov dword [ebp - 8], 0
lea eax, [ebp - 0x20]
push eax
push 1
push 0x170
call fcn.0042e2b0
add esp, 0xc
test eax, eax
je 0x426a55
mov ecx, dword [ebp - 4]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
cmp dword [0x525800], 2
mov dword [ecx + 0x5312ec], 0
mov dword [ecx + 0x5312e8], 0xffffffff
jge 0x426a14
mov dword [ecx + 0x5312e4], 0
jmp 0x426a3f
mov dword [ecx + 0x5312e4], 0
mov ecx, dword [ebp - 4]
lea edx, [ecx*4]
shl ecx, 5
mov dword [ebp - 0x34], eax
sub ecx, edx
push dword [ecx + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebp - 0x34]
mov edx, dword [ebp - 0x10]
mov ebx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
push 0x170
push 0
push dword [ebp - 0x20]
call fcn.004b11c0
add esp, 0xc
mov eax, dword [ebp - 0x20]
mov dword [eax + 0xf0], esi
cmp ebx, 0x69
jl 0x426a92
mov edx, dword [ebp - 0x20]
xor eax, eax
mov dword [edx], eax
mov ecx, dword [ebp - 0x20]
mov dword [ecx + 4], eax
mov ebx, dword [ebp - 0x20]
mov dword [ebx + 8], 0xffffffff
mov edx, dword [ebp - 0x20]
mov dword [edx + 0xc], eax
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov eax, dword [ebp - 0x20]
mov dword [edx + 0x5312f8], eax
jmp 0x426912
mov edi, dword [ebp - 0x34]
mov dword [ebp - 8], 1
mov dword [ebp - 0x20], edx
mov eax, dword [ebp - 0x20]
jmp 0x426912
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov ecx, dword [ebp - 4]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x5312e0], eax
mov dword [ecx + 0x5312e4], 0
jmp 0x4266be
mov ebx, dword [ebp - 0x30]
mov dword [ebp - 0x28], edi
mov edi, dword [ebp - 0x34]
test eax, eax
jne 0x42663c
mov edx, dword [ebp - 0xc]
test edx, edx
je 0x426d24
mov dword [ebp - 0x20], edx
cmp dword [edx + 0x18], 0
je 0x426bb5
mov eax, dword [0x525800]
cmp eax, 1
je 0x426b88
cmp eax, 2
jge 0x426b4c
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
mov eax, dword [ebp - 0x20]
jmp 0x42691c
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
mov ebx, dword [ebp - 4]
lea ecx, [ebx*4]
shl ebx, 5
sub ebx, ecx
push dword [ebx + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebp - 0x20]
jmp 0x42691c
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x5312f4]
push dword [edx + 0x5312f0]
call fcn.004257c0
add esp, 8
mov eax, dword [0x525800]
jmp 0x426b26
cmp dword [edx + 0xc], 0
je 0x426bd3
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edx, dword [ebp - 0x20]
cmp eax, dword [edx + 8]
jne 0x426bd3
mov ebx, 0x28
jmp 0x426c62
cmp dword [0x525800], 2
jge 0x426bf5
mov eax, dword [edx + 4]
test eax, eax
je 0x426bea
mov eax, 0x98
jmp 0x426c37
mov dword [edx + 4], 1
xor eax, eax
jmp 0x426c37
add edx, 4
push edx
call fcn.004257e0
pop ecx
test eax, eax
je 0x426c0a
mov eax, 0x98
jmp 0x426c37
mov eax, dword [ebp - 0x20]
cmp dword [eax], 0
je 0x426d05
mov dword [eax + 4], 0
mov eax, dword [ebp - 0x20]
push 0xffffffffffffffff
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [ebp - 0x20]
add eax, 4
push eax
call fcn.004257e0
pop ecx
test eax, eax
je 0x426c42
mov ebx, 0x98
jmp 0x426c5a
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edx, dword [ebp - 0x20]
mov dword [edx + 8], eax
mov eax, dword [ebp - 0x20]
xor ebx, ebx
mov dword [eax + 0xc], 1
test ebx, ebx
je 0x426b1c
mov eax, dword [0x525800]
cmp eax, 1
je 0x426cd8
cmp eax, 2
jge 0x426c8c
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
jmp 0x426cc0
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
mov esi, dword [ebp - 4]
lea ecx, [esi*4]
shl esi, 5
sub esi, ecx
push dword [esi + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov eax, ebx
mov ebx, dword [ebp - 0x1c]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x5312f4]
push dword [edx + 0x5312f0]
call fcn.004257c0
add esp, 8
mov eax, dword [0x525800]
jmp 0x426c6c
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov edx, dword [ebp - 0x20]
mov dword [edx], eax
mov eax, dword [ebp - 0x20]
mov dword [eax + 4], 0
jmp 0x426c1d
mov dword [ebp - 8], 0
lea eax, [ebp - 0x34]
push eax
push 1
push 0x170
call fcn.0042e2b0
mov dword [ebp - 0x30], eax
add esp, 0xc
cmp dword [ebp - 0x30], 0
je 0x426dc2
mov eax, dword [0x525800]
cmp eax, 1
je 0x426e2c
cmp eax, 2
jge 0x426d75
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
jmp 0x426da9
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
mov dword [edx + 0x5312e4], 0
mov ebx, dword [ebp - 4]
lea ecx, [ebx*4]
shl ebx, 5
sub ebx, ecx
push dword [ebx + 0x5312e0]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x30]
mov ebx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
push 0x170
push 0
push dword [ebp - 0x34]
call fcn.004b11c0
add esp, 0xc
mov eax, dword [ebp - 0x34]
mov dword [eax + 0xf0], esi
cmp ebx, 0x69
jl 0x426dff
mov edx, dword [ebp - 0x34]
xor eax, eax
mov dword [edx], eax
mov ecx, dword [ebp - 0x34]
mov dword [ecx + 4], eax
mov ebx, dword [ebp - 0x34]
mov dword [ebx + 8], 0xffffffff
mov edx, dword [ebp - 0x34]
mov dword [edx + 0xc], eax
cmp dword [ebp - 0x28], 0
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp - 0x20]
mov dword [edx + 0x28], eax
je 0x426e59
mov eax, dword [ebp - 0x34]
mov edx, dword [ebp - 0x28]
mov dword [edx + 0x28], eax
mov edx, dword [ebp - 0x34]
mov dword [0x5305e0], 1
mov dword [ebp - 0x20], edx
jmp 0x426b12
mov edx, dword [ebp - 4]
lea eax, [edx*4]
shl edx, 5
sub edx, eax
push dword [edx + 0x5312f4]
push dword [edx + 0x5312f0]
call fcn.004257c0
add esp, 8
mov eax, dword [0x525800]
jmp 0x426d55
mov edx, dword [ebp - 0x34]
mov ecx, dword [ebp - 4]
lea eax, [ecx*4]
shl ecx, 5
sub ecx, eax
mov dword [ecx + 0x5312f8], edx
jmp 0x426e1a
jne 0x4268ab
mov edi, dword [ebp - 0x34]
mov dword [ebp - 8], 1
jmp 0x426b12
lea edx, [eax*4]
shl eax, 5
sub eax, edx
lea eax, [eax + 0x5312f0]
push eax
call fcn.00425790
pop ecx
mov eax, dword [ebp - 4]
jmp 0x426878
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov ecx, dword [ebp - 4]
lea edx, [ecx*4]
shl ecx, 5
sub ecx, edx
mov dword [ecx + 0x5312e0], eax
mov dword [ecx + 0x5312e4], 0
jmp 0x42682d
lea eax, [ebp - 0x20]
push eax
push 1
push 0x170
call fcn.0042e2b0
add esp, 0xc
mov ebx, eax
test ebx, ebx
jne 0x426f2f
push 0x170
push 0
push dword [ebp - 0x20]
call fcn.004b11c0
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x34]
push edx
mov dword [eax + 0xf0], esi
push 0
push 0x54
call fcn.0042e2b0
add esp, 0x18
mov ebx, eax
test ebx, ebx
je 0x426f4b
push dword [ebp - 0x20]
call fcn.0042e370
pop ecx
mov dword [ebp - 0x20], 0
test ebx, ebx
je 0x426f90
mov edx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov eax, ebx
mov ebx, dword [ebp - 0x1c]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x34]
mov dword [edx + 0x58], eax
mov ebx, dword [ebp - 0x20]
mov edx, 0x54
mov ecx, dword [ebp - 0x34]
mov dword [ebx + 0x5c], ecx
mov ecx, dword [ebp - 0x34]
xor eax, eax
mov dword [ecx + edx - 4], eax
mov dword [ecx + edx - 8], eax
mov dword [ecx + edx - 0xc], eax
mov dword [ecx + edx - 0x10], eax
mov dword [ecx + edx - 0x14], eax
mov dword [ecx + edx - 0x18], eax
mov dword [ecx + edx - 0x1c], eax
sub edx, 0x1c
jne 0x426f65
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp - 0x20]
mov dword [edx], eax
mov eax, dword [0x525800]
cmp eax, 2
jge 0x426fb1
cmp eax, 1
je 0x427042
mov dword [ebp - 0x30], 0x525760
mov eax, 0x525760
jmp 0x426fc4
lea eax, [ebp - 0x30]
push eax
call fcn.00425550
pop ecx
mov ebx, eax
test ebx, ebx
jne 0x427021
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x20]
mov eax, dword [eax]
mov dword [edx + 0x28], eax
mov ebx, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x20]
mov dword [ebx], ecx
cmp dword [0x525800], 1
je 0x427052
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp + 0x14]
mov byte [edx + 0x14c], al
mov eax, dword [ebp - 0x20]
test edi, edi
je 0x426ff3
mov dword [edi + 4], eax
mov ebx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov dword [eax + 0x64], edi
mov edx, dword [ebp - 0x20]
mov edi, dword [ebp - 0x18]
and byte [edx + 0x162], 0xf7
mov ecx, dword [ebp - 0x20]
and byte [ecx + 0x162], 0xef
mov eax, dword [ebp - 0x20]
mov dword [ebx], eax
xor eax, eax
mov ebx, dword [ebp - 0x1c]
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x20]
call fcn.0042e370
pop ecx
mov edx, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov edi, dword [ebp - 0x18]
mov eax, ebx
mov ebx, dword [ebp - 0x1c]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
push 0x5257c4
call fcn.00425790
pop ecx
jmp 0x426fa3
mov eax, dword [ebp - 0x30]
push dword [eax + 0x68]
push dword [eax + 0x64]
call fcn.004257c0
add esp, 8
jmp 0x426fdd
call fcn.00425a20
jmp 0x42659d