Function at 0x10004907c
Capabilities:
Check mutex on windows

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x370
mov qword [rsp + 0x118], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov rax, qword [0x100083138]
xor rax, rsp
mov qword [rsp + 0x360], rax
mov rdi, r9
mov qword [rsp + 0x38], r9
mov r15d, r8d
mov r14d, edx
mov r13, rcx
lea rcx, [rsp + 0x50]
call fcn.100020360
nop
lea rcx, [rsp + 0xe8]
call fcn.1000193b8
nop
lea rcx, [rsp + 0x40]
call fcn.100020360
nop
xor ebx, ebx
mov esi, ebx
mov dword [rsp + 0x30], ebx
lea rcx, [rsp + 0x60]
call fcn.100020360
nop
mov qword [rsp + 0x68], rbx
mov dword [rsp + 0x58], ebx
lea rcx, [rsp + 0xb8]
call fcn.1000193b8
nop
mov r12, rbx
mov dword [rsp + 0x48], ebx
mov dword [rdi], ebx
xor edx, edx
lea r8d, [rbx + 0x30]
lea rcx, [rsp + 0x120]
call sub.msvcrt.dll_memset
lea r11, [rsp + 0xe8]
lea ebp, [rbx + 3]
cmp r11, rbx
jne 0x100049149
lea ecx, [rbx + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x100049162
lea r8, [rsp + 0xe8]
mov edx, 4
mov rcx, r13
call fcn.10003d658
cmp eax, ebx
jne 0x10004917a
lea rdx, [0x10000eff0]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x65b
jmp 0x1000496a7
mov rax, qword [rsp + 0xf8]
cmp eax, 1
jbe 0x10004919f
lea rdx, [0x1000112e0]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0xd
jmp 0x1000496a7
cmp eax, ebx
jne 0x1000491bb
lea rdx, [0x10000f0f0]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0xd
jmp 0x1000496a7
mov eax, ebx
mov rdx, qword [rsp + 0xe8]
cmp rdx, rbx
setne al
cmp eax, ebx
jne 0x1000491da
mov ecx, 0x80004005
call fcn.1000201f8
int3
add rdx, 0x10
lea rcx, [rsp + 0x40]
call fcn.10001f050
mov edx, 0x104
lea rcx, [rsp + 0x150]
mov edi, ebx
lea rsi, [0x1000102e0]
lea rax, [rsp + 0x150]
sub rsi, rax
lea rax, [rdx + 0x7ffffefa]
cmp rax, rbx
je 0x10004922b
movzx eax, word [rcx + rsi]
cmp ax, bx
je 0x10004922b
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x100049209
test rdx, rdx
jne 0x100049239
sub rcx, 2
mov edi, 0x8007007a
and word [rcx], r12w
test edi, edi
jns 0x100049253
mov ebx, 0x65b
mov rdi, qword [rsp + 0x38]
mov esi, r12d
jmp 0x1000496a7
mov r8, qword [rsp + 0x40]
cmp dword [r8 - 8], 1
jle 0x100049272
mov edx, dword [r8 - 0x10]
lea rcx, [rsp + 0x40]
call fcn.10002009c
mov r8, qword [rsp + 0x40]
mov edx, 0x104
lea rcx, [rsp + 0x150]
call fcn.100020240
test eax, eax
jns 0x10004929a
mov ebx, 0x65b
mov rdi, qword [rsp + 0x38]
mov esi, r12d
jmp 0x1000496a7
lea rcx, [rsp + 0x120]
call fcn.100043fb8
mov ebx, eax
test eax, eax
jne 0x10004968e
lea r8, [rsp + 0x150]
xor edx, edx
lea rcx, [rsp + 0x120]
call qword [sym.imp.KERNEL32.dll_CreateMutexW]
mov r12, rax
test rax, rax
jne 0x1000492e3
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rdi, qword [rsp + 0x38]
jmp 0x100049660
mov edx, 0x3e8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x80
je 0x100049328
test eax, eax
je 0x100049328
cmp eax, 0x102
jne 0x100049316
mov ebx, 0x20
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rdi, qword [rsp + 0x38]
jmp 0x100049660
mov dword [rsp + 0x48], 1
and dword [rsp + 0x5c], 0
lea rax, [rsp + 0x70]
mov qword [rsp + 0x78], rax
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x70]
call fcn.100020390
nop
lea rcx, [rsp + 0x58]
mov qword [rsp + 0x28], rcx
lea rcx, [rsp + 0x68]
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x60]
lea r8, [rsp + 0x5c]
mov rdx, rax
mov rcx, r13
call fcn.1000488cc
mov ebx, eax
test eax, eax
jne 0x100049698
mov edx, dword [rsp + 0x5c]
mov dword [rsp + 0x30], edx
xor eax, eax
lea rdi, [0x100005b90]
mov rsi, qword [rsp + 0x60]
lea r8d, [rbx + 1]
mov rcx, r8
repe cmpsw word [rsi], word [rdi]
je 0x1000493a9
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x10004947c
test edx, edx
je 0x1000493d0
test r15d, r15d
jne 0x1000493d0
lea rdx, [0x10000f610]
mov ecx, r8d
call fcn.100054fd8
xor ebx, ebx
jmp 0x100049664
lea rax, [rsp + 0x50]
test rax, rax
jne 0x1000493e5
lea ecx, [rax + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1000493fb
lea r8, [rsp + 0x50]
mov edx, 2
mov rcx, r13
call fcn.10003d2d8
test eax, eax
jne 0x10004941c
lea rdx, [0x10000cc10]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x643
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
cmp r14d, 9
jne 0x1000495e7
lea rax, [rsp + 0xb8]
test rax, rax
jne 0x10004943e
lea ecx, [rax + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x10004945b
lea r8, [rsp + 0xb8]
mov edx, 8
mov rcx, r13
call fcn.10003d658
test eax, eax
jne 0x1000495e7
lea rdx, [0x100011370]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x643
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
test r15d, r15d
je 0x10004964a
lea rcx, [rsp + 0x80]
call fcn.10003cdb4
nop
lea rax, [rsp + 0x70]
mov qword [rsp + 0x78], rax
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x70]
call fcn.100020390
nop
mov r8d, ebp
mov rdx, rax
lea rcx, [rsp + 0x80]
call fcn.10003cf1c
cmp eax, 0xb7
je 0x1000494fa
mov r8, qword [rsp + 0x60]
lea rdx, [0x10000f5c0]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x643
lea rcx, [rsp + 0x80]
call fcn.10003ce68
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
lea rax, [rsp + 0x50]
test rax, rax
jne 0x10004950f
lea ecx, [rax + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x10004952a
lea r8, [rsp + 0x50]
mov edx, 2
lea rcx, [rsp + 0x80]
call fcn.10003d2d8
test eax, eax
jne 0x100049558
lea rdx, [0x10000cc10]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x643
lea rcx, [rsp + 0x80]
call fcn.10003ce68
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
cmp r14d, 9
jne 0x1000495c2
lea rax, [rsp + 0xb8]
test rax, rax
jne 0x100049576
lea ecx, [rax + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x100049594
lea r8, [rsp + 0xb8]
mov edx, 8
lea rcx, [rsp + 0x80]
call fcn.10003d658
test eax, eax
jne 0x1000495c2
lea rdx, [0x100011370]
mov ecx, ebp
call fcn.100054fd8
mov ebx, 0x643
lea rcx, [rsp + 0x80]
call fcn.10003ce68
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
cmp dword [rsp + 0xa8], 0
je 0x1000495da
lea rcx, [rsp + 0x80]
call fcn.10003d1ac
nop
lea rcx, [rsp + 0x80]
call fcn.10003ce68
mov r9d, r14d
mov r8, qword [rsp + 0x50]
lea rdx, [0x10000f6e0]
mov ecx, 1
call fcn.100054fd8
cmp r14d, 5
je 0x10004962f
cmp r14d, 9
jne 0x100049664
mov rdi, qword [rsp + 0x38]
mov r9, rdi
lea r8, [rsp + 0xb8]
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x50]
call fcn.100045480
mov ebx, eax
jmp 0x100049660
mov rdi, qword [rsp + 0x38]
mov r8, rdi
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x50]
call fcn.100044dfc
mov ebx, eax
jmp 0x100049660
lea rdx, [0x10000f610]
mov ecx, r8d
call fcn.100054fd8
xor ebx, ebx
mov rdi, qword [rsp + 0x38]
test ebx, ebx
jne 0x1000496a3
lea rcx, [rsp + 0x40]
call fcn.100048e8c
test eax, eax
je 0x1000496f8
mov r8d, eax
lea rdx, [0x10000f850]
mov ecx, ebp
call fcn.100054fd8
mov r13d, dword [rsp + 0x48]
jmp 0x1000496fd
mov rdi, qword [rsp + 0x38]
mov esi, r12d
jmp 0x1000496a7
mov rdi, qword [rsp + 0x38]
mov esi, dword [rsp + 0x30]
jmp 0x1000496a7
mov esi, dword [rsp + 0x30]
lea r8, [0x10000f730]
mov edx, ebx
mov ecx, ebp
call fcn.1000550a8
mov r13d, dword [rsp + 0x48]
test r13d, r13d
je 0x10004970b
test esi, esi
jne 0x1000496fd
mov qword [rsp + 0x20], rdi
mov r9d, dword [rsp + 0x58]
mov r8, qword [rsp + 0x68]
mov edx, r14d
lea rcx, [rsp + 0x40]
call fcn.100048a0c
test eax, eax
je 0x1000496fd
mov r8d, eax
lea rdx, [0x10000f7c0]
mov ecx, ebp
call fcn.100054fd8
jmp 0x1000496fd
mov r13d, dword [rsp + 0x48]
test r13d, r13d
je 0x10004970b
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
test r12, r12
je 0x100049719
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x138]
test rcx, rcx
je 0x10004972c
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov rcx, qword [rsp + 0x140]
test rcx, rcx
je 0x10004973f
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x148]
test rcx, rcx
je 0x100049752
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x68]
test rcx, rcx
je 0x100049762
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
nop
lea rcx, [rsp + 0xb8]
call fcn.10001f994
nop
lea rcx, [rsp + 0x60]
call fcn.10002006c
nop
lea rcx, [rsp + 0x40]
call fcn.10002006c
nop
lea rcx, [rsp + 0xe8]
call fcn.10001f994
nop
lea rcx, [rsp + 0x50]
call fcn.10002006c
mov eax, ebx
mov rcx, qword [rsp + 0x360]
xor rcx, rsp
call fcn.10006bd80
mov rbx, qword [rsp + 0x3c0]
add rsp, 0x370
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret