Function at 0x46eb50
Capabilities:
Receive http response
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c95b8
mov eax, dword fs:[0]
push eax
sub esp, 0x44
push ebx
push esi
push edi
mov eax, dword [0x5142b0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor ebx, ebx
lea ecx, [ebp - 0x50]
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x1c], ebx
call fcn.0046d5a0
mov esi, dword [ebp + 0x44]
lea eax, [ebp - 0x50]
mov dword [ebp - 4], ebx
cmp eax, esi
je 0x46ebb4
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
push eax
push ecx
lea ecx, [ebp + 0x44]
push ecx
lea ecx, [ebp - 0x50]
call fcn.0046d060
push esi
lea ecx, [ebp - 0x50]
call fcn.0046d2e0
mov edi, dword [ebp + 0x40]
mov edx, dword [edi + 8]
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp + 0x44], edx
mov dword [ebp + 0x40], eax
mov dword [ebp - 0x18], ecx
mov edi, edi
mov esi, dword [ebp + 0x44]
lea edx, [ebp - 0x10]
push edx
push esi
mov dword [ebp - 0x10], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
jne 0x46ed11
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push ebx
push str.InternetGetRequestEx_:_Error_occured_in_WinHttpQueryDataAvailable______lu__n
call fcn.00423ad0
push ebx
call fcn.00464180
add esp, 0xc
cmp ebx, 0x2ee2
jne 0x46ed11
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x24]
push eax
push ecx
push str.Total_Bytes_read_so_far:_llu_n
call fcn.00423db0
push str.InternetGetRequestEx_:_second_attempt_to_recover_from_previous_error_n
call fcn.00423db0
mov ebx, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
add esp, 0x10
push esi
call ebx
mov edx, dword [ebp + 0x40]
push edx
call ebx
mov eax, dword [ebp - 0x18]
push eax
call ebx
push 0x190
push 1
call fcn.00491e51
mov ecx, dword [ebp - 0x20]
mov esi, eax
mov eax, dword [ebp - 0x24]
mov edx, eax
add esp, 8
or edx, ecx
jne 0x46ec76
push str.Range:_bytes0_
push esi
call fcn.00463e60
add esp, 8
jmp 0x46ec86
push ecx
push eax
push str.Range:_bytes_llu_
push esi
call fcn.00463e60
add esp, 0x10
push esi
push str.InternetGetRequestByBitrate:_Content_Range_Header_message:__S_n
call fcn.00423db0
mov ecx, dword [ebp + 0x3c]
mov edx, dword [ebp + 0x38]
push 0
lea eax, [ebp - 0x50]
push eax
mov eax, dword [ebp + 0x34]
push edi
push ecx
mov ecx, dword [ebp + 0x30]
push edx
mov edx, dword [ebp + 0x2c]
push eax
mov eax, dword [ebp + 0x28]
push ecx
mov ecx, dword [ebp + 0x24]
push edx
mov edx, dword [ebp + 0x20]
push eax
mov eax, dword [ebp + 0x1c]
push ecx
mov ecx, dword [ebp + 0x18]
push edx
mov edx, dword [ebp + 0x14]
push eax
mov eax, dword [ebp + 0x10]
push ecx
mov ecx, dword [ebp + 0xc]
push edx
push eax
push ecx
mov dword [edi + 0xc], 1
mov dword [edi + 0x10], esi
call fcn.00469e40
add esp, 0x48
mov ebx, eax
test esi, esi
je 0x46eced
push esi
call fcn.0048efd8
add esp, 4
mov eax, dword [edi + 4]
mov edx, dword [edi]
mov dword [ebp + 0x40], eax
mov eax, dword [edi + 8]
mov dword [ebp - 0x18], edx
mov dword [ebp + 0x44], eax
test ebx, ebx
jne 0x46ed11
lea ecx, [ebp - 0x10]
push ecx
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x46ed82
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x46ede8
inc eax
push eax
push 1
call fcn.00491e51
mov ecx, dword [ebp + 0x44]
add esp, 8
mov esi, eax
mov eax, dword [ebp - 0x10]
lea edx, [ebp - 0x14]
push edx
push eax
push esi
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x46eda7
mov eax, dword [ebp - 0x14]
add dword [ebp - 0x24], eax
adc dword [ebp - 0x20], 0
test eax, eax
je 0x46ed68
push 0
lea edx, [ebp - 0x1c]
push edx
push eax
mov eax, dword [ebp + 8]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x46edc5
mov eax, dword [ebp - 0x14]
test esi, esi
je 0x46ed78
push esi
call fcn.0048efd8
mov eax, dword [ebp - 0x14]
add esp, 4
test eax, eax
jne 0x46ebd0
jmp 0x46ede8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push ebx
push str.InternetGetRequestEx_:_Error_occured_in_WinHttpQueryDataAvailable______lu__n
call fcn.00423ad0
push ebx
call fcn.00464180
add esp, 0xc
mov dword [ebp - 0x10], 0
jmp 0x46ede8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push ebx
push str.InternetGetRequestEx_:__Error_in_WinHttpReadData______lu__n
call fcn.00423ad0
push ebx
call fcn.00464180
add esp, 0xc
jmp 0x46eddb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push ebx
push str.InternetGetRequestEx_:__Error_in_WriteFile______lu__n
call fcn.00423ad0
add esp, 8
test esi, esi
je 0x46ede8
push esi
call fcn.0048efd8
add esp, 4
mov ecx, dword [ebp - 0x20]
mov esi, dword [ebp - 0x24]
push ecx
push esi
push str.Total_bytes_read____llu__n
call fcn.00423db0
mov edx, dword [ebp + 0x30]
mov eax, dword [ebp + 0x2c]
mov ecx, dword [ebp + 0x18]
push ebx
push esi
push edx
mov edx, dword [ebp + 0x14]
push eax
push ecx
push edx
call fcn.00468750
mov eax, dword [ebp + 0x44]
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
add esp, 0x24
push eax
call esi
mov ecx, dword [ebp + 0x40]
push ecx
call esi
mov edx, dword [ebp - 0x18]
push edx
call esi
lea ecx, [ebp - 0x50]
mov dword [ebp - 4], 0xffffffff
call fcn.0046d4c0
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret