Function at 0x140063220
Capabilities:
Check mutex on windows

Disassembly:
push rsi
push rdi
push r12
push r13
push r14
push r15
push rbp
sub rsp, 0x40
mov r12, rdx
mov edi, r8d
mov r13, rcx
lea r14, [0x140000000]
mov esi, dword [r12]
cmp esi, 0xffffffff
je 0x140063257
jle 0x1400635d9
cmp esi, 0x68
jg 0x1400635d4
inc esi
movsxd rax, esi
mov edx, esi
test rax, rax
jl 0x1400635ba
cmp rax, 0x271
jg 0x1400635ba
lea r8, [rax + rax*2]
shl r8, 4
mov rcx, qword [r14 + r8 + 0xe5068]
test rcx, rcx
je 0x1400635af
mov dword [rsp + 0x30], edx
cmp rax, 0x68
jg 0x140063450
cmp dword [r14 + r8 + 0xe5050], 0
je 0x1400632dd
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edx, dword [rsp + 0x30]
movsxd rdx, edx
lea r8, [rdx + rdx*2]
shl r8, 4
cmp eax, dword [r14 + r8 + 0xe504c]
jne 0x1400632dd
mov eax, Ordinal_43
mov dword [r12], esi
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
cmp dword [0x1400ce448], 2
jge 0x14006331a
mov eax, dword [r14 + r8 + 0xe5048]
test eax, eax
je 0x1400632fc
mov eax, 0x98
jmp 0x14006339d
movsxd rdx, edx
lea rax, [rdx + rdx*2]
shl rax, 4
mov dword [r14 + rax + 0xe5048], 1
xor eax, eax
jmp 0x14006339d
movsxd rdx, edx
lea rbp, [0x1400e5040]
lea rax, [rdx + rdx*2]
shl rax, 4
lea rcx, [rbp + rax + 8]
call fcn.14007a450
test eax, eax
je 0x140063341
mov eax, 0x98
jmp 0x14006339d
movsxd rcx, dword [rsp + 0x30]
lea rdx, [rcx + rcx*2]
shl rdx, 4
mov rax, qword [r14 + rdx + 0xe5040]
test rax, rax
je 0x14006390c
mov dword [r14 + rdx + 0xe5048], 0
mov edx, 0xffffffff
lea rax, [rcx + rcx*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
lea rcx, [rbp + rdx + 8]
call fcn.14007a450
test eax, eax
je 0x1400633a8
mov eax, 0x98
jmp 0x1400633d1
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
movsxd rdx, dword [rsp + 0x30]
lea rcx, [rdx + rdx*2]
shl rcx, 4
mov dword [r14 + rcx + 0xe504c], eax
xor eax, eax
mov dword [r14 + rcx + 0xe5050], 1
test eax, eax
jne 0x1400632c9
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov rbp, qword [r14 + rdx + 0xe5068]
test rbp, rbp
jne 0x1400638db
mov dword [r14 + rdx + 0xe5050], 0
mov dword [r14 + rdx + 0xe504c], 0xffffffff
cmp dword [0x1400ce448], 2
jge 0x140063429
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x1400635af
mov dword [r14 + rdx + 0xe5048], 0
lea rax, [rax + rax*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
jmp 0x1400635aa
mov ebp, 0x7fffffff
cmp ebp, dword [rcx + 0x1b0]
jle 0x140063463
mov ebp, dword [rcx + 0x1b0]
mov rcx, qword [rcx + 0x48]
test rcx, rcx
jne 0x140063455
mov ecx, dword [0x1400ce448]
cmp ecx, 2
jge 0x1400634a7
mov eax, dword [r14 + r8 + 0xe5048]
test eax, eax
jne 0x14006353c
movsxd rdx, edx
lea rax, [rdx + rdx*2]
mov edx, dword [rsp + 0x30]
shl rax, 4
mov dword [r14 + rax + 0xe5048], 1
jmp 0x14006353c
movsxd rdx, edx
lea r15, [0x1400e5040]
lea rax, [rdx + rdx*2]
shl rax, 4
lea rcx, [r15 + rax + 8]
call fcn.14007a450
mov edx, dword [rsp + 0x30]
test eax, eax
je 0x1400634d3
mov ecx, dword [0x1400ce448]
jmp 0x14006353c
movsxd rdx, edx
lea rdx, [rdx + rdx*2]
shl rdx, 4
mov rax, qword [r14 + rdx + 0xe5040]
test rax, rax
je 0x140063bd3
mov dword [r14 + rdx + 0xe5048], 0
movsxd rcx, dword [rsp + 0x30]
mov edx, 0xffffffff
lea rax, [rcx + rcx*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
lea rcx, [r15 + rdx + 8]
call fcn.14007a450
mov ecx, dword [0x1400ce448]
mov edx, dword [rsp + 0x30]
cmp ecx, 1
je 0x140063bae
movsxd rdx, edx
lea r8, [rdx + rdx*2]
shl r8, 4
mov r15, qword [r14 + r8 + 0xe5068]
test r15, r15
jne 0x140063978
mov edx, dword [0x1400ce448]
cmp edx, 1
je 0x14006393f
movsxd rax, dword [rsp + 0x30]
cmp edx, 2
jge 0x140063588
mov dword [r14 + r8 + 0xe5048], 0
jmp 0x1400635af
mov dword [r14 + r8 + 0xe5048], 0
lea rax, [rax + rax*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
movsxd rax, dword [rsp + 0x30]
inc rax
mov edx, eax
jns 0x140063267
mov dword [r12], 0xffffffff
xor eax, eax
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
lea ebp, [rsi - 5]
jmp 0x1400635db
mov ebp, esi
cmp ebp, 0xfffffffa
lea ecx, [rbp + 5]
cmovle ecx, ebp
mov eax, 0xfb93e673
mul ecx
shr edx, 9
imul r8d, edx, 0x209
sub ecx, r8d
add ecx, 0x69
mov r8d, dword [0x1400ce448]
cmp r8d, 2
mov dword [rsp + 0x30], ecx
movsxd rax, ecx
jge 0x140063638
lea rdx, [rax + rax*2]
shl rdx, 4
mov eax, dword [r14 + rdx + 0xe5048]
test eax, eax
jne 0x1400636c4
mov dword [r14 + rdx + 0xe5048], 1
jmp 0x1400636c4
lea r15, [0x1400e5040]
lea rax, [rax + rax*2]
shl rax, 4
lea rcx, [r15 + rax + 8]
call fcn.14007a450
test eax, eax
jne 0x1400636b9
movsxd rcx, dword [rsp + 0x30]
lea rax, [rcx + rcx*2]
shl rax, 4
mov rdx, qword [r14 + rax + 0xe5040]
test rdx, rdx
je 0x140063d4e
lea rax, [rcx + rcx*2]
shl rax, 4
mov dword [r14 + rax + 0xe5048], 0
mov edx, 0xffffffff
lea rax, [rcx + rcx*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
lea rcx, [r15 + rdx + 8]
call fcn.14007a450
mov r8d, dword [0x1400ce448]
mov ecx, dword [rsp + 0x30]
cmp r8d, 1
je 0x140063d29
movsxd rcx, ecx
lea rdx, [rcx + rcx*2]
shl rdx, 4
mov rax, qword [r14 + rdx + 0xe5068]
mov r15, rax
test rax, rax
je 0x1400636fe
cmp ebp, dword [r15 + 0x1b0]
jbe 0x1400636fb
mov r15, qword [r15 + 0x48]
test r15, r15
jne 0x1400636e9
test rax, rax
mov ecx, 0x7fffffff
je 0x140063733
cmp ecx, dword [rax + 0x1b0]
jle 0x140063713
mov ecx, dword [rax + 0x1b0]
mov rax, qword [rax + 0x48]
test rax, rax
jne 0x140063705
cmp ecx, 0x7fffffff
je 0x140063733
mov eax, 5
xor esi, esi
cmp ecx, 0xfffffffa
cmovg esi, eax
add esi, ecx
mov dword [r12], esi
test r15, r15
je 0x140063c06
cmp ebp, dword [r15 + 0x1b0]
jne 0x140063756
mov r15, qword [r15 + 0x48]
test r15, r15
je 0x140063c06
cmp dword [r15 + 0x10], 0
je 0x140063773
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [r15 + 0xc]
jne 0x140063773
mov ebp, Ordinal_43
jmp 0x1400637fb
cmp dword [0x1400ce448], 2
jge 0x140063797
mov eax, dword [r15 + 8]
test eax, eax
je 0x14006378b
mov eax, 0x98
jmp 0x1400637d8
mov dword [r15 + 8], 1
xor eax, eax
jmp 0x1400637d8
lea rbp, [r15 + 8]
mov rcx, rbp
call fcn.14007a450
test eax, eax
je 0x1400637ae
mov eax, 0x98
jmp 0x1400637d8
mov rax, qword [r15]
test rax, rax
je 0x140063d0c
mov dword [r15 + 8], 0
mov rcx, qword [r15]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rbp
call fcn.14007a450
test eax, eax
je 0x1400637e3
mov ebp, 0x98
jmp 0x1400637f7
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [r15 + 0xc], eax
xor ebp, ebp
mov dword [r15 + 0x10], 1
test ebp, ebp
je 0x140063867
mov eax, dword [0x1400ce448]
cmp eax, 1
je 0x140063c9a
cmp eax, 2
jge 0x14006382a
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063851
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
mov rcx, qword [r14 + rdx + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov dword [r12], esi
mov eax, ebp
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
mov eax, dword [0x1400ce448]
cmp eax, 1
je 0x140063cd3
cmp eax, 2
jge 0x140063896
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x1400638bd
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
mov rcx, qword [r14 + rdx + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov rcx, r15
mov edx, edi
call fcn.140063d90
mov qword [r13], r15
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
mov rcx, rbp
mov edx, edi
call fcn.140063d90
mov qword [r13], rbp
mov ecx, dword [rbp + 0x1b0]
cmp ecx, 0xfffffffa
lea edx, [rcx + 5]
cmovg ecx, edx
mov dword [r12], ecx
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
xor ecx, ecx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
movsxd rcx, dword [rsp + 0x30]
lea rdx, [rcx + rcx*2]
shl rdx, 4
mov qword [r14 + rdx + 0xe5040], rax
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x14006336b
mov rax, qword [r14 + r8 + 0xe5058]
lea rcx, [rsp + 0x20]
mov rdx, qword [r14 + r8 + 0xe5060]
mov qword [rcx], rax
mov qword [rcx + 8], rdx
call fcn.14007a420
movsxd rax, dword [rsp + 0x30]
mov edx, dword [0x1400ce448]
lea r8, [rax + rax*2]
shl r8, 4
jmp 0x140063575
cmp dword [r15 + 0x10], 0
je 0x140063995
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [r15 + 0xc]
jne 0x140063995
mov esi, Ordinal_43
jmp 0x140063a1a
cmp dword [0x1400ce448], 2
jge 0x1400639b9
mov eax, dword [r15 + 8]
test eax, eax
je 0x1400639ad
mov eax, 0x98
jmp 0x1400639f7
mov dword [r15 + 8], 1
xor eax, eax
jmp 0x1400639f7
lea rsi, [r15 + 8]
mov rcx, rsi
call fcn.14007a450
test eax, eax
je 0x1400639d0
mov eax, 0x98
jmp 0x1400639f7
mov rcx, qword [r15]
test rcx, rcx
je 0x140063b8e
mov dword [r15 + 8], 0
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rsi
call fcn.14007a450
test eax, eax
je 0x140063a02
mov esi, 0x98
jmp 0x140063a16
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [r15 + 0xc], eax
xor esi, esi
mov dword [r15 + 0x10], 1
test esi, esi
je 0x140063a95
mov eax, dword [0x1400ce448]
cmp eax, 1
je 0x140063b1c
cmp eax, 2
jge 0x140063a49
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063a70
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
mov rcx, qword [r14 + rdx + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, 5
xor ecx, ecx
cmp ebp, 0xfffffffa
mov eax, esi
cmovg ecx, edx
add ebp, ecx
mov dword [r12], ebp
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
mov eax, dword [0x1400ce448]
cmp eax, 1
je 0x140063b55
cmp eax, 2
jge 0x140063ac4
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063aeb
movsxd rax, dword [rsp + 0x30]
lea rdx, [rax + rax*2]
shl rdx, 4
mov dword [r14 + rdx + 0xe5048], 0
mov rcx, qword [r14 + rdx + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov rcx, r15
mov edx, edi
call fcn.140063d90
mov edx, 5
xor ecx, ecx
cmp ebp, 0xfffffffa
cmovg ecx, edx
mov qword [r13], r15
add ebp, ecx
mov dword [r12], ebp
add rsp, 0x40
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
movsxd rax, dword [rsp + 0x30]
lea rcx, [rsp + 0x20]
lea rdi, [rax + rax*2]
shl rdi, 4
mov rdx, qword [r14 + rdi + 0xe5058]
mov r8, qword [r14 + rdi + 0xe5060]
mov qword [rcx], rdx
mov qword [rcx + 8], r8
call fcn.14007a420
mov eax, dword [0x1400ce448]
jmp 0x140063a29
movsxd rax, dword [rsp + 0x30]
lea rcx, [rsp + 0x20]
lea rsi, [rax + rax*2]
shl rsi, 4
mov rdx, qword [r14 + rsi + 0xe5058]
mov r8, qword [r14 + rsi + 0xe5060]
mov qword [rcx], rdx
mov qword [rcx + 8], r8
call fcn.14007a420
mov eax, dword [0x1400ce448]
jmp 0x140063aa4
xor ecx, ecx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
mov qword [r15], rax
mov dword [r15 + 8], 0
mov rcx, qword [r15]
jmp 0x1400639e4
movsxd rdx, edx
lea rax, [0x1400e5040]
lea r8, [rdx + rdx*2]
shl r8, 4
lea rcx, [rax + r8 + 0x18]
call fcn.14007a3e0
mov edx, dword [rsp + 0x30]
jmp 0x140063545
xor ecx, ecx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
movsxd rcx, dword [rsp + 0x30]
lea rdx, [rcx + rcx*2]
shl rdx, 4
mov qword [r14 + rdx + 0xe5040], rax
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063500
mov ecx, dword [0x1400ce448]
cmp ecx, 1
je 0x140063c61
movsxd rax, dword [rsp + 0x30]
cmp ecx, 2
jge 0x140063c29
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063c50
mov dword [r14 + rdx + 0xe5048], 0
lea rax, [rax + rax*2]
shl rax, 4
mov rcx, qword [r14 + rax + 0xe5040]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
movsxd rax, dword [rsp + 0x30]
inc rax
lea edx, [rsi + 1]
mov dword [r12], edx
mov edx, eax
jmp 0x14006325e
mov rax, qword [r14 + rdx + 0xe5058]
lea rcx, [rsp + 0x20]
mov rdx, qword [r14 + rdx + 0xe5060]
mov qword [rcx], rax
mov qword [rcx + 8], rdx
call fcn.14007a420
movsxd rax, dword [rsp + 0x30]
mov ecx, dword [0x1400ce448]
lea rdx, [rax + rax*2]
shl rdx, 4
jmp 0x140063c16
movsxd rax, dword [rsp + 0x30]
lea rcx, [rsp + 0x20]
lea rdi, [rax + rax*2]
shl rdi, 4
mov rdx, qword [r14 + rdi + 0xe5058]
mov r8, qword [r14 + rdi + 0xe5060]
mov qword [rcx], rdx
mov qword [rcx + 8], r8
call fcn.14007a420
mov eax, dword [0x1400ce448]
jmp 0x14006380a
movsxd rax, dword [rsp + 0x30]
lea rcx, [rsp + 0x20]
lea rbp, [rax + rax*2]
shl rbp, 4
mov rdx, qword [r14 + rbp + 0xe5058]
mov rsi, qword [r14 + rbp + 0xe5060]
mov qword [rcx], rdx
mov qword [rcx + 8], rsi
call fcn.14007a420
mov eax, dword [0x1400ce448]
jmp 0x140063876
xor ecx, ecx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
mov qword [r15], rax
mov dword [r15 + 8], 0
jmp 0x1400637c2
movsxd rcx, ecx
lea rax, [0x1400e5040]
lea rdx, [rcx + rcx*2]
shl rdx, 4
lea rcx, [rax + rdx + 0x18]
call fcn.14007a3e0
mov ecx, dword [rsp + 0x30]
jmp 0x1400636ce
xor ecx, ecx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
movsxd rcx, dword [rsp + 0x30]
lea rdx, [rcx + rcx*2]
shl rdx, 4
mov qword [r14 + rdx + 0xe5040], rax
mov dword [r14 + rdx + 0xe5048], 0
jmp 0x140063687