Function at 0x4115be
Capabilities:
Check for time delay via gettickcount

Disassembly:
push 0x44
mov eax, 0x457734
call fcn.0043dfc3
push str.DownloadFileAndWait__
lea ecx, [ebp - 0x1c]
call fcn.0040215a
xor esi, esi
push esi
lea eax, [ebp - 0x1c]
push eax
push 2
mov dword [ebp - 4], esi
call fcn.0040ed4d
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
xor eax, eax
cmp dword [0x48e50c], esi
sete al
xor ebx, ebx
inc ebx
push ebx
push ebx
mov dword [ebp - 0x2c], eax
call fcn.00407a9a
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x4c], esi
xor eax, eax
lea edi, [ebp - 0x48]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
push 0x3c
stosd dword es:[edi], eax
mov dword [ebp - 0x10], esi
call fcn.0042a85e
pop ecx
mov dword [ebp - 0x34], eax
mov dword [ebp - 4], ebx
cmp eax, esi
je 0x411649
push dword [0x48e95c]
push eax
call fcn.0040c26e
mov edi, eax
mov dword [ebp - 0x14], edi
jmp 0x41164e
mov dword [ebp - 0x14], esi
mov edi, esi
or dword [ebp - 4], 0xffffffff
cmp dword [edi], esi
jne 0x41169f
push str.DownloadFileAndWait__:_queue_is_empty
lea ecx, [ebp - 0x1c]
call fcn.0040215a
mov dword [ebp - 4], 2
push dword [edi + 0xc]
lea eax, [ebp - 0x1c]
push eax
push ebx
call fcn.0040ed4d
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
mov eax, dword [edi + 0xc]
mov ecx, dword [ebp + 0x10]
push edi
mov dword [ecx], eax
call fcn.00411bb0
push 4
pop eax
jmp 0x411baa
push 8
push dword [ebp + 0xc]
push str.https:__
call fcn.0043d225
add esp, 0xc
neg eax
sbb eax, eax
inc eax
mov dword [edi + 0x14], eax
lea eax, [ebp - 0x50]
push eax
lea ebx, [ebp - 0x10]
mov ecx, edi
call fcn.0040ca19
mov ecx, dword [ebp + 0x10]
push esi
push 1
mov dword [ecx], eax
call fcn.00407a9a
call fcn.0042ac34
push eax
lea ecx, [ebp - 0x18]
call fcn.004104de
push str.IDS_ACTION_CONNECTING
lea ecx, [ebp - 0x1c]
mov dword [ebp - 4], 3
call fcn.0040215a
lea esi, [ebp - 0x18]
lea edi, [ebp - 0x1c]
mov ebx, 0x48e460
mov byte [ebp - 4], 4
call fcn.00408548
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.004025dc
mov edx, esi
call fcn.00407aba
mov esi, dword [ebp + 0x10]
mov eax, dword [esi]
test eax, eax
jl 0x4117cc
cmp dword [ebp - 0x10], 2
je 0x41173d
cmp dword [ebp - 0x10], 1
jne 0x4117c1
push str.DownloadFileAndWait:_Last_Bits_job_still_downloading_manifest_or_ARMupdate
lea ecx, [ebp - 0x1c]
call fcn.0040215a
push 0
lea eax, [ebp - 0x1c]
push eax
push 2
mov byte [ebp - 4], 5
call fcn.0040ed4d
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
mov edi, dword [ebp - 0x14]
push 1
push edi
call fcn.0040c3e1
push str.DownloadFileAndWait:_Cancel_Last_BITS_Job
lea ecx, [ebp - 0x1c]
call fcn.0040215a
push 0
lea eax, [ebp - 0x1c]
push eax
push 2
mov byte [ebp - 4], 6
call fcn.0040ed4d
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
mov eax, edi
call fcn.0040c9e6
lea eax, [ebp - 0x50]
push eax
lea ebx, [ebp - 0x10]
mov ecx, edi
call fcn.0040ca19
mov dword [esi], eax
jmp 0x4117c4
mov edi, dword [ebp - 0x14]
mov eax, dword [esi]
test eax, eax
jl 0x4117cf
jmp 0x411823
mov edi, dword [ebp - 0x14]
cmp eax, 0x80200001
je 0x411823
push str.DownloadFileAndWait_isComplete_returns_error
lea ecx, [ebp - 0x1c]
call fcn.0040215a
mov byte [ebp - 4], 7
push dword [esi]
lea eax, [ebp - 0x1c]
push eax
push 1
call fcn.0040ed4d
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
cmp dword [edi + 0x14], 0
je 0x411823
mov eax, edi
call fcn.0040c9e6
lea eax, [ebp - 0x50]
push eax
lea ebx, [ebp - 0x10]
mov ecx, edi
call fcn.0040ca19
mov dword [esi], eax
cmp dword [ebp - 0x10], 6
je 0x411b91
push dword [ebp + 0xc]
lea ecx, [ebp - 0x1c]
call fcn.0040215a
push dword [ebp - 0x2c]
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x1c]
push eax
push edi
mov byte [ebp - 4], 8
call fcn.00411468
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add ecx, 0xfffffff0
mov dword [esi], eax
call fcn.004025dc
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp dword [esi], 0
mov dword [ebp - 0x34], eax
jge 0x41189b
push str.downLoadFileSet___failed
lea ecx, [ebp - 0x1c]
call fcn.0040215a
mov byte [ebp - 4], 9
push dword [esi]
lea eax, [ebp - 0x1c]
push eax
push 1
call fcn.0040ed4d
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
jmp 0x411b7c
lea eax, [ebp - 0x50]
push eax
lea ebx, [ebp - 0x10]
mov ecx, edi
call fcn.0040ca19
xor ebx, ebx
mov dword [esi], eax
cmp dword [0x48e520], ebx
jne 0x411b84
cmp dword [ebp - 0x10], 6
jne 0x411911
cmp dword [0x48e50c], ebx
je 0x411911
push 1
push 0x5a
call fcn.00407a9a
push 0x45fd04
lea ecx, [ebp - 0x20]
call fcn.0040215a
lea esi, [ebp - 0x18]
lea edi, [ebp - 0x20]
mov ebx, 0x48e460
mov byte [ebp - 4], 0xa
call fcn.00408548
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x20]
add ecx, 0xfffffff0
call fcn.004025dc
mov edx, esi
call fcn.00407aba
mov edi, dword [ebp - 0x14]
mov esi, dword [ebp + 0x10]
xor ebx, ebx
jmp 0x411919
push ebx
push 1
call fcn.00407a9a
cmp dword [edi + 0x14], ebx
je 0x411a75
mov eax, dword [esi]
cmp eax, ebx
jge 0x411a7d
cmp eax, 0x801901f8
ja 0x411a75
cmp dword [ebp - 0x10], 1
jne 0x411a75
push dword [ebp + 0xc]
lea ecx, [ebp - 0x1c]
call fcn.0040215a
push str.http:__
push str.https:__
lea eax, [ebp - 0x1c]
push eax
mov byte [ebp - 4], 0xb
call fcn.00408af7
test eax, eax
je 0x411a66
push str.Port_443_Blocked:_HTTPS:___BITS_connection_failed_attempting_HTTP:___connection
lea ecx, [ebp - 0x24]
call fcn.0040215a
push ebx
lea eax, [ebp - 0x24]
xor esi, esi
push eax
inc esi
push esi
mov byte [ebp - 4], 0xc
call fcn.0040ed4d
mov byte [ebp - 4], 0xb
mov ecx, dword [ebp - 0x24]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
mov dword [0x48ea84], esi
mov dword [edi + 0x14], ebx
mov dword [edi + 0x10], ebx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push ebx
push esi
mov dword [ebp - 0x34], eax
call fcn.00407a9a
push str.IDS_ACTION_CONNECTING
lea ecx, [ebp - 0x28]
call fcn.0040215a
lea esi, [ebp - 0x18]
lea edi, [ebp - 0x28]
mov ebx, 0x48e460
mov byte [ebp - 4], 0xd
call fcn.00408548
mov byte [ebp - 4], 0xb
mov ecx, dword [ebp - 0x28]
add ecx, 0xfffffff0
call fcn.004025dc
mov edx, esi
call fcn.00407aba
mov eax, dword [ebp - 0x14]
call fcn.0040c9e6
cmp dword [0x48e520], 0
jne 0x411afa
push dword [ebp - 0x2c]
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x1c]
push eax
push dword [ebp - 0x14]
call fcn.00411468
mov esi, dword [ebp + 0x10]
add esp, 0xc
mov dword [esi], eax
test eax, eax
jge 0x411a50
push str.downLoadFileSet_HTTP:____failed
lea ecx, [ebp - 0x30]
call fcn.0040215a
mov byte [ebp - 4], 0xe
push dword [esi]
lea eax, [ebp - 0x30]
push eax
push 1
call fcn.0040ed4d
mov ecx, dword [ebp - 0x30]
add esp, 0xc
add ecx, 0xfffffff0
call fcn.004025dc
jmp 0x411a61
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x50]
push eax
lea ebx, [ebp - 0x10]
call fcn.0040ca19
mov dword [esi], eax
mov edi, dword [ebp - 0x14]
xor ebx, ebx
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.004025dc
cmp dword [esi], ebx
jl 0x411b0e
cmp dword [ebp - 0x4c], ebx
ja 0x411aa8
cmp dword [ebp - 0x50], 1
ja 0x411aa8
cmp dword [0x48e50c], ebx
je 0x411ab0
mov eax, dword [0x48e510]
neg eax
sbb eax, eax
and eax, 0x384
add eax, 0x64
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
push ebx
push 1
call fcn.00407a9a
cmp dword [0x48e520], ebx
jne 0x411b84
cmp dword [ebp - 0x10], 6
je 0x411ad7
cmp dword [edi + 0x14], ebx
jne 0x411ad7
call dword [sym.imp.KERNEL32.dll_GetTickCount]
inc eax
sub eax, dword [ebp - 0x34]
dec eax
cmp eax, dword [ebp + 0x14]
ja 0x411b4c
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [0x48e520], ebx
jne 0x411b84
cmp dword [ebp - 0x10], 6
jne 0x41189b
jmp 0x411b91
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.004025dc
mov edi, dword [ebp - 0x14]
jmp 0x411b8a
push str.HTTPS_and_HTTP_connection_failed
lea ecx, [ebp - 0x34]
call fcn.0040215a
lea eax, [ebp - 0x34]
push eax
mov byte [ebp - 4], 0xf
mov ecx, dword [esi]
push 0x222e0
mov edx, 0x48eabc
call fcn.0040d172
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x34]
add ecx, 0xfffffff0
call fcn.004025dc
mov eax, edi
call fcn.0040c9e6
jmp 0x411b84
push str.Network_too_slow_or_no_connection
lea ecx, [ebp - 0x34]
call fcn.0040215a
lea eax, [ebp - 0x34]
push eax
push 0x222e0
mov ecx, 0x80200010
mov edx, 0x48eabc
mov byte [ebp - 4], 0x10
call fcn.0040d172
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x34]
add ecx, 0xfffffff0
call fcn.004025dc
cmp dword [ebp - 0x10], 6
je 0x411b91
mov eax, edi
call fcn.0040c9e6
mov esi, dword [ebp - 0x10]
push edi
mov dword [edi + 0x38], esi
call fcn.00411bb0
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
call fcn.004025dc
mov eax, esi
call fcn.0043e09b
ret