Function at 0x1000263f
Capabilities:
Connect socket
Get socket status
Set socket configuration

Disassembly:
jmp 0x1007fb29
sub esp, 0x20
push ebx
mov ebx, dword [esp + 0x28]
push ebp
xor ebp, ebp
mov dword [esp + 0xc], 1
push esi
test byte [ebx + 4], 0x10
push edi
mov dword [esp + 0x10], ebp
mov dword [esp + 0x1c], ebp
je 0x1007fd89
push dword [esp + 0x38]
call sym.CoreFoundation.dll_CFDataGetBytePtr
push dword [esp + 0x3c]
mov edi, eax
call sym.CoreFoundation.dll_CFDataGetLength
mov esi, eax
pop ecx
pop ecx
test edi, edi
je 0x1007fd89
test esi, esi
jle 0x1007fd89
movsd xmm0, qword [esp + 0x3c]
xorps xmm1, xmm1
comisd xmm0, xmm1
mov ebx, dword [ebx + 0x14]
ja 0x1007fb90
comisd xmm1, xmm0
jbe 0x1007fba1
lea eax, [esp + 0x14]
push eax
push 0x8004667e
push ebx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
push esi
push edi
push ebx
call dword [sym.imp.WS2_32.dll_connect]
mov edi, eax
test edi, edi
je 0x1007fd85
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
mov ecx, 0x2734
cmove eax, ecx
cmp eax, ecx
jne 0x1007fd85
movsd xmm0, qword [esp + 0x3c]
xorps xmm1, xmm1
comisd xmm0, xmm1
jb 0x1007fd7c
push ebp
push dword [sym.CoreFoundation.dll_kCFAllocatorSystemDefault]
mov dword [esp + 0x20], 4
call sym.CoreFoundation.dll_CFDataCreateMutable
or edi, 0xffffffff
mov ebp, eax
pop ecx
pop ecx
cmp ebx, edi
je 0x1007fc7d
push ebp
call sym.CoreFoundation.dll_CFDataGetMutableBytePtr
push ebp
mov esi, eax
call sym.CoreFoundation.dll_CFDataGetLength
pop ecx
pop ecx
mov ecx, eax
mov dword [esp + 0x34], ecx
test ecx, ecx
je 0x1007fc39
push esi
push ebx
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x1007fc7d
mov ecx, dword [esp + 0x34]
test ecx, ecx
jle 0x1007fc39
mov eax, dword [esi]
lea eax, [eax*4 + 8]
jmp 0x1007fc3e
mov eax, 0x1004
cmp eax, ecx
jle 0x1007fc56
sub eax, ecx
push eax
push ebp
call sym.CoreFoundation.dll_CFDataIncreaseLength
push ebp
call sym.CoreFoundation.dll_CFDataGetMutableBytePtr
add esp, 0xc
mov esi, eax
xor eax, eax
cmp eax, dword [esi]
jae 0x1007fc6d
lea ecx, [esi + 4]
cmp dword [ecx], ebx
je 0x1007fc6b
inc eax
add ecx, 4
cmp eax, dword [esi]
jb 0x1007fc5f
cmp eax, dword [esi]
jne 0x1007fc7d
cmp dword [esi], 0x400
jae 0x1007fc7d
mov dword [esi + eax*4 + 4], ebx
inc dword [esi]
movsd xmm0, qword [esp + 0x3c]
xorps xmm1, xmm1
comisd xmm1, xmm0
jae 0x1007fcbb
comisd xmm0, xmmword [0x10145390]
jae 0x1007fcbb
push ecx
push ecx
movsd qword [esp], xmm0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_floor]
movsd xmm0, qword [esp + 0x44]
fstp qword [esp + 0x30]
cvttsd2si eax, qword [esp + 0x30]
pop ecx
pop ecx
mov dword [esp + 0x20], eax
jmp 0x1007fcc3
mov dword [esp + 0x20], getpeername
push ecx
push ecx
movsd qword [esp], xmm0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_floor]
movsd xmm0, qword [esp + 0x44]
fstp qword [esp + 0x30]
subsd xmm0, qword [esp + 0x30]
mulsd xmm0, qword [0x10149990]
movsd qword [esp], xmm0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_floor]
fstp qword [esp + 0x30]
cvttsd2si eax, qword [esp + 0x30]
push ebp
mov dword [esp + 0x30], eax
call sym.CoreFoundation.dll_CFDataGetLength
add esp, 0xc
mov esi, eax
lea eax, [esp + 0x20]
shl esi, 3
push eax
push 0
push ebp
call sym.CoreFoundation.dll_CFDataGetMutableBytePtr
pop ecx
push eax
push 0
push esi
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jns 0x1007fd37
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esp + 0x10], eax
jmp 0x1007fd6c
jne 0x1007fd3e
push 0xfffffffffffffffe
pop edi
jmp 0x1007fd6c
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x14]
push eax
push 0x1007
push 0xffff
push ebx
call dword [sym.imp.WS2_32.dll_getsockopt]
mov edi, dword [esp + 0x10]
xor ecx, ecx
test eax, eax
cmovne edi, ecx
mov dword [esp + 0x10], edi
neg edi
sbb edi, edi
push ebp
call sym.CoreFoundation.dll_CFRelease
movsd xmm0, qword [esp + 0x40]
xorps xmm1, xmm1
pop ecx
xor eax, eax
comisd xmm1, xmm0
cmova edi, eax
mov eax, edi
jmp 0x1007fd8c
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret