Function at 0x406d04
Capabilities:
Check for time delay via gettickcount
Resolve dns

Disassembly:
push ebp
sub esp, 0x214
lea ebp, [esp - 4]
mov eax, dword [0x449e30]
xor eax, ebp
mov dword [ebp + 0x214], eax
push 0x44
mov eax, 0x43255d
call fcn.004217ef
mov dword [ebp - 0x20], ecx
xor edi, edi
push edi
push str.CGetAnyServerAux::UserWorkItemCallback
lea ecx, [ebp + 0x1ac]
call fcn.004107dc
mov dword [ebp - 4], edi
mov dword [ebp - 0x30], edi
mov ecx, dword [ebp - 0x20]
call fcn.004026fb
test al, al
je 0x40706b
mov byte [ebp - 4], 1
mov dword [ebp - 0x38], edi
lea ecx, [ebp]
call fcn.004036cd
mov byte [ebp - 4], 2
lea ecx, [ebp]
call fcn.00403dbf
push eax
lea ecx, [ebp - 0x14]
call fcn.00402066
mov byte [ebp - 4], 3
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x38], edi
jne 0x406dc5
mov ebx, dword [ebp - 0x14]
cmp ebx, edi
je 0x406d9c
mov ecx, ebx
call fcn.00401440
jmp 0x406d9e
xor eax, eax
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
cmp eax, edi
jne 0x406e25
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str._Error_occures_when_try_to_gethostbyname._Error_code__d_
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0x10
call esi
mov ebx, eax
mov dword [ebp - 0x1c], edi
or dword [ebp - 0x34], 0xffffffff
cmp dword [ebp - 0x1c], edi
jne 0x406ed3
lea eax, [ebp - 0x1c]
push eax
push edi
push edi
push edi
push edi
push 6
call sub.DNSAPI.dll_DnsQueryConfig
mov dword [ebp - 0x34], eax
call esi
sub eax, ebx
cmp eax, 0x4e20
ja 0x406ed3
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [ebp - 0x20]
call fcn.004026fb
test al, al
jne 0x406dd0
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x14]
cmp ecx, edi
je 0x406ec2
jmp 0x406eba
movzx ecx, word [eax + 8]
cmp cx, 2
je 0x406e3d
movsx eax, cx
push eax
push str._Unknown_address_type__d_
jmp 0x406db5
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
push dword [eax]
call dword [sym.imp.WS2_32.dll_ntohl]
cmp eax, 0x7f000001
jne 0x406e73
push str.LOOPBACK._Waiting_while_NETWORK_start.
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0xc
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x406e90
push eax
push str.NETWORK_STARTED____Network_address__0x_X
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0x10
mov dword [ebp - 0x38], 1
call esi
sub eax, dword [ebp - 0x2c]
cmp eax, 0x4e20
ja 0x406dc5
mov ecx, dword [ebp - 0x20]
call fcn.004026fb
test al, al
jne 0x406d87
mov byte [ebp - 4], 2
cmp ebx, edi
je 0x406ec2
mov ecx, ebx
call fcn.0040352c
mov dword [ebp - 0x14], edi
mov byte [ebp - 4], 1
lea ecx, [ebp]
call fcn.00403710
jmp 0x40706b
push dword [ebp - 0x1c]
push dword [ebp - 0x34]
push str.Server_list_returned_with_error_0x_X__size__d
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0x14
call esi
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x1c], edi
je 0x40702e
push edi
push dword [ebp - 0x1c]
lea ecx, [ebp - 0x40]
call fcn.004022d5
mov byte [ebp - 4], 4
lea eax, [ebp - 0x1c]
push eax
push dword [ebp - 0x3c]
push edi
push edi
push edi
push 6
call sub.DNSAPI.dll_DnsQueryConfig
push eax
call fcn.004014cf
pop ecx
mov ebx, dword [ebp - 0x3c]
xor eax, eax
mov dword [ebp - 0x18], eax
cmp eax, dword [ebx]
jae 0x406f58
push dword [ebx + eax*4 + 4]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push str.DNS_Server_IP__s
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0x10
inc dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
jmp 0x406f2c
lea ecx, [ebp - 0x28]
call fcn.00403062
mov byte [ebp - 4], 5
mov dword [ebp - 0x24], 0x80004005
cmp dword [ebp - 0x24], edi
je 0x407001
xor eax, eax
mov dword [ebp - 0x18], eax
cmp eax, dword [ebx]
jae 0x406fa4
push 0x3e8
push dword [ebx + eax*4 + 4]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
lea ecx, [ebp - 0x28]
call fcn.004030d9
mov dword [ebp - 0x24], eax
cmp eax, edi
je 0x407001
inc dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
jmp 0x406f79
cmp dword [ebp - 0x24], edi
je 0x407001
push dword [ebp - 0x24]
push str.Cannot_ping_DNS_server._Result_is_0x_X
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0x10
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
call esi
sub eax, dword [ebp - 0x2c]
cmp eax, 0x4e20
ja 0x407016
mov ecx, dword [ebp - 0x20]
call fcn.004026fb
test al, al
jne 0x406f6b
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x28]
call fcn.004030a0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x40]
call fcn.004021fa
jmp 0x406e11
push str.Dns_servers_pings_succesfully___
push edi
lea eax, [ebp + 0x1ac]
push eax
call fcn.00410918
add esp, 0xc
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x28]
call fcn.004030a0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x40]
call fcn.004021fa
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x14]
cmp ecx, edi
je 0x407041
call fcn.0040352c
mov dword [ebp - 0x14], edi
mov byte [ebp - 4], 1
lea ecx, [ebp]
call fcn.00403710
mov dword [ebp - 4], edi
push dword [ebp - 0x30]
push 0x4376ce
lea ecx, [ebp + 0x1ac]
call fcn.00410b8f
mov ecx, dword [ebp - 0x20]
call fcn.00406b9b
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x1ac]
call fcn.00410891
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x214]
xor ecx, ebp
call fcn.004217ad
add ebp, 0x218
leave
ret