Function at 0x401160
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
mov eax, dword [0x61df80]
xor eax, ebp
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x3c], ecx
mov eax, dword [ebp + 8]
movsx ecx, byte [eax]
test ecx, ecx
jne 0x401184
xor eax, eax
jmp 0x401380
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0xffffffff
jne 0x4011bf
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x4011b2
or eax, 0xffffffff
jmp 0x401380
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 0xc]
mov eax, dword [edx]
mov dword [ebp - 0x10], eax
jmp 0x4011e9
push 2
push 4
lea ecx, [ebp - 4]
push ecx
call dword [sym.imp.WS2_32.dll_gethostbyaddr]
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x4011de
lea edx, [ebp - 4]
mov dword [ebp - 0x10], edx
jmp 0x4011e9
mov eax, dword [ebp - 0x28]
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov dword [ebp - 0x10], edx
movzx eax, byte [ebp + 0xc]
cmp eax, 5
jl 0x401256
cmp dword [ebp + 0x10], 0
je 0x401256
mov ecx, dword [ebp - 0x10]
mov edx, dword [ecx]
mov dword [ebp - 0x30], edx
mov eax, dword [ebp - 0x30]
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov dword [ebp - 0x2c], eax
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x40], ecx
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x44], edx
mov eax, dword [ebp - 0x44]
mov dword [ebp - 0x48], eax
mov ecx, dword [ebp - 0x40]
mov dl, byte [ecx]
mov byte [ebp - 0x49], dl
mov eax, dword [ebp - 0x44]
mov cl, byte [ebp - 0x49]
mov byte [eax], cl
mov edx, dword [ebp - 0x40]
add edx, 1
mov dword [ebp - 0x40], edx
mov eax, dword [ebp - 0x44]
add eax, 1
mov dword [ebp - 0x44], eax
cmp byte [ebp - 0x49], 0
jne 0x40121f
movzx ecx, byte [ebp + 0x1c]
test ecx, ecx
je 0x401256
xor eax, eax
jmp 0x401380
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 0x24], eax
mov ecx, dword [str.hello_world]
mov dword [ebp - 0x20], ecx
mov edx, dword [0x5f0730]
mov dword [ebp - 0x1c], edx
mov eax, dword [0x5f0734]
mov dword [ebp - 0x18], eax
mov cl, byte [ebp + 0xc]
mov byte [ebp - 0xc], cl
mov byte [ebp - 0xb], 0
mov byte [ebp - 0xa], 0
mov byte [ebp - 9], 0
mov dword [ebp - 8], 0
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x18], 0
push 0x7d0
push 0x28
mov eax, dword [ebp - 0x3c]
add eax, 0x14
push eax
lea ecx, [ebp - 0xc]
push ecx
push 0xc
lea edx, [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x10]
mov ecx, dword [eax]
push ecx
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0xc]
call ecx
movzx edx, byte [ebp + 0xc]
cmp edx, 5
jge 0x40133f
cmp dword [ebp + 0x10], 0
je 0x40133f
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x14]
mov dword [ebp - 0x38], ecx
mov edx, dword [ebp - 0x38]
push edx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x50], eax
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x54], ecx
mov edx, dword [ebp - 0x54]
mov dword [ebp - 0x58], edx
mov eax, dword [ebp - 0x50]
mov cl, byte [eax]
mov byte [ebp - 0x59], cl
mov edx, dword [ebp - 0x54]
mov al, byte [ebp - 0x59]
mov byte [edx], al
mov ecx, dword [ebp - 0x50]
add ecx, 1
mov dword [ebp - 0x50], ecx
mov edx, dword [ebp - 0x54]
add edx, 1
mov dword [ebp - 0x54], edx
cmp byte [ebp - 0x59], 0
jne 0x4012ff
movzx eax, byte [ebp + 0x1c]
test eax, eax
je 0x40133f
mov ecx, dword [ebp - 0x24]
push ecx
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 8]
call eax
xor eax, eax
jmp 0x401380
mov ecx, dword [ebp - 0x3c]
cmp dword [ecx + 0x18], 0
je 0x40134d
or eax, 0xffffffff
jmp 0x401380
cmp dword [ebp + 0x14], 0
je 0x40135f
mov edx, dword [ebp - 0x3c]
movzx eax, word [edx + 0x20]
mov ecx, dword [ebp + 0x14]
mov dword [ecx], eax
cmp dword [ebp + 0x18], 0
je 0x401370
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x1c]
mov dword [edx], ecx
mov edx, dword [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 8]
call ecx
movzx eax, byte [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004c7d13
mov esp, ebp
pop ebp
ret 0x18