Function at 0x42f960
Capabilities:
Get hostname
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x33c
mov eax, dword [0x55d68c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, 0x101
mov word [ebp - 0x2c4], ax
lea ecx, [ebp - 0x1b8]
push ecx
movzx edx, word [ebp - 0x2c4]
push edx
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov dword [ebp - 0x2d4], eax
cmp dword [ebp - 0x2d4], 0
je 0x42f9ab
or eax, 0xffffffff
jmp 0x42fcb3
movzx eax, word [ebp - 0x1b8]
and eax, 0xff
movzx ecx, al
cmp ecx, 1
jne 0x42f9d7
movzx edx, word [ebp - 0x1b8]
shr edx, 8
and edx, 0xff
movzx eax, dl
cmp eax, 1
je 0x42f9e5
call dword [sym.imp.WS2_32.dll_WSACleanup]
or eax, 0xffffffff
jmp 0x42fcb3
mov byte [ebp - 0x2c0], 0
push 0xfe
push 0
lea ecx, [ebp - 0x2bf]
push ecx
call fcn.004611e0
add esp, 0xc
mov dword [ebp - 0x24], str.3294
push 0xff
lea edx, [ebp - 0x2c0]
push edx
call dword [sym.imp.WS2_32.dll_gethostname]
lea eax, [ebp - 0x2c0]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 0x1c0], eax
cmp dword [ebp - 0x1c0], 0
jne 0x42fa3f
or eax, 0xffffffff
jmp 0x42fcb3
mov ecx, dword [ebp - 0x1c0]
mov edx, dword [ecx + 0xc]
cmp dword [edx], 0
je 0x42faa1
mov eax, dword [ebp - 0x1c0]
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov dword [ebp - 0x2c8], eax
mov ecx, dword [ebp - 0x2c8]
push ecx
lea ecx, [ebp - 0x20]
call fcn.00402b60
lea edx, [ebp - 0x20]
push edx
mov ecx, dword [ebp + 0xc]
call fcn.00408930
lea ecx, [ebp - 0x20]
call fcn.00402c40
mov eax, dword [ebp - 0x1c0]
mov ecx, dword [eax + 0xc]
add ecx, 4
mov edx, dword [ebp - 0x1c0]
mov dword [edx + 0xc], ecx
jmp 0x42fa3f
mov dword [ebp - 0x2f8], 0x17
mov dword [ebp - 0x2f4], 1
mov dword [ebp - 0x2fc], 1
mov dword [ebp - 0x2f0], 0
mov dword [ebp - 0x2ec], 0
mov dword [ebp - 0x2e8], 0
mov dword [ebp - 0x2e4], 0
mov dword [ebp - 0x2e0], 0
lea eax, [ebp - 0x1bc]
push eax
lea ecx, [ebp - 0x2fc]
push ecx
mov edx, dword [ebp - 0x24]
push edx
lea eax, [ebp - 0x2c0]
push eax
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov dword [ebp - 0x2cc], eax
cmp dword [ebp - 0x2cc], 0
jge 0x42fb27
or eax, 0xffffffff
jmp 0x42fcb3
cmp dword [ebp - 0x1bc], 0
jne 0x42fb38
or eax, 0xffffffff
jmp 0x42fcb3
mov ecx, dword [ebp - 0x1bc]
mov dword [ebp - 0x2d0], ecx
jmp 0x42fb55
mov edx, dword [ebp - 0x2d0]
mov eax, dword [edx + 0x1c]
mov dword [ebp - 0x2d0], eax
cmp dword [ebp - 0x2d0], 0
je 0x42fcab
lea ecx, [ebp - 0x328]
call fcn.00402b30
mov ecx, dword [ebp - 0x2d0]
mov edx, dword [ecx + 0x18]
mov dword [ebp - 0x2dc], edx
mov dword [ebp - 0x30c], 0
jmp 0x42fb97
mov eax, dword [ebp - 0x30c]
add eax, 1
mov dword [ebp - 0x30c], eax
cmp dword [ebp - 0x30c], 0x10
jge 0x42fc41
mov ecx, dword [ebp - 0x30c]
sub ecx, 1
and ecx, reloc.WS2_32.dll_accept
jns 0x42fbba
dec ecx
or ecx, 0xfffffffe
inc ecx
test ecx, ecx
je 0x42fbd7
cmp dword [ebp - 0x30c], 0
jle 0x42fbd7
push 0x551788
lea ecx, [ebp - 0x328]
call fcn.00409640
mov byte [ebp - 0x33c], 0
xor edx, edx
mov dword [ebp - 0x33b], edx
mov dword [ebp - 0x337], edx
mov dword [ebp - 0x333], edx
mov dword [ebp - 0x32f], edx
mov word [ebp - 0x32b], dx
mov byte [ebp - 0x329], dl
mov eax, dword [ebp - 0x2dc]
add eax, dword [ebp - 0x30c]
movzx ecx, byte [eax + 8]
push ecx
push 0x55178c
lea edx, [ebp - 0x33c]
push edx
call fcn.00455c32
add esp, 0xc
lea eax, [ebp - 0x33c]
push eax
lea ecx, [ebp - 0x328]
call fcn.00409640
jmp 0x42fb88
mov byte [ebp - 0x308], 0
xor ecx, ecx
mov dword [ebp - 0x307], ecx
mov dword [ebp - 0x303], ecx
mov byte [ebp - 0x2ff], cl
mov edx, dword [ebp - 0x2dc]
mov eax, dword [edx + 0x18]
push eax
push str.___d
lea ecx, [ebp - 0x308]
push ecx
call fcn.00455c32
add esp, 0xc
lea edx, [ebp - 0x308]
push edx
lea ecx, [ebp - 0x328]
call fcn.00409640
lea eax, [ebp - 0x328]
push eax
mov ecx, dword [ebp + 8]
call fcn.00408930
lea ecx, [ebp - 0x328]
call fcn.00402c40
jmp 0x42fb46
call dword [sym.imp.WS2_32.dll_WSACleanup]
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00455328
mov esp, ebp
pop ebp
ret