Function at 0x416ef0
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x28], 0
mov edi, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
test esi, esi
je 0x416f18
mov edx, dword [esi + 4]
test edx, edx
jne 0x417013
test ebx, ebx
je 0x416f5b
mov dword [esp], ebx
lea edx, [ebp - 0x10]
mov ecx, 0xa
mov dword [esp + 4], edx
mov dword [esp + 8], ecx
call sub.msys_1.0.dll_strtol
mov edx, eax
lea eax, [eax - 1]
cmp eax, 0xfffe
ja 0x417160
mov eax, dword [ebp - 0x10]
cmp byte [eax], 0
jne 0x417160
movzx ebx, dx
xchg bh, bl
movzx eax, bx
mov dword [ebp - 0x28], eax
test esi, esi
je 0x417030
test byte [esi], 1
je 0x417030
mov dword [ebp - 0x1c], 0
test edi, edi
je 0x416f90
mov dword [esp], edi
lea ecx, [ebp - 0x14]
mov dword [esp + 4], ecx
call sub.msys_1.0.dll_inet_aton
test eax, eax
jne 0x417023
nop
mov dword [esp], 0x30
call sub.msys_1.0.dll_malloc
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x416ffc
mov dword [esp], ebx
mov eax, 0x30
xor edi, edi
mov dword [esp + 8], eax
mov dword [esp + 4], edi
call sub.msys_1.0.dll_memset
mov dword [ebx + 0x10], 0x10
mov ecx, dword [ebp - 0x28]
lea eax, [ebx + 0x20]
mov dword [ebx + 4], 2
mov edx, dword [ebp - 0x1c]
mov word [ebx + 0x20], 2
mov dword [ebx + 0x18], eax
mov word [eax + 2], cx
mov dword [eax + 4], edx
mov eax, dword [esi + 8]
test eax, eax
je 0x417186
mov dword [ebx + 8], eax
mov eax, dword [esi + 0xc]
test eax, eax
je 0x416ffa
mov dword [ebx + 0xc], eax
mov eax, ebx
mov esi, dword [ebp + 0x14]
cmp eax, 1
mov dword [esi], eax
sbb eax, eax
and eax, 0x7ffffffd
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
cmp edx, 2
mov eax, 0x7ffffffa
je 0x416f18
jmp 0x41700b
mov edi, dword [ebp - 0x14]
mov dword [ebp - 0x1c], edi
jmp 0x416f90
test edi, edi
je 0x4171f0
mov dword [esp], edi
lea ebx, [ebp - 0x14]
mov dword [esp + 4], ebx
call sub.msys_1.0.dll_inet_aton
test eax, eax
jne 0x417192
test esi, esi
je 0x41705d
test byte [esi], 4
mov eax, 0x7ffffffc
jne 0x41700b
mov dword [esp], edi
call sub.msys_1.0.dll_gethostbyname
test eax, eax
mov edi, eax
je 0x417250
mov eax, dword [eax]
test eax, eax
je 0x417250
cmp byte [eax], 0
je 0x417250
mov eax, dword [edi + 0xc]
mov ebx, dword [eax]
test ebx, ebx
je 0x417250
mov dword [ebp - 0x20], 0
mov edx, dword [ebp + 0x14]
mov dword [ebp - 0x18], 0
mov dword [edx], 0
jmp 0x4170e7
mov dword [ebx + 8], eax
mov eax, dword [esi + 0xc]
test eax, eax
je 0x4170b5
mov dword [ebx + 0xc], eax
test ebx, ebx
mov eax, ebx
je 0x41726e
mov ebx, dword [ebp - 0x20]
test ebx, ebx
je 0x41725d
mov ecx, dword [ebp - 0x20]
mov dword [ecx + 0x1c], eax
inc dword [ebp - 0x18]
mov dword [ebp - 0x20], eax
mov eax, dword [edi + 0xc]
mov ecx, dword [ebp - 0x18]
mov ebx, dword [eax + ecx*4]
test ebx, ebx
je 0x417267
mov ebx, dword [ebp - 0x18]
mov ecx, dword [eax + ebx*4]
mov eax, dword [ecx]
mov dword [ebp - 0x24], eax
mov dword [esp], 0x30
call sub.msys_1.0.dll_malloc
test eax, eax
mov ebx, eax
je 0x41726e
mov dword [esp], ebx
mov edx, 0x30
xor eax, eax
mov dword [esp + 8], edx
mov dword [esp + 4], eax
call sub.msys_1.0.dll_memset
mov dword [ebx + 0x10], 0x10
mov edx, dword [ebp - 0x24]
lea eax, [ebx + 0x20]
mov dword [ebx + 4], 2
mov ecx, dword [ebp - 0x28]
mov dword [ebx + 0x18], eax
mov dword [eax + 4], edx
mov word [ebx + 0x20], 2
mov word [eax + 2], cx
mov eax, dword [esi + 8]
test eax, eax
jne 0x4170a8
mov dword [ebx + 8], 1
jmp 0x4170ab
mov dword [esp], ebx
xor edx, edx
mov dword [esp + 4], edx
call sub.msys_1.0.dll_getservbyname
mov dword [ebp - 0x28], 0
test eax, eax
je 0x416f5b
movsx eax, word [eax + 8]
jmp 0x416f58
mov dword [ebx + 8], 1
jmp 0x416ff0
mov edi, dword [ebp - 0x14]
mov dword [esp], 0x30
call sub.msys_1.0.dll_malloc
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x416ffc
mov dword [esp], ebx
mov ecx, 0x30
xor eax, eax
mov dword [esp + 8], ecx
mov dword [esp + 4], eax
call sub.msys_1.0.dll_memset
mov dword [ebx + 0x10], 0x10
mov edx, dword [ebp - 0x28]
lea ecx, [ebx + 0x20]
mov dword [ebx + 4], 2
mov word [ebx + 0x20], 2
mov dword [ebx + 0x18], ecx
mov word [ecx + 2], dx
mov dword [ecx + 4], edi
jmp 0x416fe2
mov dword [esp], 0x30
call sub.msys_1.0.dll_malloc
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x416ffc
mov dword [esp], ebx
mov eax, 0x30
xor edi, edi
mov dword [esp + 8], eax
mov dword [esp + 4], edi
call sub.msys_1.0.dll_memset
mov dword [ebx + 0x10], 0x10
mov edx, dword [ebp - 0x28]
lea ecx, [ebx + 0x20]
mov dword [ebx + 4], 2
mov word [ebx + 0x20], 2
mov dword [ebx + 0x18], ecx
mov word [ecx + 2], dx
mov dword [ecx + 4], 0x100007f
jmp 0x416fe2
add esp, 0x2c
mov eax, 0x7ffffffe
pop ebx
pop esi
pop edi
pop ebp
ret
mov edx, dword [ebp + 0x14]
mov dword [edx], eax
jmp 0x4170d0
xor eax, eax
jmp 0x41700b
mov edi, dword [ebp + 0x14]
mov eax, dword [edi]
jmp 0x417282
mov esi, dword [eax + 0x1c]
mov dword [esp], eax
call fcn.00419aa0
mov eax, esi
test eax, eax
jne 0x417275
mov eax, 0x7ffffffd
jmp 0x41700b