Function at 0x1800051b0
Capabilities:
Check mutex and terminate process on windows
Check mutex on windows
Terminate process
Terminate thread

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x58
mov rax, qword [rsp + 0x60]
mov r9, qword [rax + 0x88]
lea r8, [0x18003bbb8]
xor edx, edx
xor ecx, ecx
call fcn.180003c90
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x28]
inc eax
cdqe
mov rcx, rax
call fcn.180011040
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x88]
lea rdx, str.Global_s_m
mov rcx, qword [rsp + 0x38]
call fcn.180003c40
mov rax, qword [rsp + 0x60]
movzx eax, byte [rax + 0x50]
test eax, eax
jne 0x1800053e8
mov r8, qword [rsp + 0x38]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
mov qword [rsp + 0x30], rax
cmp qword [rsp + 0x30], 0
je 0x18000534e
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x24], eax
cmp dword [rsp + 0x24], 0xb7
je 0x180005261
cmp dword [rsp + 0x24], 5
jne 0x1800052a1
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0xa8], 0
je 0x18000529c
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0x80], 0
je 0x18000529c
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, [0x18003bbd8]
mov rcx, qword [rsp + 0x60]
call fcn.180004250
jmp 0x180005333
lea rdx, [0x18003bbe8]
mov rax, qword [rsp + 0x60]
mov rcx, qword [rax + 0x80]
call fcn.180003b20
test rax, rax
je 0x1800052fb
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0xa8], 0
je 0x1800052f9
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0x80], 0
je 0x1800052f9
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, [0x18003bbf8]
mov rcx, qword [rsp + 0x60]
call fcn.180004250
jmp 0x180005333
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, str.Log:keepalive_loop_break__if__ulLastError__ERROR_ALREADY_EXISTS__ulLastError__ERROR_ACCESS_DENIED__:_s__n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1800053e8
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1800053d8
lea rdx, [0x18003bc80]
mov rax, qword [rsp + 0x60]
mov rcx, qword [rax + 0x80]
call fcn.180003b20
test rax, rax
jne 0x18000537c
mov rcx, qword [rsp + 0x60]
call fcn.1800050b0
movzx eax, al
test eax, eax
je 0x1800053b9
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0xa8], 0
je 0x1800053b7
mov rax, qword [rsp + 0x60]
cmp qword [rax + 0x80], 0
je 0x1800053b7
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, str.KEEPALIVE:_s__n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
jmp 0x1800053d8
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, str.Log:keepalive_loop_break_if__HANDLE_hMutex__CreateMutexA_0__false__pszAttackMutex__:_s__n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
jmp 0x1800053e8
mov ecx, 0x7d0
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x180005215
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, str.Log:keepalive_loop_finished:_s__n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
mov rax, qword [rsp + 0x60]
movzx eax, byte [rax + 0x50]
test eax, eax
jne 0x1800054c7
mov rax, qword [rsp + 0x60]
mov r8, qword [rax + 0x80]
lea rdx, str.Log:keepalive_loop_terminating.._:_s__n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
mov rax, qword [rsp + 0x60]
movzx eax, byte [rax + 0xa0]
test eax, eax
jne 0x180005467
lea rdx, str.Log:TerminateProcess_n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
jmp 0x1800054c7
lea rdx, str.Log:FreeLibraryAndExitThread_FreeLibraryAndExitThreadReflected_n
mov rcx, qword [rsp + 0x60]
call fcn.180004250
mov rax, qword [rsp + 0x60]
add rax, 0x68
mov rcx, rax
call fcn.180005520
mov dword [rsp + 0x20], eax
mov eax, dword [rsp + 0x20]
mov dword [rsp + 0x2c], eax
mov eax, dword [rsp + 0x20]
dec eax
mov dword [rsp + 0x20], eax
cmp dword [rsp + 0x2c], 0
jbe 0x1800054c7
mov eax, dword [rsp + 0x20]
mov rcx, qword [rsp + 0x60]
add rcx, 0x68
mov edx, eax
call fcn.1800054f0
xor edx, edx
mov rcx, qword [rax]
call qword [sym.imp.KERNEL32.dll_TerminateThread]
jmp 0x18000548d
mov rax, qword [rsp + 0x38]
mov qword [rsp + 0x48], rax
mov edx, 1
mov rcx, qword [rsp + 0x48]
call fcn.1800109e0
add rsp, 0x58
ret