Function at 0x100875e0
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0x54
mov eax, dword [0x1013d900]
xor eax, esp
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x5c]
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x68]
mov esi, dword [edi]
xor ebx, ebx
xor ebp, ebp
mov dword [eax], ebx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], ebp
cmp dword [edi + ecx*4 + 0x240], ebx
je 0x1008763a
pop edi
pop esi
pop ebp
mov dword [eax], 1
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x50]
xor ecx, esp
call fcn.10056c06
add esp, 0x54
ret
call fcn.10083f90
mov dword [esp + 0x20], edx
push 1
lea edx, [esp + 0x20]
push edx
push esi
mov dword [esp + 0x28], eax
call fcn.10086660
add esp, 0xc
cmp eax, ebx
mov dword [esp + 0x24], eax
jge 0x10087685
push str.Connection_time_out
push esi
call fcn.100844e0
add esp, 8
pop edi
pop esi
pop ebp
mov eax, 0x1c
pop ebx
mov ecx, dword [esp + 0x50]
xor ecx, esp
call fcn.10056c06
add esp, 0x54
ret
mov eax, ebx
xor eax, 1
mov dword [esp + 0x28], eax
mov eax, dword [edi + ebx*4 + 0x170]
cmp eax, 0xffffffff
je 0x10087833
push 0
push eax
push 0xffffffffffffffff
push 0xffffffffffffffff
call fcn.100796e0
add esp, 0x10
test eax, eax
jne 0x10087747
mov eax, dword [edi + 0x290]
mov ecx, dword [edi + 0x28c]
mov edx, dword [esp + 0x20]
mov esi, dword [edi + 0x298]
push eax
mov eax, dword [esp + 0x20]
push ecx
push edx
xor ebp, ebp
push eax
mov dword [esp + 0x20], ebp
call fcn.10083fc0
add esp, 0x10
cmp eax, esi
jl 0x10087701
mov ecx, dword [esp + 0x14]
push esi
push str.After__ldms_connect_time__move_on__n
push ecx
call fcn.10084450
mov ebp, 0x274c
add esp, 0xc
mov dword [esp + 0x10], ebp
test ebx, ebx
jne 0x100877a5
cmp dword [edi + 0x54], ebx
jne 0x100877a5
mov edx, dword [edi + 0x290]
mov eax, dword [edi + 0x28c]
mov ecx, dword [esp + 0x20]
push edx
mov edx, dword [esp + 0x20]
push eax
push ecx
push edx
call fcn.10083fc0
add esp, 0x10
cmp eax, 0xc8
jl 0x100877a5
mov eax, dword [esp + 0x6c]
push 1
push eax
call fcn.10087530
jmp 0x100877a2
cmp eax, 2
je 0x10087773
cmp dword [edi + 0x280], 0
jne 0x10087773
test al, 4
je 0x100877a5
mov ecx, dword [edi + ebx*4 + 0x170]
push ecx
lea esi, [esp + 0x14]
call fcn.10086b40
mov ebp, dword [esp + 0x14]
add esp, 4
jmp 0x100877a5
mov edx, dword [edi + ebx*4 + 0x170]
push edx
lea esi, [esp + 0x14]
call fcn.10086b40
add esp, 4
test eax, eax
jne 0x10087881
mov eax, dword [esp + 0x14]
push str.Connection_failed_n
push eax
call fcn.10084450
mov ebp, dword [esp + 0x18]
add esp, 8
test ebp, ebp
je 0x10087833
mov esi, dword [esp + 0x14]
push ebp
mov dword [esi + 0x8628], ebp
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [edi + ebx*4 + 0x50]
test eax, eax
je 0x10087833
push 0x2e
lea ecx, [esp + 0x34]
push ecx
push eax
call fcn.1007a420
push ebp
push edi
call fcn.10089eb0
mov edx, dword [edi + 0xc0]
push eax
push edx
lea eax, [esp + 0x4c]
push eax
push str.connect_to__s_port__ld_failed:__s_n
push esi
call fcn.10084450
mov ecx, dword [edi + ebx*4 + 0x50]
mov eax, dword [esp + 0x4c]
add esp, 0x28
cmp dword [ecx + 0x1c], 0
je 0x10087808
cdq
sub eax, edx
sar eax, 1
mov edx, dword [esp + 0x6c]
push ebx
push edx
mov dword [edi + 0x298], eax
call fcn.10087530
add esp, 8
cmp eax, 7
jne 0x1008782f
mov ecx, dword [esp + 0x28]
cmp dword [edi + ecx*4 + 0x170], 0xffffffff
jne 0x10087833
mov dword [esp + 0x18], eax
inc ebx
cmp ebx, 2
jl 0x10087685
cmp dword [esp + 0x18], 0
je 0x10087963
cmp dword [edi + 0x54], 0
jne 0x10087869
mov ecx, dword [esp + 0x6c]
push 1
push ecx
call fcn.10087530
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
je 0x10087963
cmp dword [edi + 0x224], 0
je 0x1008792a
mov esi, dword [edi + 0xb8]
jmp 0x10087941
mov edx, dword [edi + ebx*4 + 0x170]
mov esi, dword [esp + 0x6c]
mov dword [edi + esi*4 + 0x168], edx
mov eax, dword [edi + ebx*4 + 0x50]
or ebp, 0xffffffff
mov dword [edi + 0x4c], eax
mov dword [edi + ebx*4 + 0x170], ebp
mov ebx, dword [esp + 0x28]
mov eax, dword [edi + ebx*4 + 0x170]
cmp eax, ebp
je 0x100878c4
push eax
push edi
call fcn.10087040
add esp, 8
mov dword [edi + ebx*4 + 0x170], ebp
push esi
push edi
call fcn.1007b4f0
add esp, 8
test eax, eax
jne 0x10087967
mov ecx, dword [esp + 0x2c]
mov dword [edi + esi*4 + 0x240], 1
mov dword [ecx], 1
test esi, esi
jne 0x100878fe
mov edx, dword [esp + 0x14]
push 4
push edx
call fcn.100a0110
add esp, 8
mov eax, dword [edi + esi*4 + 0x168]
push eax
push edi
call fcn.10086c50
push edi
call fcn.1007b610
add esp, 0xc
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x50]
xor ecx, esp
call fcn.10056c06
add esp, 0x54
ret
cmp dword [edi + 0x21c], 0
je 0x1008793b
mov esi, dword [edi + 0xa8]
jmp 0x10087941
mov esi, dword [edi + 0x98]
push ebp
push edi
call fcn.10089eb0
mov edx, dword [edi + 0xc0]
push eax
mov eax, dword [esp + 0x20]
push edx
push esi
push str.Failed_to_connect_to__s_port__ld:__s
push eax
call fcn.100844e0
add esp, 0x1c
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x60]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10056c06
add esp, 0x54
ret