Function at 0x4094d0
Capabilities:
Check if file exists
Create directory
Download and write a file
Get file attributes
Get http content length
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x44601b
mov eax, dword fs:[0]
push eax
sub esp, 0x81c
mov eax, dword [0x4594f0]
xor eax, esp
mov dword [esp + 0x818], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4594f0]
xor eax, esp
push eax
lea eax, [esp + 0x830]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x840]
xor ebx, ebx
push ebx
lea eax, [esp + 0x24]
push eax
mov edi, ecx
lea ecx, [esp + 0x24]
push ecx
push 0x20000005
push ebp
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], 4
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
test eax, eax
jne 0x409541
mov dword [esp + 0x1c], ebx
push edi
lea ecx, [esp + 0x18]
call fcn.00411b80
mov esi, eax
mov eax, dword [esi]
push 0x5c
push eax
call fcn.00431467
add esp, 8
cmp eax, ebx
jne 0x409563
or esi, 0xffffffff
jmp 0x409567
sub eax, dword [esi]
mov esi, eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x409587
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push edi
lea ecx, [esp + 0x2c]
call fcn.00411b80
inc esi
push esi
lea ecx, [esp + 0x18]
push ecx
mov ecx, eax
mov dword [esp + 0x840], ebx
call fcn.00409bd0
mov dword [esp + 0x838], 0xffffffff
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4095d1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4095e9
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push ebx
push 0x80
push 2
push ebx
push 3
push 0x40000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x40962a
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409623
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor al, al
jmp 0x4096d9
mov ebx, dword [sym.imp.WININET.dll_InternetReadFile]
lea ecx, [esp + 0x18]
push ecx
push 0x800
lea edx, [esp + 0x34]
push edx
push ebp
call ebx
mov ecx, dword [esp + 0x18]
mov esi, ecx
test eax, eax
je 0x40969d
test ecx, ecx
jbe 0x409699
push 0
lea eax, [esp + 0x28]
push eax
push ecx
lea ecx, [esp + 0x38]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp esi, dword [esp + 0x24]
jne 0x40969d
lea edx, [esp + 0x18]
push edx
push 0x800
lea eax, [esp + 0x34]
push eax
push ebp
call ebx
mov ecx, dword [esp + 0x18]
mov esi, ecx
test eax, eax
jne 0x40964c
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
jmp 0x40960a
test eax, eax
jne 0x4096b0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
jmp 0x40960a
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4096d7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, 1
mov ecx, dword [esp + 0x830]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x818]
xor ecx, esp
call fcn.0042f79c
add esp, 0x828
ret 4