Function at 0x1000d1d0
Capabilities:
Check for time delay via gettickcount
Create thread
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x1016f008
push 0x10118480
mov eax, dword fs:[0]
push eax
sub esp, 0x9ac
mov eax, dword [0x1017455c]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov esi, dword [ebp + 0x18]
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x9b0], eax
mov dword [ebp - 0x9ac], ecx
mov dword [ebp - 0x9a8], edx
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x9b8], eax
mov ecx, dword [ebp + 0x24]
mov dword [ebp - 0x99c], ecx
xor edi, edi
mov dword [ebp - 0x990], edi
push 0x850
push edi
lea edx, [ebp - 0x98c]
push edx
call fcn.10116880
add esp, 0xc
mov dword [ebp - 0x9a0], 1
mov dword [ebp - 4], edi
mov ecx, dword [ebp + 8]
lea edx, [ebp - 0x128]
lea esp, [esp]
mov al, byte [ecx]
mov byte [edx], al
inc ecx
inc edx
test al, al
jne 0x1000d270
push 0x10149038
lea eax, [ebp - 0x128]
push eax
call fcn.1010ddc0
add esp, 8
cmp eax, edi
je 0x1000d295
mov byte [eax], 0
lea ecx, [esi - 0x2710]
cmp ecx, 0xc350
jbe 0x1000d2c5
mov eax, 0xcccccccd
mul esi
shr edx, 3
lea edx, [edx + edx*4]
add edx, edx
mov eax, esi
sub eax, edx
cmp eax, 2
mov dword [ebp - 0x994], 0x2710
jne 0x1000d2cb
mov dword [ebp - 0x994], esi
lea ecx, [ebp - 0x128]
push ecx
lea edx, [ebp - 0x65c]
push edx
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
call esi
push ebx
lea eax, [ebp - 0x350]
push eax
call esi
push 0x1013f817
lea ecx, [ebp - 0x760]
push ecx
call esi
push 0x1013f817
lea edx, [ebp - 0x346]
push edx
call esi
mov ecx, 0x1014615c
lea edx, [ebp - 0x558]
movzx eax, word [ecx]
mov word [edx], ax
add ecx, 2
add edx, 2
cmp ax, di
jne 0x1000d312
push 0x1013f817
lea eax, [ebp - 0x242]
push eax
call esi
mov dword [ebp - 0x764], edi
mov dword [ebp - 0x768], edi
mov dword [ebp - 0x988], edi
mov dword [ebp - 0x98c], edi
mov dword [ebp - 0x984], edi
mov ecx, dword [ebp + 0x14]
mov dword [ebp - 0x990], ecx
mov edx, dword [ebp - 0x994]
mov dword [ebp - 0x974], edx
cmp dword [ebp - 0x9a8], edi
je 0x1000d375
mov eax, dword [ebp - 0x9a8]
mov byte [eax], 0
mov eax, dword [ebp - 0x9ac]
cmp eax, edi
je 0x1000d382
mov byte [eax], 0
mov eax, dword [ebp - 0x9b0]
cmp eax, edi
je 0x1000d38f
mov byte [eax], 0
lea ecx, [ebp - 0x998]
push ecx
push 0
lea edx, [ebp - 0x990]
push edx
push 0x1000ca20
push 0
push 0
call fcn.1010f4a0
add esp, 0x18
mov edi, eax
mov dword [ebp - 0x9bc], edi
test edi, edi
jne 0x1000d3ed
mov eax, dword [ebp - 0x99c]
test eax, eax
je 0x1000d3cc
mov dword [eax], 1
mov eax, dword [ebp - 0x9b8]
test eax, eax
je 0x1000d3dc
mov dword [eax], 0
mov dword [ebp - 4], 0xfffffffe
mov eax, 1
jmp 0x1000d868
mov dword [ebp - 0x9b4], 0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x9a4], eax
cmp dword [0x101902a8], 0
je 0x1000d429
lea eax, [ebp - 0x128]
push eax
mov ecx, dword [ebp - 0x998]
push ecx
push str.NEWTHREAD__x_:_IsConnectionActive___for___s_
push 0
call fcn.10053700
add esp, 0x10
push ebx
call fcn.1010dc05
add esp, 4
movzx eax, ax
mov edx, 2
mov word [ebp - 0x138], dx
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x136], ax
lea eax, [ebp - 0x128]
push eax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [ebp - 0x134], eax
cmp eax, 0xffffffff
je 0x1000d489
mov dword [ebp - 0x9b4], 1
mov eax, dword [ebp - 0x9ac]
test eax, eax
je 0x1000d489
lea ecx, [ebp - 0x128]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
nop
cmp dword [ebp - 0x98c], 0
jne 0x1000d49f
push 1
call esi
jmp 0x1000d490
mov eax, dword [ebp - 0x9b8]
test eax, eax
je 0x1000d4ab
mov dword [eax], edi
mov eax, dword [ebp - 0x99c]
test eax, eax
je 0x1000d4bb
mov dword [eax], 1
cmp dword [0x101902a8], 0
je 0x1000d4d3
push str.WaitForSingleObjectEx...
push 0
call fcn.10053700
add esp, 8
cmp dword [0x1018fe94], 0
jne 0x1000d4ee
push 0
mov ebx, dword [ebp - 0x994]
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObjectEx]
jmp 0x1000d505
mov edx, dword [ebp - 0x994]
push edx
mov ebx, edi
call fcn.1000bf70
add esp, 4
mov ebx, dword [ebp - 0x994]
mov esi, eax
cmp dword [0x101902a8], 0
je 0x1000d540
cmp esi, 0x102
jne 0x1000d520
push eax
push str.WaitForSingleObjectEx_Returned__WaitRes___d__WAIT_TIMEOUT__...
jmp 0x1000d532
test esi, esi
jne 0x1000d52c
push esi
push str.WaitForSingleObjectEx_Returned__WaitRes___d__WAIT_OBJECT_0__...
jmp 0x1000d532
push esi
push str.WaitForSingleObjectEx_Returned__WaitRes___d__NON_WAIT_TIMEOUT__...
push 0
call fcn.10053700
add esp, 0xc
lea esp, [esp]
cmp esi, 0x102
jne 0x1000d796
mov eax, dword [ebp + 0x28]
test eax, eax
je 0x1000d59d
cmp dword [eax], 1
jne 0x1000d59d
cmp dword [ebp - 0x980], 0
je 0x1000d59d
lea eax, [ebp - 0x99c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
cmp eax, 1
jne 0x1000d796
cmp dword [ebp - 0x99c], 0x103
jne 0x1000d796
mov ecx, dword [ebp - 0x980]
mov dword [ecx], eax
push 0x14
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x1000d796
cmp dword [0x101902a8], 0
je 0x1000d5bc
mov edx, dword [ebp - 0x768]
push edx
push str._Stage:__d._Wait_Timeout
push 0
call fcn.10053700
add esp, 0xc
mov eax, dword [ebp - 0x768]
cmp eax, 3
je 0x1000d6c1
cmp eax, 1
je 0x1000d6b7
inc dword [ebp - 0x9a0]
cmp dword [0x1018fe94], 0
jne 0x1000d5ef
push 0
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObjectEx]
jmp 0x1000d606
mov eax, dword [ebp - 0x994]
push eax
mov ebx, edi
call fcn.1000bf70
add esp, 4
mov ebx, dword [ebp - 0x994]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x9a4]
cmp eax, 0x7148
jbe 0x1000d540
push ebx
mov eax, dword [ebp - 0x998]
push eax
push eax
mov ecx, dword [ebp - 0x768]
push ecx
push str._TOX___Stage:__d._Terminating_Thread__0x_x_:__d___TO:__d
push 0
call fcn.10053700
add esp, 0x18
push 0
push edi
call dword [sym.imp.KERNEL32.dll_TerminateThread]
cmp dword [0x101902a8], 0
je 0x1000d673
cmp eax, 1
mov eax, dword [ebp - 0x998]
push eax
push eax
jne 0x1000d664
push str._TOX___ThreadTerm_Success__0x_x_:__d_
jmp 0x1000d669
push str._TOX___ThreadTerm_Failure__0x_x_:__d_
push 0
call fcn.10053700
add esp, 0x10
mov eax, 0x10624dd3
mul ebx
shr edx, 6
imul edx, dword [ebp - 0x9a0]
push edx
push str.Unable_to_connect__Timed_Out_within__d_secs__
lea edx, [ebp - 0x760]
push edx
call fcn.1010d6a8
add esp, 0xc
cmp dword [0x101902a8], 0
je 0x1000d796
lea eax, [ebp - 0x760]
push eax
push str._TOX___s
jmp 0x1000d78c
cmp eax, 3
je 0x1000d6c1
cmp eax, 1
jne 0x1000d6fb
cmp dword [ebp - 0x980], 0
je 0x1000d6fb
lea ecx, [ebp - 0x9a4]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
cmp eax, 1
jne 0x1000d751
cmp dword [ebp - 0x9a4], 0x103
jne 0x1000d751
mov edx, dword [ebp - 0x980]
mov dword [edx], eax
push 0x14
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x1000d751
cmp dword [0x101902a8], 0
je 0x1000d71c
mov ecx, dword [ebp - 0x998]
push ecx
push ecx
push eax
push str._Stage:__d._Terminating_Thread__0x_x_:__d_
push 0
call fcn.10053700
add esp, 0x14
push 0
push edi
call dword [sym.imp.KERNEL32.dll_TerminateThread]
cmp dword [0x101902a8], 0
je 0x1000d751
cmp eax, 1
mov eax, dword [ebp - 0x998]
push eax
push eax
jne 0x1000d742
push str._ThreadTerm_Success__0x_x_:__d_
jmp 0x1000d747
push str._ThreadTerm_Failure__0x_x_:__d_
push 0
call fcn.10053700
add esp, 0x10
mov eax, 0x10624dd3
mul ebx
shr edx, 6
imul edx, dword [ebp - 0x9a0]
push edx
push str.Unable_to_connect__Timed_Out_within__d_secs__
lea eax, [ebp - 0x760]
push eax
call fcn.1010d6a8
add esp, 0xc
cmp dword [0x101902a8], 0
je 0x1000d796
lea ecx, [ebp - 0x760]
push ecx
push 0x1013fb04
push 0
call fcn.10053700
add esp, 0xc
mov esi, dword [ebp + 0x28]
test esi, esi
je 0x1000d7a2
cmp dword [esi], 1
je 0x1000d7c3
cmp dword [ebp - 0x9b4], 0
jne 0x1000d7c3
mov eax, dword [ebp - 0x9ac]
test eax, eax
je 0x1000d7c3
lea edx, [ebp - 0x346]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x9bc]
push eax
call fcn.100673f0
test esi, esi
je 0x1000d7d8
cmp dword [esi], 1
je 0x1000d820
mov eax, dword [ebp - 0x9b0]
test eax, eax
je 0x1000d7f9
cmp byte [ebp - 0x760], 0
je 0x1000d7f9
lea ecx, [ebp - 0x760]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov eax, dword [ebp - 0x9a8]
test eax, eax
je 0x1000d820
cmp byte [ebp - 0x242], 0
je 0x1000d820
mov edx, dword [ebp + 0x1c]
push edx
lea ecx, [ebp - 0x242]
push ecx
push eax
call fcn.1010e100
add esp, 0xc
cmp dword [0x101902a8], 0
je 0x1000d838
push str.Exiting_IsConnectionActive__...
push 0
call fcn.10053700
add esp, 8
mov eax, dword [ebp - 0x984]
mov dword [ebp - 4], 0xfffffffe
jmp 0x1000d868
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.1010d699
mov esp, ebp
pop ebp
ret