Function at 0x4ca579
Capabilities:
Check http status code
Get http content length

Disassembly:
push ebp
lea ebp, [esp - 0x79c]
sub esp, 0x81c
mov eax, dword [0x516ad4]
xor ecx, ecx
cmp dword [ebx + 0x74], ecx
push esi
mov dword [ebp + 0x798], eax
push edi
je 0x4ca7fc
cmp dword [ebx + 0x80], ecx
je 0x4ca7fc
mov esi, dword [0x51a438]
mov eax, dword [ebx + 0x40]
cmp eax, ecx
mov edi, esi
mov dword [ebp - 0x74], ecx
mov dword [ebp - 0x78], 4
mov dword [ebp - 0x6c], edi
mov dword [ebp - 0x70], esi
je 0x4ca5e9
push dword [eax + 0x10]
lea eax, [ebp - 0x6c]
call fcn.00403266
mov eax, dword [ebx + 0x40]
push dword [eax + 0x14]
lea eax, [ebp - 0x70]
call fcn.00403266
mov esi, dword [ebp - 0x70]
mov edi, dword [ebp - 0x6c]
push 0
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x74]
push eax
push 0x20000013
push dword [ebx + 0x74]
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
jne 0x4ca61e
add esi, 0xfffffff4
cmp esi, dword [0x51a43c]
je 0x4ca616
push esi
call fcn.004013aa
lea eax, [edi - 0xc]
jmp 0x4ca7ee
mov eax, dword [ebp - 0x74]
cmp eax, 0x197
jne 0x4ca662
cmp dword [ebx + 0xa0], 0
jne 0x4ca6d7
mov eax, dword [edi - 8]
test eax, eax
mov edi, dword [sym.imp.WININET.dll_InternetSetOptionW]
je 0x4ca651
lea eax, [eax + eax + 2]
push eax
push dword [ebp - 0x6c]
push 0x2b
push dword [ebx + 0x74]
call edi
mov eax, dword [esi - 8]
test eax, eax
je 0x4ca6a2
lea eax, [eax + eax + 2]
push eax
push esi
push 0x2c
jmp 0x4ca69d
cmp eax, 0x191
jne 0x4ca6d7
cmp dword [ebx + 0xa0], 0
jne 0x4ca6d7
mov eax, dword [edi - 8]
test eax, eax
mov edi, dword [sym.imp.WININET.dll_InternetSetOptionW]
je 0x4ca68e
lea eax, [eax + eax + 2]
push eax
push dword [ebp - 0x6c]
push 0x1c
push dword [ebx + 0x74]
call edi
mov eax, dword [esi - 8]
test eax, eax
je 0x4ca6a2
lea eax, [eax + eax + 2]
push eax
push esi
push 0x1d
push dword [ebx + 0x74]
call edi
xor edi, edi
inc edi
add esi, 0xfffffff4
cmp esi, dword [0x51a43c]
mov dword [ebx + 0xa0], edi
je 0x4ca6bc
push esi
call fcn.004013aa
mov eax, dword [ebp - 0x6c]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca6d0
push eax
call fcn.004013aa
mov eax, edi
jmp 0x4ca7fe
cmp eax, 0x190
mov dword [ebx + 0x34], eax
jae 0x4ca605
push 0
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x74]
push eax
push 0x20000005
push dword [ebx + 0x74]
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
je 0x4ca605
mov eax, dword [ebp - 0x74]
and word [ebp - 0x68], 0
mov dword [ebx + 0x38], eax
xor eax, eax
mov ecx, 0x1ff
lea edi, [ebp - 0x66]
rep stosd dword es:[edi], eax
push 0
stosw word es:[edi], ax
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x68]
push eax
push 1
push dword [ebx + 0x74]
mov dword [ebp - 0x80], 0x400
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
jne 0x4ca746
lea eax, [esi - 0xc]
jmp 0x4ca7da
lea eax, [ebp - 0x68]
push eax
lea edi, [ebp - 0x7c]
call fcn.004031b3
lea esi, [ebx + 0x3c]
call fcn.00410c3f
mov edi, eax
mov eax, esi
call fcn.00403223
mov eax, dword [ebp - 0x7c]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca777
push eax
call fcn.004013aa
push 0x503308
xor ecx, ecx
call fcn.00410c59
test eax, eax
jge 0x4ca7d4
mov eax, dword [ebx + 0x80]
mov ecx, dword [eax + 0x1c]
test ecx, ecx
jne 0x4ca7ca
mov ecx, dword [ebx + 0x68]
add ecx, dword [ebx + 0x38]
mov dword [eax + 0x1c], ecx
mov eax, dword [ebp - 0x70]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca7b1
push eax
call fcn.004013aa
mov eax, dword [ebp - 0x6c]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca7c5
push eax
call fcn.004013aa
push 2
pop eax
jmp 0x4ca7fe
mov eax, dword [ebx + 0x68]
add eax, dword [ebx + 0x38]
cmp ecx, eax
je 0x4ca79d
mov eax, dword [ebp - 0x70]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca7e8
push eax
call fcn.004013aa
mov eax, dword [ebp - 0x6c]
add eax, 0xfffffff4
cmp eax, dword [0x51a43c]
je 0x4ca7fc
push eax
call fcn.004013aa
xor eax, eax
mov ecx, dword [ebp + 0x798]
pop edi
pop esi
call fcn.004eae3c
add ebp, 0x79c
leave
ret