Function at 0x140003f60
Capabilities:
Create http request
Download and write a file
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
mov eax, 0x1060
call fcn.14000c940
sub rsp, rax
mov rax, qword [0x14003b040]
xor rax, rsp
mov qword [rsp + 0x1050], rax
mov rbx, rdx
mov rdi, rcx
xor r14d, r14d
mov edx, 1
xor ecx, ecx
mov dword [rsp + 0x20], r14d
xor r9d, r9d
xor r8d, r8d
call qword [sym.imp.WININET.dll_InternetOpenW]
cmp qword [rdi + 0x18], 7
mov rdx, rdi
mov rbp, rax
jbe 0x140003fbe
mov rdx, qword [rdi]
mov qword [rsp + 0x28], r14
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x20], 0x80000000
mov rcx, rbp
call qword [sym.imp.WININET.dll_InternetOpenUrlW]
mov rsi, rax
test rax, rax
jne 0x140004043
lea rdx, str.Failed_to_connect_to
lea rcx, [0x14003c9f0]
call fcn.140005d00
cmp qword [rdi + 0x18], 7
mov r8, qword [rdi + 0x10]
jbe 0x140004003
mov rdi, qword [rdi]
mov rdx, rdi
mov rcx, rax
call fcn.1400074d0
mov dl, 0xa
mov rbx, rax
mov rcx, qword [rax]
movsxd rcx, dword [rcx + 4]
add rcx, rax
call fcn.140006fe0
movzx edx, ax
mov rcx, rbx
call fcn.140006e30
mov rcx, rbx
call fcn.140006cd0
mov rcx, rbp
call qword [sym.imp.WININET.dll_InternetCloseHandle]
jmp 0x1400041b3
cmp qword [rbx + 0x18], 7
mov rcx, rbx
jbe 0x140004050
mov rcx, qword [rbx]
mov qword [rsp + 0x30], r14
xor r9d, r9d
mov dword [rsp + 0x28], 0x80
xor r8d, r8d
mov edx, 0x40000000
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rdi, rax
cmp rax, 0xffffffffffffffff
jne 0x1400040e9
lea rdx, str.Failed_to_create_file
lea rcx, [0x14003c9f0]
call fcn.140005d00
cmp qword [rbx + 0x18], 7
mov r8, qword [rbx + 0x10]
jbe 0x1400040a0
mov rbx, qword [rbx]
mov rdx, rbx
mov rcx, rax
call fcn.1400074d0
mov dl, 0xa
mov rbx, rax
mov rcx, qword [rax]
movsxd rcx, dword [rcx + 4]
add rcx, rax
call fcn.140006fe0
movzx edx, ax
mov rcx, rbx
call fcn.140006e30
mov rcx, rbx
call fcn.140006cd0
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rbp
call qword [sym.imp.WININET.dll_InternetCloseHandle]
jmp 0x1400041b3
lea r9, [rsp + 0x40]
mov r8d, 0x1000
lea rdx, [rsp + 0x50]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x140004145
mov r8d, dword [rsp + 0x40]
test r8d, r8d
je 0x140004145
lea r9, [rsp + 0x44]
mov qword [rsp + 0x20], r14
lea rdx, [rsp + 0x50]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
lea r9, [rsp + 0x40]
mov r8d, 0x1000
lea rdx, [rsp + 0x50]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x140004106
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rbp
call qword [sym.imp.WININET.dll_InternetCloseHandle]
lea rdx, str.File_downloaded:
lea rcx, [0x14003c8c0]
call fcn.140005d00
cmp qword [rbx + 0x18], 7
mov r8, qword [rbx + 0x10]
jbe 0x140004181
mov rbx, qword [rbx]
mov rdx, rbx
mov rcx, rax
call fcn.1400074d0
mov dl, 0xa
mov rbx, rax
mov rcx, qword [rax]
movsxd rcx, dword [rcx + 4]
add rcx, rax
call fcn.140006fe0
movzx edx, ax
mov rcx, rbx
call fcn.140006e30
mov rcx, rbx
call fcn.140006cd0
mov rcx, qword [rsp + 0x1050]
xor rcx, rsp
call fcn.14000c2f0
lea r11, [rsp + 0x1060]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret