Function at 0x180059620
Capabilities:
Check os version
Create thread

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x18], r8
mov qword [rsp + 8], rcx
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x110
mov r13, r9
mov esi, edx
mov rbx, rcx
test rcx, rcx
jne 0x18005965b
mov eax, 0xc00000ef
jmp 0x180059f86
mov eax, esi
and eax, 0xf000
cmp eax, 0x2000
je 0x180059673
mov eax, 0xc00000f0
jmp 0x180059f86
mov r15d, dword [rsp + 0x168]
cmp byte [rsp + 0x180], 1
jne 0x1800596ce
test r15d, r15d
jne 0x180059694
mov eax, 0xc00000f4
jmp 0x180059f86
mov r14d, dword [rsp + 0x170]
test r14d, r14d
je 0x1800596c4
test sil, 2
je 0x1800596ad
cmp r14d, 0x10
ja 0x1800596c4
mov r12d, dword [rsp + 0x178]
test r12d, r12d
jne 0x1800596de
mov eax, 0xc00000f6
jmp 0x180059f86
mov eax, 0xc00000f5
jmp 0x180059f86
mov r12d, dword [rsp + 0x178]
mov r14d, dword [rsp + 0x170]
cmp r15d, 0x10000000
ja 0x18005968a
test sil, 2
lea r9, [0x18004e220]
mov eax, 0
cmovne r9, rax
or edx, 8
mov r8d, 0x2600
call fcn.18004f400
mov edi, eax
mov dword [rsp + 0x50], eax
test eax, eax
js 0x180059f86
cmp byte [rsp + 0x180], 1
jne 0x18005974c
mov r8d, esi
mov edx, dword [rsp + 0x160]
mov rcx, rbx
call fcn.18004ebb0
mov edi, eax
mov dword [rsp + 0x50], eax
test eax, eax
jns 0x18005974c
mov rcx, rbx
call fcn.18004f4b0
mov eax, edi
jmp 0x180059f86
test r13, r13
jne 0x180059762
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov eax, eax
mov qword [rbx + 0xa0], rax
jmp 0x180059769
mov qword [rbx + 0xa0], r13
lea rsi, [rbx + 0x170]
mov rax, rsi
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x80], rax
lea r13, [rbx + 0x80]
lea r9, [0x180059140]
mov r8, qword [rbx + 0xa0]
mov rdx, qword [rsp + 0x150]
mov rcx, r13
call fcn.18005af70
test eax, eax
js 0x180059dff
lea rcx, [rbx + 0x160]
lea r8, str.ProcessingMsgSrw
xor edx, edx
call fcn.180055750
mov dword [rsp + 0x64], eax
test eax, eax
js 0x180059dff
lea rcx, [rbx + 0x100]
mov byte [rsp + 0x20], 0
mov r9d, 1
xor r8d, r8d
mov edx, 0x1f0003
call qword [0x18009b4d0]
test eax, eax
js 0x180059dff
xor r8d, r8d
mov qword [rbx + 0x120], r8
mov qword [rbx + 0x108], r8
mov dword [rbx + 0x110], r8d
mov qword [rbx + 0x118], r8
mov dword [rbx + 0xf8], r8d
mov dword [rsp + 0x64], r8d
mov dword [rbx + 0x200], r8d
mov dword [rbx + 0x204], r8d
mov rax, qword [rsp + 0x188]
mov qword [rbx + 0x128], rax
mov dword [rbx + 0x1f8], r8d
mov dword [rbx + 0x1fc], r8d
cmp byte [rsp + 0x180], r8b
jne 0x1800599c4
mov byte [rbx + 0xe4], r8b
mov dword [rbx + 0xc8], r8d
lea r13, [rbx + 0x148]
mov byte [rsp + 0x20], r8b
xor r9d, r9d
mov edx, 0x1f0003
mov rcx, r13
call qword [0x18009b4d0]
test eax, eax
js 0x180059dff
lea r14, [rbx + 0x150]
mov byte [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
mov edx, 0x1f0003
mov rcx, r14
call qword [0x18009b4d0]
test eax, eax
js 0x180059dff
mov dword [rsp + 0x98], 0x30
xor ecx, ecx
mov qword [rsp + 0xa0], rcx
mov dword [rsp + 0xb0], ecx
lea rax, [rbx + 0x80]
mov qword [rsp + 0xa8], rax
xorps xmm0, xmm0
movdqu xmmword [rsp + 0xb8], xmm0
lea r8, [rsp + 0x98]
lea edx, [rcx + 6]
lea rcx, [rbx + 0xa8]
call qword [0x18009b488]
test eax, eax
js 0x180059dff
lea rax, [rbx + 0xb8]
mov dword [rsp + 0x48], 0x204
xor ecx, ecx
mov dword [rsp + 0x40], ecx
mov dword [rsp + 0x38], 2
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], rcx
mov qword [rsp + 0x20], rcx
xor r9d, r9d
lea r8, [rbx + 0xb0]
or rdx, 0xffffffffffffffff
mov rcx, qword [rbx + 0xa8]
call qword [0x18009b490]
test eax, eax
js 0x180059dff
mov rax, qword [rbx + 0xb0]
mov ecx, dword [rax + 0x2c]
mov dword [rbx + 0xe0], ecx
test rsi, rsi
je 0x180059dfa
lea rax, [rsp + 0x68]
mov qword [rsp + 0x28], rax
xor r12d, r12d
mov dword [rsp + 0x20], r12d
mov r9, rbx
lea r8, [0x18005a840]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rsi], rax
test rax, rax
jne 0x1800599bb
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx eax, ax
or eax, 0xe8f00000
jge 0x180059d2a
jmp 0x180059dff
mov eax, dword [rsp + 0x68]
jmp 0x180059d22
mov dword [rbx + 0xe0], r15d
mov edx, r15d
add rdx, 0x20
mov eax, r12d
imul rdx, rax
lea ecx, [r14 - 1]
add rcx, 2
imul rcx, rcx, 0x38
add rcx, rdx
lea r15, [rbx + 0xb8]
mov dword [r15], ecx
mov dword [rsp + 0x98], 0x30
mov qword [rsp + 0xa0], r8
mov dword [rsp + 0xb0], r8d
mov qword [rsp + 0xa8], r13
xorps xmm0, xmm0
movdqu xmmword [rsp + 0xb8], xmm0
mov dword [rsp + 0x7c], r8d
mov dword [rsp + 0x78], ecx
mov qword [rsp + 0x30], r8
mov dword [rsp + 0x28], 0x8000000
mov dword [rsp + 0x20], 4
lea r9, [rsp + 0x78]
lea r8, [rsp + 0x98]
mov edx, 0xf001f
lea rcx, [rbx + 0xa8]
call qword [0x18009b480]
test eax, eax
js 0x180059dff
lea rsi, [rbx + 0xb0]
mov eax, dword [r15]
mov dword [rsp + 0x48], 0x204
xor ecx, ecx
mov dword [rsp + 0x40], ecx
mov dword [rsp + 0x38], 2
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x28], rcx
mov qword [rsp + 0x20], rax
xor r9d, r9d
mov r8, rsi
or rdx, 0xffffffffffffffff
mov rcx, qword [rbx + 0xa8]
call qword [0x18009b490]
mov dword [rsp + 0x64], eax
test eax, eax
js 0x180059dff
mov r8d, dword [r15]
xor edx, edx
mov rcx, qword [rsi]
call fcn.18005f850
mov r10, qword [rsi]
mov qword [rsp + 0xd8], r10
mov eax, dword [rbx + 0xe0]
mov dword [r10 + 0x2c], eax
mov eax, dword [rbx + 0xe0]
add eax, 0x20
mov dword [r10 + 0x30], eax
xor r13d, r13d
mov r9d, r13d
mov dword [rsp + 0x60], r13d
cmp r9d, r14d
jae 0x180059b5a
mov eax, r9d
imul rcx, rax, 0x38
lea r8, [rcx + r10]
xor eax, eax
mov qword [r8 + 0x38], rax
mov qword [r8 + 0x40], rax
mov qword [r8 + 0x48], rax
mov qword [r8 + 0x50], rax
mov qword [r8 + 0x58], rax
mov qword [r8 + 0x60], rax
mov qword [r8 + 0x68], rax
lea rdx, [rcx + r10]
mov rax, qword [rsi]
mov dword [rdx + 0x60], r13d
lea rcx, [rdx + 0x50]
sub rcx, rax
mov qword [rdx + 0x50], rcx
mov qword [rdx + 0x58], rcx
mov rax, qword [rsi]
mov dword [r8 + 0x48], r13d
lea rcx, [r8 + 0x38]
sub rcx, rax
mov qword [r8 + 0x38], rcx
mov qword [r8 + 0x40], rcx
inc r9d
mov dword [rsp + 0x60], r9d
jmp 0x180059af2
mov rax, qword [rsi]
mov dword [r10 + 0x10], r13d
mov rcx, r10
sub rcx, rax
mov qword [r10], rcx
mov qword [r10 + 8], rcx
lea ecx, [r14 - 1]
add rcx, 2
imul r8, rcx, 0x38
add r8, r10
mov qword [rsp + 0x88], r8
mov edx, r13d
mov dword [rsp + 0x60], edx
cmp edx, r12d
jae 0x180059bf0
mov ecx, dword [rbx + 0xb8]
mov r9, qword [rsi]
add rcx, r9
mov r11, qword [r10 + 8]
lea rax, [r9 + 0x10]
add rax, r11
cmp rax, rcx
ja 0x180059bdd
mov rax, qword [r11 + r9]
mov qword [r8], rax
mov rax, qword [r10 + 8]
mov qword [r8 + 8], rax
mov rax, r8
sub rax, r9
mov qword [r10 + 8], rax
mov qword [r11 + r9], rax
mov eax, dword [r10 + 0x30]
add r8, rax
mov qword [rsp + 0x88], r8
inc edx
jmp 0x180059b88
mov edi, 0xe8000011
mov dword [rsp + 0x50], edi
mov r15, qword [rsp + 0x58]
jmp 0x180059e0d
mov byte [rbx + 0xe4], 1
mov dword [rbx + 0xe8], r12d
mov rax, qword [rsp + 0x190]
mov qword [rbx + 0x130], rax
mov rax, qword [rsp + 0x198]
mov qword [rbx + 0x138], rax
mov dword [rbx + 0x1f4], r14d
mov eax, r14d
lea r8, [rax + rax*8]
shl r8, 3
lea rcx, [rbx + 0x280]
xor edx, edx
call fcn.18005f850
lea r13, [rbx + 0x148]
mov qword [rsp + 0x28], r13
mov byte [rsp + 0x20], 0
xor r9d, r9d
mov r8d, 0x1f0003
lea rdx, str._TearDown
mov rcx, qword [rbx + 0x88]
call fcn.1800593d0
test eax, eax
js 0x180059dff
lea rcx, [rbx + 0x158]
mov byte [rsp + 0x20], 1
xor r9d, r9d
xor r8d, r8d
mov edx, 0x1f0003
call qword [0x18009b4d0]
test eax, eax
js 0x180059dff
lea r14, [rbx + 0x150]
mov qword [rsp + 0x28], r14
mov byte [rsp + 0x20], 0
xor r9d, r9d
mov r8d, 0x1f0003
lea rdx, str._PortAvailable
mov rcx, qword [rbx + 0x88]
call fcn.1800593d0
test eax, eax
js 0x180059dff
lea rsi, [rbx + 0x170]
test rsi, rsi
je 0x180059dfa
lea rax, [rsp + 0x6c]
mov qword [rsp + 0x28], rax
xor r12d, r12d
mov dword [rsp + 0x20], r12d
mov r9, rbx
lea r8, [0x18005bcd0]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rsi], rax
test rax, rax
jne 0x180059d1e
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx eax, ax
or eax, 0xe8f00000
jge 0x180059d2a
jmp 0x180059dff
mov eax, dword [rsp + 0x6c]
mov qword [rsp + 0x90], rax
mov rax, qword [r14]
mov qword [rsp + 0xc8], rax
mov rax, qword [r13]
mov qword [rsp + 0xd0], rax
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 2]
lea rcx, [rsp + 0xc8]
call fcn.18005e090
test eax, eax
jne 0x180059d71
xor r13d, r13d
mov edi, r13d
mov dword [rsp + 0x50], r13d
mov r15, qword [rsp + 0x58]
jmp 0x180059e0d
cmp eax, 1
jne 0x180059dff
mov r15, qword [rsp + 0x58]
mov r14, qword [r15]
test r14, r14
jne 0x180059d8e
mov eax, 0xc00000ef
jmp 0x180059df4
xor r8d, r8d
xor edx, edx
mov rcx, r14
call qword [0x18009b4e8]
mov esi, eax
mov dword [rsp + 0x70], eax
test eax, eax
js 0x180059df0
call qword [sym.imp.KERNEL32.dll_GetVersion]
cmp ax, 5
jne 0x180059dbc
mov edi, r12d
mov dword [rsp + 0x50], r12d
jmp 0x180059dee
mov qword [rsp + 0x20], r12
mov r9d, 0x30
lea r8, [rsp + 0xe0]
xor edx, edx
mov rcx, r14
call qword [0x18009b3c8]
mov esi, eax
mov dword [rsp + 0x70], eax
test eax, eax
cmovns edi, dword [rsp + 0xe0]
mov dword [rsp + 0x50], edi
mov eax, esi
test esi, esi
jns 0x180059e0a
mov dword [rsp + 0x50], eax
jmp 0x180059e08
mov eax, 0xc00000f1
mov dword [rsp + 0x50], eax
mov r15, qword [rsp + 0x58]
mov edi, eax
xor r13d, r13d
test edi, edi
jns 0x180059745
mov rcx, qword [rbx + 0x148]
test rcx, rcx
je 0x180059e69
xor edx, edx
call qword [0x18009b4d8]
test eax, eax
js 0x180059745
mov rcx, qword [r15]
test rcx, rcx
je 0x180059e55
xor r8d, r8d
xor edx, edx
call qword [0x18009b4e8]
test eax, eax
js 0x180059745
mov rcx, qword [r15]
call qword [0x18009b4c8]
mov rcx, qword [rbx + 0x148]
call qword [0x18009b4c8]
mov qword [rbx + 0x148], r13
lea rsi, [rbx + 0x88]
cmp qword [rsi], 0
je 0x180059ec7
test rsi, rsi
je 0x180059ec7
mov r8, qword [rsi]
test r8, r8
je 0x180059ec7
cmp byte [0x18009b380], 0
je 0x180059eb5
mov r9d, 0x4b5
lea rax, str.ptportshmem.c
mov qword [rsp + 0x20], rax
mov r8d, 0x4d545250
mov rdx, rsi
lea rcx, [0x18009cc40]
call fcn.18004be40
jmp 0x180059ec4
xor edx, edx
mov rcx, qword [0x18009ccf0]
call qword [0x18009b440]
mov qword [rsi], r13
mov rcx, qword [rbx + 0x150]
test rcx, rcx
je 0x180059ee0
call qword [0x18009b4c8]
mov qword [rbx + 0x150], r13
mov rcx, qword [rbx + 0x100]
test rcx, rcx
je 0x180059ef9
call qword [0x18009b4c8]
mov qword [rbx + 0x100], r13
cmp byte [rsp + 0x180], 1
jne 0x180059f1c
mov rcx, qword [rbx + 0x158]
test rcx, rcx
je 0x180059f1c
call qword [0x18009b4c8]
mov qword [rbx + 0x158], r13
mov rdx, qword [rbx + 0xb0]
test rdx, rdx
je 0x180059f41
or rcx, 0xffffffffffffffff
call qword [0x18009b498]
test eax, eax
js 0x180059745
mov qword [rbx + 0xb0], r13
mov rcx, qword [rbx + 0xa8]
test rcx, rcx
je 0x180059f5a
call qword [0x18009b4c8]
mov qword [rbx + 0xa8], r13
lea rcx, [rbx + 0x160]
cmp qword [rcx], 0
je 0x180059f6c
call fcn.180055a50
mov rcx, rbx
cmp byte [rbx + 0xe4], 1
jne 0x180059740
call fcn.18004f050
jmp 0x180059745
lea r11, [rsp + 0x110]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret