Function at 0x10172d90
Capabilities:
Connect socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2ec
mov eax, dword [0x10373f78]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
add eax, 0x4e
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, dword [ebp + 0xc]
lea eax, [edi + eax*4]
mov dword [ebp - 0x2e8], edi
mov dword [eax], 0xffffffff
mov edx, dword [ebx + 0xc]
mov dword [ebp - 0x2ec], eax
mov eax, dword [ecx + 4]
mov dword [ebp - 0x2d4], eax
mov al, byte [edx + 0x455]
mov byte [ebp - 0x2d6], 0
mov dword [ebp - 0x2e4], edx
cmp al, 3
je 0x10172e13
cmp al, 6
je 0x10172e07
mov dword [ebp - 0x2d0], 2
mov dword [ebp - 0x2cc], 0x11
jmp 0x10172e27
mov dword [ebp - 0x2cc], 0
jmp 0x10172e1d
mov dword [ebp - 0x2cc], 6
mov dword [ebp - 0x2d0], 1
mov eax, dword [ecx + 0x10]
mov dword [ebp - 0x2c8], eax
cmp eax, 0x80
jbe 0x10172e46
mov dword [ebp - 0x2c8], 0x80
mov eax, 0x80
push eax
push dword [ecx + 0x18]
lea eax, [ebp - 0x2c4]
push eax
call fcn.10266cf0
add esp, 0xc
cmp dword [ebx + 0x1b8], 0
je 0x10172e96
push 1
push ebx
call fcn.101610e0
lea eax, [ebp - 0x2d4]
push eax
mov eax, dword [ebx + 0x1b8]
push 0
push dword [ebx + 0x1bc]
call eax
mov esi, eax
push 0
push ebx
mov dword [ebp - 0x2e0], esi
call fcn.101610e0
add esp, 0x1c
jmp 0x10172eb6
push dword [ebp - 0x2cc]
push dword [ebp - 0x2d0]
push dword [ebp - 0x2d4]
call dword [sym.imp.WS2_32.dll_socket]
mov esi, eax
mov dword [ebp - 0x2e0], eax
cmp esi, 0xffffffff
je 0x10173231
mov eax, dword [ebp - 0x2e4]
cmp byte [eax + 0x455], 5
jne 0x10172edf
push 1
push esi
call fcn.1018d980
mov eax, dword [ebp - 0x2e4]
add esp, 8
mov ecx, dword [eax + 0x44c]
test ecx, ecx
je 0x10172eff
mov eax, dword [ebp - 0x2ac]
cmp dword [ebp - 0x2d4], 0x17
cmove eax, ecx
mov dword [ebp - 0x2ac], eax
xor eax, eax
mov dword [ebp - 0x2e4], eax
lea eax, [ebp - 0x2dc]
push eax
lea eax, [ebp - 0x34]
push eax
push dword [ebp - 0x2c8]
lea eax, [ebp - 0x2c4]
push eax
call fcn.101715c0
add esp, 0x10
test al, al
jne 0x10172f81
call fcn.10276a94
mov esi, dword [eax]
call fcn.10276a94
mov edi, eax
lea eax, [ebp - 0x134]
push 0x100
push eax
push esi
call fcn.1015cfa0
push eax
push dword [edi]
push str.sa_addr_inet_ntop___failed_with_errno__d:__s
push ebx
call fcn.10170b90
push dword [ebp - 0x2e0]
push dword [ebp - 0x2e8]
push ebx
call fcn.10171670
add esp, 0x28
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.102649e4
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x2d4], 0x17
mov ecx, str.__Trying__s:_d...
push dword [ebp - 0x2dc]
mov eax, str.__Trying___s_:_d...
cmovne eax, ecx
lea ecx, [ebp - 0x34]
push ecx
push eax
push ebx
call fcn.10170c50
mov eax, dword [ebp - 0x2d4]
add esp, 0x10
cmp eax, 2
je 0x10172fb9
cmp eax, 0x17
jne 0x1017301d
cmp dword [ebp - 0x2d0], 1
jne 0x1017301d
cmp byte [ebx + 0x6ac], 0
mov byte [ebp - 0x2d5], 1
je 0x10173024
push 4
lea eax, [ebp - 0x2dc]
mov dword [ebp - 0x2dc], 1
push eax
push 1
push 6
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x10173024
push 0x100
lea eax, [ebp - 0x234]
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.1015cfa0
push eax
push str.Could_not_set_TCP_NODELAY:__s
push ebx
call fcn.10170c50
add esp, 0x18
jmp 0x10173024
mov byte [ebp - 0x2d5], 0
mov eax, dword [0x10385f84]
mov dword [ebp - 0x2e8], 0x4020
mov dword [ebp - 0x2e0], 0
mov dword [ebp - 0x2dc], 4
test eax, eax
jne 0x10173077
push 3
push 2
push eax
push eax
push 6
call fcn.1018d9b0
add esp, 0x14
test al, al
je 0x1017306b
mov dword [0x10385f84], 2
jmp 0x101730c7
mov dword [0x10385f84], 1
jmp 0x1017307c
cmp eax, 2
je 0x101730c7
lea eax, [ebp - 0x2dc]
push eax
lea eax, [ebp - 0x2e0]
push eax
push 0x1001
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x101730ad
mov eax, dword [ebp - 0x2e0]
cmp eax, dword [ebp - 0x2e8]
jg 0x101730c7
push 4
lea eax, [ebp - 0x2e8]
push eax
push 0x1001
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
cmp byte [ebp - 0x2d5], 0
je 0x1017319f
cmp byte [ebx + 0x6b3], 0
je 0x1017319f
push 4
lea eax, [ebp - 0x2e0]
mov dword [ebp - 0x2e0], 1
push eax
push 8
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x1017311a
push esi
push str.Failed_to_set_SO_KEEPALIVE_on_fd__d
push ebx
call fcn.10170c50
add esp, 0xc
jmp 0x1017319f
push dword [ebx + 0x660]
mov dword [ebp - 0x240], 1
call fcn.10173460
push dword [ebx + 0x664]
imul eax, eax, 0x3e8
mov dword [ebp - 0x2e0], eax
mov dword [ebp - 0x23c], eax
call fcn.10173460
add esp, 8
imul eax, eax, 0x3e8
push 0
push 0
mov dword [ebp - 0x2e0], eax
mov dword [ebp - 0x238], eax
lea eax, [ebp - 0x2dc]
push eax
push 0
push 0
push 0xc
lea eax, [ebp - 0x240]
push eax
push 0x98000004
push esi
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x1017319f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push esi
push str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__d:__d
push ebx
call fcn.10170c50
add esp, 0x10
cmp dword [ebx + 0x1b0], 0
je 0x101731e4
push 1
push ebx
call fcn.101610e0
mov eax, dword [ebx + 0x1b0]
push 0
push esi
push dword [ebx + 0x1b4]
call eax
push 0
push ebx
mov dword [ebp - 0x2dc], eax
call fcn.101610e0
mov eax, dword [ebp - 0x2dc]
add esp, 0x1c
cmp eax, 2
jne 0x10173247
mov byte [ebp - 0x2d6], 1
mov eax, dword [ebp - 0x2d4]
cmp eax, 2
je 0x101731f4
cmp eax, 0x17
jne 0x1017326c
lea eax, [ebp - 0x2c4]
push eax
call fcn.1018d8e0
push eax
push dword [ebp - 0x2d4]
push esi
push ebx
call fcn.10172650
add esp, 0x14
mov dword [ebp - 0x2e4], eax
test eax, eax
je 0x1017326c
push esi
push edi
push ebx
call fcn.10171670
mov eax, dword [ebp - 0x2e4]
add esp, 0xc
cmp eax, 1
jne 0x10173236
mov eax, 7
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.102649e4
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x101731e4
push esi
push edi
push ebx
call fcn.10171670
add esp, 0xc
mov eax, 0x2a
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.102649e4
mov esp, ebp
pop ebp
ret
push 1
push esi
call fcn.1018d980
lea eax, [ebp - 0x244]
push eax
call fcn.10177300
add esp, 0xc
cmp dword [edi + 0x43c], 1
movups xmm0, xmmword [eax]
movups xmmword [edi + 0x260], xmm0
jle 0x101732c1
push 3
push dword [edi + 0x274]
push dword [edi + 0x270]
push ebx
call fcn.10160b40
push 4
push dword [edi + 0x27c]
push dword [edi + 0x278]
push ebx
call fcn.10160b40
add esp, 0x20
cmp byte [ebp - 0x2d6], 0
jne 0x1017339d
cmp byte [edi + 0x455], 4
je 0x1017339d
cmp byte [edi + 0x255], 0
jne 0x10173324
push dword [ebp - 0x2c8]
lea eax, [ebp - 0x2c4]
push eax
push esi
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x10173324
mov eax, dword [ebp - 0x2e4]
test eax, eax
jne 0x10173236
mov ecx, dword [ebp - 0x2ec]
pop edi
mov dword [ecx], esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.102649e4
mov esp, ebp
pop ebp
ret
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
mov dword [ebp - 0x2dc], eax
sub ecx, 0xb
je 0x10173382
sub ecx, 0x2728
je 0x10173382
sub ecx, 1
je 0x10173382
push 0x100
lea ecx, [ebp - 0x134]
push ecx
push eax
call fcn.1015cfa0
push eax
lea eax, [ebp - 0x34]
push eax
push str.Immediate_connect_fail_for__s:__s
push ebx
call fcn.10170c50
mov eax, dword [ebp - 0x2dc]
push esi
push edi
push ebx
mov dword [ebx + 0x8f8], eax
call fcn.10171670
add esp, 0x28
jmp 0x10173231
mov ecx, dword [ebp - 0x2ec]
xor eax, eax
pop edi
mov dword [ecx], esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.102649e4
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x2ec]
xor eax, eax
pop edi
mov dword [ecx], esi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.102649e4
mov esp, ebp
pop ebp
ret