Function at 0x405d6a
Capabilities:
Check internet connectivity via wininet
Create http request
Get http content length
Read data from internet
Receive data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4319ed
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
mov eax, 0x10094
call fcn.00410ea0
push edi
mov dword [ebp - 4], 2
push 0
lea eax, [ebp - 0x1007c]
push eax
call dword [sym.imp.WININET.dll_InternetGetConnectedState]
mov cl, byte [0x444ad8]
mov byte [ebp - 0x1006c], cl
mov ecx, 0xf
xor eax, eax
lea edi, [ebp - 0x1006b]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov edx, dword [ebp - 0x1007c]
and edx, 4
test edx, edx
jne 0x405de8
push 0
push 0
push 0
push 4
lea eax, [ebp - 0x1006c]
push eax
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [ebp - 0x10], eax
jmp 0x405e00
push 0
push 0
push 0
push 0
lea ecx, [ebp - 0x1006c]
push ecx
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x405e50
push 0
push 0
push str.Internetl
call fcn.0042ba76
mov dword [ebp - 0x10090], 0xffffffff
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00425c03
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00425c03
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00425c03
mov eax, dword [ebp - 0x10090]
jmp 0x406156
mov edx, dword [str.Accept:___r_n_r_n]
mov dword [ebp - 0x20], edx
mov eax, dword [0x440170]
mov dword [ebp - 0x1c], eax
mov ecx, dword [0x440174]
mov dword [ebp - 0x18], ecx
mov edx, dword [0x440178]
mov dword [ebp - 0x14], edx
lea ecx, [ebp - 0x1008c]
call fcn.00429176
mov byte [ebp - 4], 3
push 0
push 0x84000100
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp + 8]
call fcn.00405760
push eax
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.WININET.dll_InternetOpenUrlA]
mov dword [ebp - 0x10074], eax
cmp dword [ebp - 0x10074], 0
jne 0x405f13
push 0
push 0
push 0x44017c
call fcn.0042ba76
mov dword [ebp - 0x10094], 0xffffffff
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1008c]
call fcn.004291cb
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00425c03
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00425c03
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00425c03
mov eax, dword [ebp - 0x10094]
jmp 0x406156
push 0
push 0x1001
lea ecx, [ebp + 0xc]
call fcn.00405760
push eax
lea ecx, [ebp - 0x1008c]
call fcn.00429288
test eax, eax
jne 0x405f8b
push 0
push 0
push 0x44018c
call fcn.0042ba76
mov dword [ebp - 0x10098], 0xffffffff
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1008c]
call fcn.004291cb
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00425c03
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00425c03
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00425c03
mov eax, dword [ebp - 0x10098]
jmp 0x406156
mov dword [ebp - 0x10028], 0
mov dword [ebp - 0x10024], 4
mov dword [ebp - 0x10070], 0
push 0
lea eax, [ebp - 0x10024]
push eax
lea ecx, [ebp - 0x10028]
push ecx
push 0x20000005
mov edx, dword [ebp - 0x10074]
push edx
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
test eax, eax
jne 0x405fd9
mov dword [ebp - 0x10028], 0
lea eax, [ebp - 0x1002c]
push eax
push 0x4000
lea ecx, [ebp - 0x10020]
push ecx
mov edx, dword [ebp - 0x10074]
push edx
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x406061
push 0
push 0
push 0x4401a0
call fcn.0042ba76
lea ecx, [ebp - 0x1008c]
call fcn.004294a3
mov dword [ebp - 0x1009c], 0xffffffff
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1008c]
call fcn.004291cb
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00425c03
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00425c03
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00425c03
mov eax, dword [ebp - 0x1009c]
jmp 0x406156
cmp dword [ebp - 0x1002c], 0
jne 0x40606c
jmp 0x406092
mov eax, dword [ebp - 0x1002c]
push eax
lea ecx, [ebp - 0x10020]
push ecx
lea ecx, [ebp - 0x1008c]
call fcn.004293df
mov edx, 1
test edx, edx
jne 0x405fd9
lea ecx, [ebp - 0x10078]
call fcn.00405700
mov byte [ebp - 4], 4
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push 0x4401ac
lea eax, [ebp - 0x10078]
push eax
call fcn.00423bd6
add esp, 0xc
push 0x4401b0
lea ecx, [ebp + 0x10]
push ecx
call fcn.00409220
and eax, 0xff
test eax, eax
je 0x4060ec
push 0xa
lea ecx, [ebp - 0x10078]
call fcn.00405760
push eax
lea ecx, [ebp - 0x1008c]
call fcn.004293df
lea ecx, [ebp - 0x1008c]
call fcn.004294a3
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x100a0], 0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x10078]
call fcn.00425c03
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x1008c]
call fcn.004291cb
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00425c03
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00425c03
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00425c03
mov eax, dword [ebp - 0x100a0]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
mov esp, ebp
pop ebp
ret