Function at 0x404520
Capabilities:
Create http request
Read data from internet
Receive data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x46dce0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x1030
call fcn.00419250
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 0x10], esp
push 0
push 0
push 0
push 0
push str.BillUrl
mov dword [ebp - 0x18], ebx
mov dword [ebp - 4], 0
call dword [sym.imp.WININET.dll_InternetOpenA]
mov edi, eax
test edi, edi
mov dword [ebp - 0x40], edi
je 0x40462f
mov al, byte [ebp + 0xb]
push 0
lea ecx, [ebp - 0x3c]
mov byte [ebp - 0x3c], al
call fcn.00403160
mov cl, byte [ebp + 0xb]
push 0
mov byte [ebp - 0x2c], cl
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 1
call fcn.00403160
lea edx, [ebp - 0x3c]
mov ecx, ebx
push edx
mov byte [ebp - 4], 2
call fcn.004052d0
lea eax, [ebp - 0x2c]
lea edx, [ebp - 0x3c]
push eax
sub esp, 0x10
mov ecx, esp
mov dword [ebp - 0x1c], esp
push edx
call fcn.00402df0
mov ecx, ebx
call fcn.004060e0
mov eax, dword [ebp - 0x38]
test eax, eax
jne 0x4045d0
mov eax, 0x473a84
push eax
push 0x4881a0
push str.GetBillUrlAddr__
push str._BILLHTTP
call fcn.004094d0
mov eax, dword [ebp - 0x28]
add esp, 0x10
test eax, eax
jne 0x4045f4
mov eax, 0x473a84
push eax
push 0x4881a0
push str.GetBillHeader__
push str._BILLHTTP
call fcn.004094d0
mov eax, dword [ebp - 0x34]
add esp, 0x10
test eax, eax
jne 0x404642
push 1
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 1
call fcn.00403160
push 1
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 0
call fcn.00403160
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 0x28]
test ecx, ecx
jne 0x40464e
mov ecx, 0x473a84
mov eax, dword [ebp - 0x38]
test eax, eax
jne 0x40465a
mov eax, 0x473a84
mov edx, dword [ebp - 0x24]
push 0
push 0x4000000
push edx
push ecx
push eax
push edi
call dword [sym.imp.WININET.dll_InternetOpenUrlA]
mov esi, eax
test esi, esi
mov dword [ebp - 0x1c], esi
je 0x4047c8
mov dword [ebp - 0x14], 1
jmp 0x404687
mov ebx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x14]
test eax, eax
jbe 0x404797
lea eax, [ebp - 0x14]
lea ecx, [ebp - 0x840]
push eax
push 0x3ff
push ecx
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
mov ecx, 0xff
xor eax, eax
lea edi, [ebp - 0x43f]
mov byte [ebp - 0x440], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x1ff
xor eax, eax
lea edi, [ebp - 0x103e]
mov word [ebp - 0x1040], 0
rep stosd dword es:[edi], eax
mov edx, dword [ebp - 0x14]
push 0x400
stosw word es:[edi], ax
lea eax, [ebp - 0x840]
lea ecx, [ebp - 0x1040]
push eax
push ecx
mov ecx, ebx
mov byte [ebp + edx - 0x840], 0
call fcn.004048a0
lea edx, [ebp - 0x1040]
push 0x400
lea eax, [ebp - 0x440]
push edx
push eax
mov ecx, ebx
call fcn.00404850
lea edi, [ebp - 0x440]
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [ebp + 8]
repne scasb al, byte es:[edi]
mov eax, dword [edx + 8]
not ecx
dec ecx
mov edi, ecx
mov ecx, dword [0x473a88]
sub ecx, eax
cmp ecx, edi
ja 0x404744
call fcn.0043f3a0
test edi, edi
jbe 0x404687
mov ecx, dword [ebp + 8]
push 0
mov ebx, dword [ecx + 8]
add ebx, edi
push ebx
call fcn.004032f0
test al, al
je 0x404684
mov eax, dword [ebp + 8]
mov ecx, edi
lea esi, [ebp - 0x440]
mov edi, dword [eax + 8]
mov edx, dword [eax + 4]
add edi, edx
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [ebp - 0x1c]
mov dword [eax + 8], ebx
mov eax, dword [eax + 4]
mov byte [eax + ebx], 0
jmp 0x404684
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 4]
test eax, eax
jne 0x4047a6
mov eax, 0x473a84
push eax
push 0x4881a0
push str.GetBillUrlResult__
push str._BILLHTTP
call fcn.004094d0
add esp, 0x10
push esi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov edi, dword [ebp - 0x40]
push edi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x28]
xor esi, esi
cmp ecx, esi
je 0x4047f4
mov al, byte [ecx - 1]
test al, al
je 0x4047ea
cmp al, 0xff
je 0x4047ea
dec al
mov byte [ecx - 1], al
jmp 0x4047f4
dec ecx
push ecx
call fcn.00459108
add esp, 4
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x28], esi
cmp ecx, esi
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x20], esi
je 0x40462f
mov al, byte [ecx - 1]
test al, al
je 0x40482b
cmp al, 0xff
je 0x40482b
dec al
mov byte [ecx - 1], al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
dec ecx
push ecx
call fcn.00459108
mov ecx, dword [ebp - 0xc]
add esp, 4
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4