Function at 0x401f90
Capabilities:
Check http status code
Get file size
Send data
Send http request

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x244
mov eax, dword [0x4c9890]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov bl, byte [ebp + 8]
push esi
movzx eax, bl
push edi
mov edi, dword [ebp + 0xc]
push eax
push str.MultiBlockDownloader::GetInfo__bTryPartial___d
mov esi, ecx
call fcn.00413860
add esp, 8
mov dword [ebp - 0x210], 0x80004005
push esi
push 0x24080000
push 0
push 0
push 0
push dword [esi + 0x3c]
mov dword [esi + 0x3b8], 1
push 0x4a1c20
push dword [esi + 0x50]
mov dword [esi + 0x388], 0
mov dword [esi + 0x38c], 0
mov byte [esi + 0x384], 0
mov dword [esi + 0x390], 0
mov dword [esi + 0x394], 0
call dword [sym.imp.WININET.dll_HttpOpenRequestW]
mov dword [esi + 0x380], eax
test eax, eax
jne 0x402062
lea eax, [ebp - 0x210]
push str.HttpOpenRequest
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpOpenRequest
push 0xfff
push 0x1000
push edi
call fcn.00486606
add esp, 0x10
jmp 0x4023a0
push eax
push 0x4a1c20
push str.HttpOpenRequestW_lpszVerb____s___m_hRequest___.8X
call fcn.00413860
push dword [esi + 0x3c]
push str.m_urlcTarget.lpszUrlPath___s
call fcn.00413860
add esp, 0x14
test bl, bl
je 0x4020c5
push 0x20000000
push 0xffffffffffffffff
push str.RANGE:_bytes0_1
push dword [esi + 0x380]
call dword [sym.imp.WININET.dll_HttpAddRequestHeadersW]
test eax, eax
jne 0x4020c5
lea eax, [ebp - 0x210]
push str.HttpAddRequestHeaders
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpAddRequestHeaders
jmp 0x40204a
push esi
push 8
xorps xmm0, xmm0
push 0
lea eax, [ebp - 0x244]
push eax
push dword [esi + 0x380]
movq qword [ebp - 0x244], xmm0
movq qword [ebp - 0x22c], xmm0
movq qword [ebp - 0x23c], xmm0
movq qword [ebp - 0x234], xmm0
movq qword [ebp - 0x224], xmm0
mov dword [ebp - 0x244], 0x28
mov dword [ebp - 0x228], 0
call dword [sym.imp.WININET.dll_HttpSendRequestExW]
test eax, eax
jne 0x402146
lea eax, [ebp - 0x210]
push 0x4a1dfc
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpSendRequestExW
jmp 0x40204a
push esi
push 0
push 0
push dword [esi + 0x380]
call dword [sym.imp.WININET.dll_HttpEndRequestW]
test eax, eax
jne 0x402181
lea eax, [ebp - 0x210]
push 0x4a1ed4
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpEndRequestW
jmp 0x40204a
mov ebx, dword [sym.imp.WININET.dll_HttpQueryInfoW]
push 0
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x218]
push eax
push 0x20000013
push dword [esi + 0x380]
mov dword [ebp - 0x218], 0
mov dword [ebp - 0x214], 4
call ebx
test eax, eax
jne 0x4021e2
lea eax, [ebp - 0x210]
push str.HttpQueryInfo
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpQueryInfo
jmp 0x40204a
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
call fcn.004866f0
mov eax, dword [ebp - 0x218]
add esp, 0xc
mov dword [ebp - 0x214], 0x104
cmp eax, 0xce
jne 0x4022cf
cmp byte [ebp + 8], 0
je 0x4022fc
push 0
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x20c]
push eax
push 0x35
push dword [esi + 0x380]
call ebx
test eax, eax
jne 0x402269
lea eax, [ebp - 0x210]
push str.HttpQueryInfo
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpQueryInfo_HTTP_QUERY_CONTENT_RANGE
jmp 0x40204a
push dword [ebp - 0x214]
lea eax, [ebp - 0x20c]
push eax
push str.HttpQueryInfoW_HTTP_QUERY_CONTENT_RANGE___szInfo___s__dwInfoSize___d
call fcn.00413860
mov eax, dword [ebp - 0x214]
and eax, 0xfffffffe
add esp, 0xc
cmp eax, 0x208
jae 0x402488
xor ecx, ecx
mov word [ebp + eax - 0x20c], cx
lea eax, [ebp - 0x20c]
push 0x2f
push eax
call fcn.004870a4
add esp, 8
test eax, eax
je 0x4023a0
add eax, 2
push eax
call fcn.00487284
mov byte [esi + 0x384], 1
jmp 0x402387
cmp eax, 0xc8
je 0x4022fc
test edi, edi
je 0x4023a0
push eax
push str.failed_at_HttpQueryInfo_with_HTTP_code__u
push 0xfff
push 0x1000
push edi
call fcn.00486606
add esp, 0x14
jmp 0x4023a0
push 0
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x20c]
push eax
push 5
push dword [esi + 0x380]
call ebx
test eax, eax
jne 0x40233c
lea eax, [ebp - 0x210]
push str.HttpQueryInfo
push eax
call fcn.004015b0
add esp, 8
test edi, edi
je 0x4023a0
push str.failed_at_HttpQueryInfo_HTTP_QUERY_CONTENT_LENGTH
jmp 0x40204a
push dword [ebp - 0x214]
lea eax, [ebp - 0x20c]
push eax
push str.HttpQueryInfoW_HTTP_QUERY_CONTENT_LENGTH___szInfo___I64d__dwInfoSize___d
call fcn.00413860
mov eax, dword [ebp - 0x214]
and eax, 0xfffffffe
add esp, 0xc
cmp eax, 0x208
jae 0x402488
xor ecx, ecx
mov word [ebp + eax - 0x20c], cx
lea eax, [ebp - 0x20c]
push eax
call fcn.00487284
mov byte [esi + 0x384], 0
mov dword [ebp - 0x210], 0
mov dword [esi + 0x38c], edx
mov dword [esi + 0x388], eax
add esp, 4
cmp byte [esi + 0x384], 0
je 0x4023b0
push str.Support_Partial:_true
jmp 0x4023b5
push str.Support_Partial:_false
call fcn.00413860
mov eax, dword [esi + 0x380]
add esp, 4
test eax, eax
je 0x4023e6
push 0
push eax
call dword [sym.imp.WININET.dll_InternetSetStatusCallbackW]
push dword [esi + 0x380]
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [esi + 0x380], 0
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
lea eax, [esi + 0x3c8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x402447
lea eax, [ebp - 0x21c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov ecx, dword [ebp - 0x21c]
mov eax, dword [ebp - 0x218]
push edi
mov dword [esi + 0x390], ecx
mov dword [esi + 0x394], eax
mov dword [esi + 0x398], ecx
mov dword [esi + 0x39c], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x40246f
mov dword [esi + 0x390], 0
mov dword [esi + 0x394], 0
mov dword [esi + 0x398], 0
mov dword [esi + 0x39c], 0
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x210]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00487c50
mov esp, ebp
pop ebp
ret 8
call fcn.0048697a
int3