Function at 0x45d8ec
Capabilities:
Connect socket
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffec8
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x138], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x45dbb4
push dword fs:[eax]
mov dword fs:[eax], esp
cmp dword [ebx + 0x3b8], 0
jne 0x45d936
push 1
mov ecx, 0x45dbc4
mov edx, 0x45dbd4
mov eax, dword [0x474124]
mov eax, dword [eax]
call fcn.0045b854
jmp 0x45db9b
cmp dword [ebx + 0x3c0], 0
jne 0x45d95c
push 1
mov ecx, 0x45dbc4
mov edx, 0x45dbe8
mov eax, dword [0x474124]
mov eax, dword [eax]
call fcn.0045b854
jmp 0x45db9b
mov word [ebx + 0x214], 2
lea eax, [ebp - 0x20]
mov edx, dword [ebx + 0x3b8]
call fcn.00408c64
mov esi, 0x45dc00
push esi
lea eax, [ebp - 0x20]
push eax
call sub.wsock32.dll_getservbyname
mov edi, eax
mov dword [ebx + 0x208], edi
test edi, edi
jne 0x45d9b6
lea edx, [ebp - 0x138]
lea eax, [ebp - 0x20]
call fcn.00408dc4
mov eax, dword [ebp - 0x138]
call fcn.00408854
push eax
call sub.wsock32.dll_htons
mov word [ebx + 0x216], ax
jmp 0x45d9c1
mov ax, word [edi + 8]
mov word [ebx + 0x216], ax
lea eax, [ebp - 0x121]
mov edx, dword [ebx + 0x3c0]
call fcn.00408c64
lea eax, [ebp - 0x121]
push eax
call sub.wsock32.dll_inet_addr
mov edi, eax
mov dword [ebx + 0x218], edi
inc edi
jne 0x45da2e
lea eax, [ebp - 0x121]
push eax
call sub.wsock32.dll_gethostbyname
mov edi, eax
mov dword [ebx + 0x20c], edi
test edi, edi
jne 0x45da1b
call sub.wsock32.dll_WSAGetLastError
push eax
mov ecx, 0x45dc0c
or edx, 0xffffffff
mov eax, ebx
call fcn.0045e0ec
jmp 0x45db9b
mov eax, dword [ebx + 0x20c]
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [ebx + 0x218], eax
push esi
call sub.wsock32.dll_getprotobyname
mov edi, eax
mov dword [ebx + 0x210], edi
movsx eax, word [edi + 8]
push eax
push 1
push 2
call sub.wsock32.dll_socket
mov esi, eax
mov dword [ebx + 0x3c4], esi
test esi, esi
jge 0x45da6b
call sub.wsock32.dll_WSAGetLastError
push eax
mov ecx, 0x45dc34
or edx, 0xffffffff
mov eax, ebx
call fcn.0045e0ec
cmp byte [ebx + 0x3b4], 1
jne 0x45dadd
mov esi, 0x400
mov word [ebp - 0x134], 2
xor eax, eax
mov dword [ebp - 0x130], eax
push esi
call sub.wsock32.dll_htons
mov word [ebp - 0x132], ax
push 0x10
lea eax, [ebp - 0x134]
push eax
mov eax, dword [ebx + 0x3c4]
push eax
call sub.wsock32.dll_bind
test eax, eax
je 0x45dadd
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2740
je 0x45dad4
call sub.wsock32.dll_WSAGetLastError
push eax
mov ecx, 0x45dc50
mov edx, dword [ebx + 0x3c4]
mov eax, ebx
call fcn.0045e0ec
dec esi
cmp esi, 0x200
jg 0x45da8a
cmp dword [ebx + 0x3cc], 1
jne 0x45db21
push 0x33
push 0x400
mov eax, ebx
call fcn.00441f68
push eax
mov eax, dword [ebx + 0x3c4]
push eax
call sub.wsock32.dll_WSAAsyncSelect
mov esi, eax
test esi, esi
je 0x45db39
call sub.wsock32.dll_WSAGetLastError
push eax
mov ecx, 0x45dc68
mov edx, dword [ebx + 0x3c4]
mov eax, ebx
call fcn.0045e0ec
jmp 0x45db39
lea eax, [ebx + 0x3cc]
push eax
push 0x8004667e
mov eax, dword [ebx + 0x3c4]
push eax
call sub.wsock32.dll_ioctlsocket
cmp dword [ebx + 0x3cc], 0
jne 0x45db49
mov eax, ebx
call fcn.0045ed9c
push 0x10
lea eax, [ebx + 0x214]
push eax
mov eax, dword [ebx + 0x3c4]
push eax
call sub.wsock32.dll_connect
mov esi, eax
cmp dword [ebx + 0x3cc], 0
jne 0x45db70
mov eax, ebx
call fcn.0045edc8
test esi, esi
je 0x45db9b
call sub.wsock32.dll_WSAGetLastError
mov esi, eax
cmp esi, 0x2733
je 0x45db9b
call sub.wsock32.dll_WSAGetLastError
push eax
mov ecx, 0x45dc80
mov edx, dword [ebx + 0x3c4]
mov eax, ebx
call fcn.0045e0ec
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x45dbbb
lea eax, [ebp - 0x138]
call fcn.00404314
ret