Function at 0x411b20
Capabilities:
Connect socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x33c
mov eax, dword [0x60fec0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x31c]
push esi
mov esi, dword [ebp + 0xc]
push edi
push eax
push 0x8004667e
mov edi, ecx
mov dword [ebp - 0x31c], 1
push ebx
mov dword [ebp - 0x314], edi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
push dword [esi + 0x10]
push dword [esi + 0x18]
push ebx
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
jns 0x411d02
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x411ba1
mov eax, dword [edi + 4]
mov dword [eax], 2
pop edi
pop esi
xor al, al
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00574853
mov esp, ebp
pop ebp
ret 8
mov eax, dword [edi + 0xc]
lea esi, [ebp - 0x108]
mov dword [ebp - 0x108], 1
mov ecx, 0x41
mov ebx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x320], eax
mov eax, dword [edi + 8]
lea edi, [ebp - 0x20c]
mov edx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x320], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x104], eax
mov dword [ebp - 0x318], eax
lea eax, [ebp - 0x318]
mov dword [ebp - 0x33c], eax
lea eax, [ebp - 0x108]
mov dword [ebp - 0x338], eax
lea eax, [ebp - 0x20c]
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x334], eax
lea esi, [ebp - 0x108]
lea eax, [ebp - 0x310]
mov dword [ebp - 0x324], edx
mov dword [ebp - 0x330], eax
lea edi, [ebp - 0x310]
mov ecx, 0x41
mov dword [ebp - 0x320], ebx
lea eax, [ebp - 0x324]
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x32c], eax
lea ecx, [ebp - 0x33c]
call fcn.00411dc0
mov esi, eax
test esi, esi
jns 0x411c61
call fcn.0057fb2e
cmp dword [eax], 4
je 0x411c44
test esi, esi
jne 0x411c6a
mov ecx, 0xd
jmp 0x411ce8
test esi, esi
jle 0x411ce3
lea eax, [ebp - 0x108]
push eax
push dword [ebp - 0x318]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x411c9a
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x318]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x411ce3
lea eax, [ebp - 0x328]
mov dword [ebp - 0x31c], 0
push eax
lea eax, [ebp - 0x31c]
mov dword [ebp - 0x328], 4
push eax
push 0x1007
push 0xffff
push dword [ebp - 0x318]
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
js 0x411ce3
cmp dword [ebp - 0x31c], 0
jne 0x411ce3
xor ecx, ecx
jmp 0x411ce8
mov ecx, 2
mov edi, dword [ebp - 0x314]
mov eax, dword [edi + 4]
mov dword [eax], ecx
mov eax, dword [edi + 4]
cmp dword [eax], 0
jne 0x411b8c
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x314]
mov dword [ebp - 0x314], 0
push eax
push 0x8004667e
push ebx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov eax, dword [edi + 0x14]
push 0
push 0x3e8
push dword [eax + 4]
push dword [eax]
call fcn.00574cf0
mov ecx, dword [edi + 0x10]
mov esi, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
imul ecx, dword [ecx], 0x3e8
add eax, ecx
mov dword [ebp - 0x314], eax
lea eax, [ebp - 0x314]
push eax
push 0x1006
push 0xffff
push ebx
call esi
mov eax, dword [edi + 0x1c]
push 0
push 0x3e8
push dword [eax + 4]
push dword [eax]
call fcn.00574cf0
mov ecx, dword [edi + 0x18]
push 4
imul ecx, dword [ecx], 0x3e8
add eax, ecx
mov dword [ebp - 0x314], eax
lea eax, [ebp - 0x314]
push eax
push 0x1005
push 0xffff
push ebx
call esi
mov eax, dword [edi + 4]
mov ecx, dword [ebp - 4]
pop edi
pop esi
mov dword [eax], 0
xor ecx, ebp
mov al, 1
pop ebx
call fcn.00574853
mov esp, ebp
pop ebp
ret 8