Function at 0x412614
Capabilities:
Connect socket
Get local ipv4 addresses
Get socket information
Receive data
Receive data on socket
Resolve dns
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff9c4
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x638], ecx
mov dword [ebp - 0x63c], ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 4], edx
mov esi, eax
xor eax, eax
push ebp
push 0x4129c4
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
lea eax, [ebp - 0xc]
mov edx, 0xa
call fcn.004045d4
lea eax, [ebp - 0x614]
mov edx, 0x400
call fcn.00405bf8
push 0
push 0x400
lea eax, [ebp - 0x614]
push eax
push esi
call sub.wsock32.dll_recv_1
mov edi, eax
test edi, edi
jle 0x41299e
lea eax, [ebp - 0x110]
mov edx, 0x104
call fcn.00405bf8
lea edx, [ebp - 0x614]
lea eax, [ebp - 0x110]
mov ecx, edi
call fcn.00405bf0
lea eax, [ebp - 0x214]
mov edx, 0x104
call fcn.00405bf8
mov byte [ebp - 0x214], 5
mov byte [ebp - 0x212], 0
cmp byte [ebp - 0x110], 5
jne 0x4126d4
cmp byte [ebp - 0x10e], 0
je 0x4126d8
xor eax, eax
jmp 0x4126da
mov al, 1
test al, al
jne 0x41270c
mov byte [ebp - 0x213], 1
lea eax, [ebp - 0xc]
call fcn.004044fc
lea edx, [ebp - 0x214]
mov ecx, 0xa
call fcn.00405bf0
mov edx, dword [ebp - 0xc]
mov eax, esi
call fcn.004124b0
jmp 0x41299e
mov al, byte [ebp - 0x10f]
dec al
jne 0x412975
lea eax, [ebp - 0x624]
mov edx, 0x10
call fcn.00405bf8
mov word [ebp - 0x624], 2
mov al, byte [ebp - 0x10d]
dec al
je 0x412746
sub al, 2
je 0x412793
jmp 0x412835
mov al, byte [ebp - 0x10c]
mov byte [ebp - 0x620], al
mov al, byte [ebp - 0x10b]
mov byte [ebp - 0x61f], al
mov al, byte [ebp - 0x10a]
mov byte [ebp - 0x61e], al
mov al, byte [ebp - 0x109]
mov byte [ebp - 0x61d], al
mov dl, byte [ebp - 0x107]
mov al, byte [ebp - 0x108]
call fcn.00405bdc
mov word [ebp - 0x622], ax
jmp 0x412863
movzx edi, byte [ebp - 0x10c]
lea eax, [ebp - 0x638]
push eax
lea eax, [ebp - 0x63c]
lea edx, [ebp - 0x10c]
mov ecx, pe_nt_image_headers32
call fcn.0040425c
mov eax, dword [ebp - 0x63c]
mov ecx, edi
mov edx, 2
call fcn.00404504
mov eax, dword [ebp - 0x638]
call fcn.004044a4
push eax
call sub.wsock32.dll_gethostbyname_1
test eax, eax
jne 0x41280c
mov byte [ebp - 0x213], 1
lea eax, [ebp - 0xc]
call fcn.004044fc
lea edx, [ebp - 0x214]
mov ecx, 0xa
call fcn.00405bf0
mov edx, dword [ebp - 0xc]
mov eax, esi
call fcn.004124b0
jmp 0x41299e
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [ebp - 0x620], eax
mov dl, byte [ebp + edi - 0x10a]
mov al, byte [ebp + edi - 0x10b]
call fcn.00405bdc
mov word [ebp - 0x622], ax
jmp 0x412863
mov byte [ebp - 0x213], 8
lea eax, [ebp - 0xc]
call fcn.004044fc
lea edx, [ebp - 0x214]
mov ecx, 0xa
call fcn.00405bf0
mov edx, dword [ebp - 0xc]
mov eax, esi
call fcn.004124b0
jmp 0x41299e
push 0x10
lea eax, [ebp - 0x624]
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax]
push eax
call sub.wsock32.dll_connect_1
inc eax
jne 0x4128b3
mov byte [ebp - 0x213], 4
lea eax, [ebp - 0xc]
call fcn.004044fc
lea edx, [ebp - 0x214]
mov ecx, 0xa
call fcn.00405bf0
mov edx, dword [ebp - 0xc]
mov eax, esi
call fcn.004124b0
mov eax, dword [ebp - 4]
mov eax, dword [eax]
push eax
call sub.wsock32.dll_closesocket_1
jmp 0x41299e
lea eax, [ebp - 0x634]
mov edx, 0x10
call fcn.00405bf8
mov dword [ebp - 8], 0x10
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x634]
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax]
push eax
call sub.wsock32.dll_getsockname
mov byte [ebp - 0x211], 1
mov al, byte [ebp - 0x630]
mov byte [ebp - 0x210], al
mov al, byte [ebp - 0x62f]
mov byte [ebp - 0x20f], al
mov al, byte [ebp - 0x62e]
mov byte [ebp - 0x20e], al
mov al, byte [ebp - 0x62d]
mov byte [ebp - 0x20d], al
mov ax, word [ebp - 0x632]
mov edx, eax
and dx, 0xff
mov byte [ebp - 0x20c], dl
movzx eax, ax
shr eax, 8
mov byte [ebp - 0x20b], al
lea eax, [ebp - 0x614]
mov edx, 0x400
call fcn.00405bf8
lea edx, [ebp - 0x214]
lea eax, [ebp - 0x614]
mov ecx, 0xa
call fcn.00405bf0
push 0
push 0xa
lea eax, [ebp - 0x614]
push eax
push esi
call sub.wsock32.dll_send_1
inc eax
je 0x41299e
mov bl, 1
jmp 0x41299e
mov byte [ebp - 0x213], 7
lea eax, [ebp - 0xc]
call fcn.004044fc
lea edx, [ebp - 0x214]
mov ecx, 0xa
call fcn.00405bf0
mov edx, dword [ebp - 0xc]
mov eax, esi
call fcn.004124b0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4129cb
lea eax, [ebp - 0x63c]
mov edx, 2
call fcn.00404030
lea eax, [ebp - 0xc]
call fcn.0040400c
ret