Function at 0x140039c10
Capabilities:
Terminate thread

Disassembly:
push rbx
sub rsp, 0x50
cmp byte [r8], 0
mov ebx, 1
je 0x140039cae
xor eax, eax
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x30]
lea r8, [0x140039f10]
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], eax
mov qword [rsp + 0x60], rdi
mov dword [rsp + 0x30], 0xffffffff
call fcn.140034bc0
mov rdi, rax
dec rax
cmp rax, 0xfffffffffffffffd
ja 0x140039ca1
mov edx, 0x7530
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x140039c80
mov ebx, dword [rsp + 0x30]
jmp 0x140039c98
cmp eax, 0x102
jne 0x140039c98
mov ebx, 2
mov rcx, rdi
lea edx, [rbx - 1]
call qword [sym.imp.KERNEL32.dll_TerminateThread]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov rdi, qword [rsp + 0x60]
add rsp, 0x50
pop rbx
ret
add rsp, 0x50
pop rbx
jmp 0x140039d00
mov rax, rsp
push rbp
push rdi
push r14
lea rbp, [rax - 0x5f]
sub rsp, 0xa0
mov qword [rbp + 0x37], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov rdi, rdx
mov rsi, rcx
mov ebx, 1
xor r14d, r14d
mov qword [rbp - 1], r14
lea rax, [rbp - 1]
mov qword [rsp + 0x20], rax
lea r9, [0x140129110]
xor edx, edx
lea r8d, [rbx + 3]
lea rcx, [0x14012e270]
call fcn.1400344b0
test eax, eax
js 0x140039ef4
mov qword [rbp + 7], r14
mov qword [rbp - 0x11], r14
lea rcx, [rbp + 0x1f]
call fcn.140037ca0
nop
mov rcx, qword [rbp - 1]
mov rax, qword [rcx]
lea rdx, [rbp - 0x11]
mov qword [rsp + 0x30], rdx
mov dword [rsp + 0x28], ebx
lea rdx, [rbp + 7]
mov qword [rsp + 0x20], rdx
lea r9d, [rbx + 7]
lea r8, [rbp + 0x1f]
lea rdx, [rbp + 0x1f]
call qword [rax + 0x78]
test eax, eax
jne 0x140039edd
mov rax, qword [rbp + 7]
dec rax
cmp rax, 0xfffffffffffffffd
ja 0x140039ecf
lea r9, [rbp + 0xf]
lea r8, [0x140129120]
lea rdx, [0x14012c290]
mov rcx, qword [rbp - 0x11]
call fcn.140035730
test eax, eax
js 0x140039ecf
mov qword [rbp - 0x19], r14
mov rcx, qword [rbp + 0xf]
mov rax, qword [rcx]
lea rdx, [rbp - 0x19]
call qword [rax + 0x78]
test eax, eax
js 0x140039ec5
mov qword [rbp - 9], r14
mov rcx, qword [rbp - 0x19]
mov rax, qword [rcx]
lea r9, [rbp - 9]
lea r8, [0x140129100]
xor edx, edx
call qword [rax + 0x78]
test eax, eax
js 0x140039eb7
mov dword [rbp + 0x77], r14d
lea rdx, [rbp + 0x77]
mov rcx, qword [rbp + 7]
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
test eax, eax
je 0x140039e38
mov ecx, dword [rbp + 0x77]
test ecx, ecx
je 0x140039e38
call qword [sym.imp.USER32.dll_AllowSetForegroundWindow]
mov qword [rbp + 0x7f], r14
mov rcx, qword [rbp - 9]
mov rax, qword [rcx]
lea r8, [rbp + 0x7f]
lea rdx, [0x140129130]
call qword [rax]
test eax, eax
js 0x140039ea9
mov qword [rbp + 0x77], r14
mov rcx, qword [rbp + 0x7f]
mov rax, qword [rcx]
lea rdx, [rbp + 0x77]
call qword [rax + gethostname]
test eax, eax
js 0x140039e9b
mov rcx, qword [rbp + 0x77]
mov rax, qword [rcx]
lea r8, [rbp + 0x17]
lea rdx, [0x140129140]
call qword [rax]
test eax, eax
js 0x140039e8d
mov rdx, rdi
mov rcx, qword [rbp + 0x17]
call rsi
mov ebx, eax
mov rcx, qword [rbp + 0x77]
mov rdx, qword [rcx]
call qword [rdx + reloc.WS2_32.dll_recv]
mov qword [rbp + 0x77], r14
mov rcx, qword [rbp + 0x7f]
mov rdx, qword [rcx]
call qword [rdx + reloc.WS2_32.dll_recv]
mov qword [rbp + 0x7f], r14
mov rcx, qword [rbp - 9]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov qword [rbp - 9], r14
mov rcx, qword [rbp - 0x19]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov qword [rbp - 0x19], r14
mov rcx, qword [rbp + 0xf]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov rcx, qword [rbp - 0x11]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov qword [rbp - 0x11], r14
mov rcx, qword [rbp - 1]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov qword [rbp - 1], r14
lea rcx, [rbp + 0x1f]
call fcn.140037bf0
mov eax, ebx
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret