Function at 0x140001703
Capabilities:
Create http request
Read data from internet
Receive data

Disassembly:
push rbp
push rbx
mov eax, 0x1228
call fcn.14000f900
sub rsp, rax
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x11c0], rcx
mov qword [rbp + 0x11c8], rdx
lea rax, str._LOG__Attempting_to_download:
mov rdx, rax
mov rax, qword [0x1400f4c50]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rcx, rax
mov rax, qword [rbp + 0x11c0]
mov rdx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____char__std::char_traits_char___std.allocator_char____std::basic_ostream_char__std::char_traits_char_____std::__cxx11::basic_string_char__std::char_traits_char___std::allocator_char
mov rcx, rax
mov rax, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rdx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
mov dword [rsp + 0x20], 0
mov r9d, 0
mov r8d, 0
mov edx, 0
lea rax, str.Downloader
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetOpenA]
call rax
mov qword [rbp + 0x1198], rax
cmp qword [rbp + 0x1198], 0
jne 0x1400017ed
lea rax, str._ERROR__InternetOpenA_failed._Error_code:
mov rdx, rax
mov rax, qword [0x1400f4c30]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rbx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
mov rcx, rbx
call method.std::ostream.operator___unsigned_long_
mov rcx, rax
mov rax, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rdx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
mov ebx, 0
jmp 0x140001a21
mov rax, qword [rbp + 0x11c0]
mov rcx, rax
call method.std::__cxx11::basic_string_char__std::char_traits_char___std::allocator_char___.c_str___const
mov rdx, rax
mov rax, qword [rbp + 0x1198]
mov qword [rsp + 0x28], 0
mov dword [rsp + 0x20], 0x80000000
mov r9d, 0
mov r8d, 0
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetOpenUrlA]
call rax
mov qword [rbp + 0x1190], rax
cmp qword [rbp + 0x1190], 0
jne 0x14000189e
lea rax, str._ERROR__InternetOpenUrlA_failed._Error_code:
mov rdx, rax
mov rax, qword [0x1400f4c30]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rbx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
mov rcx, rbx
call method.std::ostream.operator___unsigned_long_
mov rcx, rax
mov rax, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rdx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
mov rax, qword [rbp + 0x1198]
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetCloseHandle]
call rax
mov ebx, 0
jmp 0x140001a21
mov rdx, qword [rbp + 0x11c8]
lea rax, [rbp + 0xfc0]
mov r8d, 4
mov rcx, rax
call fcn.1400c0870
lea rax, [rbp + 0xfc0]
mov rcx, rax
call method.std::basic_ofstream_char__std::char_traits_char___.is_open__
xor eax, 1
test al, al
je 0x14000195c
lea rax, str._ERROR__Unable_to_open_output_file:
mov rdx, rax
mov rax, qword [0x1400f4c30]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rcx, rax
mov rax, qword [rbp + 0x11c8]
mov rdx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____char__std::char_traits_char___std.allocator_char____std::basic_ostream_char__std::char_traits_char_____std::__cxx11::basic_string_char__std::char_traits_char___std::allocator_char
mov rcx, rax
mov rax, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rdx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
mov rax, qword [rbp + 0x1190]
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetCloseHandle]
call rax
mov rax, qword [rbp + 0x1198]
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetCloseHandle]
call rax
mov ebx, 0
jmp 0x140001a12
mov eax, dword [rbp - 0x44]
mov ecx, eax
lea rdx, [rbp - 0x40]
lea rax, [rbp + 0xfc0]
mov r8, rcx
mov rcx, rax
call method.std::ostream.write_char_const__long_long_
lea rcx, [rbp - 0x44]
lea rdx, [rbp - 0x40]
mov rax, qword [rbp + 0x1190]
mov r9, rcx
mov r8d, 0x1000
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetReadFile]
call rax
test eax, eax
je 0x140001992
mov eax, dword [rbp - 0x44]
test eax, eax
je 0x140001992
mov eax, 1
jmp 0x140001997
mov eax, 0
test al, al
jne 0x140001941
lea rax, [rbp + 0xfc0]
mov rcx, rax
call method.std::basic_ofstream_char__std::char_traits_char___.close__
mov rax, qword [rbp + 0x1190]
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetCloseHandle]
call rax
mov rax, qword [rbp + 0x1198]
mov rcx, rax
mov rax, qword [sym.imp.WININET.dll_InternetCloseHandle]
call rax
lea rax, str._LOG__Download_completed:
mov rdx, rax
mov rax, qword [0x1400f4c50]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rcx, rax
mov rax, qword [rbp + 0x11c8]
mov rdx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____char__std::char_traits_char___std.allocator_char____std::basic_ostream_char__std::char_traits_char_____std::__cxx11::basic_string_char__std::char_traits_char___std::allocator_char
mov rcx, rax
mov rax, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rdx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
mov ebx, 1
lea rax, [rbp + 0xfc0]
mov rcx, rax
call method.std::basic_ofstream_char__std::char_traits_char___.basic_ofstream__
mov eax, ebx
jmp 0x140001a42
add rsp, 0x1228
pop rbx
pop rbp
ret