Function at 0x10004b438
Capabilities:
Check mutex on windows

Disassembly:
mov r11, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x320
mov qword [rsp + 0xc8], 0xfffffffffffffffe
mov qword [r11 + 0x20], rbx
mov rax, qword [0x100083138]
xor rax, rsp
mov qword [rsp + 0x310], rax
mov r14, r8
mov r15d, edx
mov rbx, rcx
mov qword [rsp + 0x40], rcx
lea rcx, [r11 - 0x2c0]
call fcn.1000193b8
nop
lea rcx, [rsp + 0x38]
call fcn.100020360
nop
lea rcx, [rsp + 0xd0]
call fcn.1000193b8
nop
xor edi, edi
mov qword [rsp + 0x58], rdi
mov dword [rsp + 0x48], edi
mov r12d, edi
mov rbp, rdi
mov r13d, edi
mov dword [r14], edi
xor edx, edx
lea r8d, [rdi + 0x30]
lea rcx, [rsp + 0x68]
call sub.msvcrt.dll_memset
lea r11, [rsp + 0x98]
lea esi, [rdi + 3]
cmp r11, rdi
jne 0x10004b4e5
lea ecx, [rdi + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x10004b4fe
lea r8, [rsp + 0x98]
mov edx, 4
mov rcx, rbx
call fcn.10003d658
cmp eax, edi
jne 0x10004b516
lea rdx, [0x10000eff0]
mov ecx, esi
call fcn.100054fd8
mov edi, 0x65b
jmp 0x10004b7b4
mov rax, qword [rsp + 0xa8]
cmp eax, 1
jbe 0x10004b53b
lea rdx, [0x1000116d0]
mov ecx, esi
call fcn.100054fd8
mov edi, 0xd
jmp 0x10004b7b4
cmp eax, edi
jne 0x10004b557
lea rdx, [0x10000f0f0]
mov ecx, esi
call fcn.100054fd8
mov edi, 0xd
jmp 0x10004b7b4
mov eax, edi
mov rdx, qword [rsp + 0x98]
cmp rdx, rdi
setne al
cmp eax, edi
jne 0x10004b576
mov ecx, 0x80004005
call fcn.1000201f8
int3
add rdx, 0x10
lea rcx, [rsp + 0x38]
call fcn.10001f050
mov edx, 0x104
lea rcx, [rsp + 0x100]
mov r8d, edi
lea r9, [0x1000102e0]
lea rax, [rsp + 0x100]
sub r9, rax
lea rax, [rdx + 0x7ffffefa]
cmp rax, rdi
je 0x10004b5c9
movzx eax, word [r9 + rcx]
cmp ax, di
je 0x10004b5c9
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x10004b5a6
cmp rdx, rdi
jne 0x10004b5d8
sub rcx, 2
mov r8d, 0x8007007a
mov word [rcx], di
cmp r8d, edi
jge 0x10004b5ea
mov edi, 0x65b
jmp 0x10004b7b4
mov rbx, qword [rsp + 0x38]
cmp dword [rbx - 8], 1
jle 0x10004b607
mov edx, dword [rbx - 0x10]
lea rcx, [rsp + 0x38]
call fcn.10002009c
mov rbx, qword [rsp + 0x38]
mov r8, rbx
mov edx, 0x104
lea rcx, [rsp + 0x100]
call fcn.100020240
cmp eax, edi
jge 0x10004b62f
mov edi, 0x65b
mov rbx, qword [rsp + 0x40]
jmp 0x10004b7b4
lea rcx, [rsp + 0x68]
call fcn.100043fb8
mov edi, eax
test eax, eax
jne 0x10004b7af
lea r8, [rsp + 0x100]
xor edx, edx
lea rcx, [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CreateMutexW]
mov rbp, rax
test rax, rax
jne 0x10004b66d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
jmp 0x10004b783
mov edx, 0x3e8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x80
je 0x10004b6a9
test eax, eax
je 0x10004b6a9
cmp eax, 0x102
jne 0x10004b69c
mov edi, 0x20
mov rbx, qword [rsp + 0x40]
jmp 0x10004b7b4
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
jmp 0x10004b783
mov r13d, 1
and dword [rsp + 0x30], r12d
lea rax, [rsp + 0x50]
mov qword [rsp + 0x60], rax
lea rdx, [rsp + 0x38]
lea rcx, [rsp + 0x50]
call fcn.100020390
nop
lea rcx, [rsp + 0x48]
mov qword [rsp + 0x28], rcx
lea rcx, [rsp + 0x58]
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x30]
lea r8, [rsp + 0xd0]
mov rdx, rax
mov rcx, qword [rsp + 0x40]
call fcn.10004a09c
mov edi, eax
test eax, eax
je 0x10004b718
mov r9, rbx
mov r8d, eax
lea rdx, [0x100010020]
mov ecx, esi
call fcn.100054fd8
jmp 0x10004b783
mov r12d, dword [rsp + 0x30]
test r12d, r12d
je 0x10004b78e
lea rax, [rsp + 0x50]
mov qword [rsp + 0x60], rax
lea rdx, [rsp + 0x38]
lea rcx, [rsp + 0x50]
call fcn.100020390
nop
lea r9, [rsp + 0x30]
lea r8, [rsp + 0xd0]
mov edx, r15d
mov rcx, rax
call fcn.10004a5e0
test eax, eax
jne 0x10004b775
mov edi, 0x643
mov r8, rbx
lea rdx, [0x1000100b0]
mov ecx, esi
call fcn.100054fd8
mov rbx, qword [rsp + 0x40]
jmp 0x10004b7b4
cmp dword [rsp + 0x30], 0
je 0x10004b78e
mov dword [r14], 1
test edi, edi
je 0x10004b78e
mov rbx, qword [rsp + 0x40]
jmp 0x10004b7b4
lea rcx, [rsp + 0x38]
call fcn.100048e8c
test eax, eax
je 0x10004b806
mov r8d, eax
lea rdx, [0x100011730]
mov ecx, esi
call fcn.100054fd8
jmp 0x10004b806
mov rbx, qword [rsp + 0x40]
lea r8, [0x1000101b0]
mov edx, edi
mov ecx, esi
call fcn.1000550a8
test r13d, r13d
je 0x10004b814
xor eax, eax
test r12d, r12d
setne al
mov qword [rsp + 0x28], r14
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0x48]
mov r8, qword [rsp + 0x58]
lea rdx, [rsp + 0x38]
mov rcx, rbx
call fcn.10004afa4
test eax, eax
je 0x10004b806
mov r8d, eax
lea rdx, [0x100010240]
mov ecx, esi
call fcn.100054fd8
test r13d, r13d
je 0x10004b814
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
test rbp, rbp
je 0x10004b822
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x80]
test rcx, rcx
je 0x10004b835
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov rcx, qword [rsp + 0x88]
test rcx, rcx
je 0x10004b848
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x90]
test rcx, rcx
je 0x10004b85b
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x10004b86b
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
nop
lea rcx, [rsp + 0xd0]
call fcn.10001f994
nop
lea rcx, [rsp + 0x38]
call fcn.10002006c
nop
lea rcx, [rsp + 0x98]
call fcn.10001f994
mov eax, edi
mov rcx, qword [rsp + 0x310]
xor rcx, rsp
call fcn.10006bd80
mov rbx, qword [rsp + 0x378]
add rsp, 0x320
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret