Function at 0x40a5c0
Capabilities:
Connect to http server
Read data from internet
Receive data
Send data
Send http request

Disassembly:
push ebp
lea ebp, [esp - 0x2870]
mov eax, 0x2870
call fcn.004110f0
push 0xffffffffffffffff
push 0x420008
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x42a42c]
xor eax, ebp
mov dword [ebp + 0x286c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, dword [ebp + 0x2878]
mov esi, ecx
lea ecx, [ebp]
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x20], edi
mov dword [ebp - 4], 0
call fcn.004078d0
mov ecx, dword [str.http]
push 4
push ecx
lea edx, [ebp]
mov eax, 0x50
push 0x21
mov ebx, 2
push edx
mov dword [ebp + 0x2450], ebx
mov dword [ebp + 0x2454], 4
mov word [ebp + 0x244c], ax
call fcn.00410e87
push eax
call fcn.004011a0
add esp, 0x14
lea eax, [ebp - 0x18]
push eax
mov ecx, edi
call fcn.0040a480
mov eax, dword [eax]
push 0
push eax
lea ecx, [ebp]
call fcn.0040a320
mov eax, dword [ebp - 0x18]
lea ecx, [eax - 0xc]
cmp ecx, dword [0x429010]
je 0x40a69e
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40a69e
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff4
push eax
call fcn.00410a7b
add esp, 4
mov eax, dword [esi]
test eax, eax
je 0x40a8fe
mov edx, dword [ebp + 0x2450]
mov ecx, dword [ebp + 0x244c]
push 1
push 0
inc edx
push edx
push 0
push 0
push ecx
lea edx, [ebp + 0x42]
push edx
push eax
call dword [sym.imp.WININET.dll_InternetConnectW]
mov edi, eax
mov dword [ebp - 0x28], edi
test edi, edi
je 0x40a8fb
lea eax, [ebp + 0x448]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0040a2b0
lea ecx, [ebp + 0x144a]
push ecx
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edx, [ebp + 0x144a]
push edx
push eax
lea ecx, [ebp - 0x1c]
call fcn.00407ec0
mov ecx, dword [ebp - 0x20]
lea eax, [ebp - 0x18]
push eax
call fcn.0040a430
mov esi, dword [eax]
push 0
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], bl
call fcn.00408430
push 1
push 0x400000
push 0x4295f0
push 0
push 0
push eax
push esi
push edi
call dword [sym.imp.WININET.dll_HttpOpenRequestW]
mov esi, eax
mov eax, dword [ebp - 0x18]
lea ecx, [eax - 0xc]
mov byte [ebp - 4], 1
cmp ecx, dword [0x429010]
je 0x40a76c
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40a76c
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff4
push eax
call fcn.00410a7b
add esp, 4
test esi, esi
je 0x40a8c5
mov ebx, dword [sym.imp.WININET.dll_HttpSendRequestW]
push 0
push 0
push 0
push 0
push esi
call ebx
mov edi, eax
test edi, edi
je 0x40a8bb
push 0x13
push esi
call fcn.00407130
add esp, 8
cmp eax, 0x197
jne 0x40a7e1
mov ecx, dword [ebp - 0x14]
mov eax, 1
push 0x14
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x34], eax
lea eax, [ebp - 0x3c]
lea edx, [ebp - 0x48]
push eax
mov dword [ebp - 0x2c], edx
mov edx, dword [ecx]
push 0x4b
xor edi, edi
push edx
mov dword [ebp - 0x3c], 0x14
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x30], edi
call dword [sym.imp.WININET.dll_InternetSetOptionW]
push edi
push edi
push edi
push edi
push esi
call ebx
mov edi, eax
test edi, edi
je 0x40a8bb
push 0x13
push esi
call fcn.00407130
mov ebx, dword [ebp - 0x20]
add esp, 8
push eax
mov ecx, ebx
call fcn.00408830
push 0x16
lea eax, [ebp - 0x24]
push esi
push eax
call fcn.0040a4d0
add esp, 0xc
push ecx
lea edx, [ebp - 0x24]
mov ecx, esp
mov dword [ebp - 0x14], esp
push edx
mov byte [ebp - 4], 3
call fcn.0040a270
mov ecx, ebx
call fcn.00408a30
push 5
push esi
call fcn.00407130
add esp, 8
push eax
mov ecx, ebx
call fcn.00408b90
push 0
mov ecx, ebx
call fcn.00408930
xor edi, edi
lea eax, [ebp - 0x14]
push eax
push 0x400
lea ecx, [ebp + 0x246c]
push ecx
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x40a884
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x40a884
push eax
lea edx, [ebp + 0x246c]
push edx
mov ecx, ebx
call fcn.00408620
add edi, dword [ebp - 0x14]
mov ecx, ebx
push edi
call fcn.00408930
jmp 0x40a846
push edi
mov ecx, ebx
call fcn.00408c90
mov eax, dword [ebp - 0x24]
lea ecx, [eax - 0xc]
mov byte [ebp - 4], 1
cmp ecx, dword [0x429010]
je 0x40a8bb
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40a8bb
mov eax, dword [ebp - 0x24]
add eax, 0xfffffff4
push eax
call fcn.00410a7b
add esp, 4
push esi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov edi, dword [ebp - 0x28]
push edi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, dword [ebp - 0x1c]
lea edx, [eax - 0xc]
mov byte [ebp - 4], 0
cmp edx, dword [0x429010]
je 0x40a8fb
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40a8fb
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff4
push eax
call fcn.00410a7b
add esp, 4
mov edi, dword [ebp - 0x20]
mov ecx, edi
call fcn.004070d0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x286c]
xor ecx, ebp
call fcn.00410992
add ebp, 0x2870
mov esp, ebp
pop ebp
ret 0x10