Function at 0x1400020c0
Capabilities:
Create process on windows
Download url
Query environment variable
Receive data
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
lea rbp, [rsp - 0x480]
sub rsp, 0x580
mov rax, qword [0x140010040]
xor rax, rsp
mov qword [rbp + 0x470], rax
xor esi, esi
call fcn.140001630
test al, al
je 0x1400026c1
lea rdx, str.New_update_detected._Updating...
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.140006c90
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rcx, [rsp + 0x30]
call fcn.140001330
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x30], rax
movabs r8, 0x7fffffffc46535ff
cmp rax, r8
je 0x14000215e
mov ecx, 1
mov edx, 0xff
cmovl ecx, edx
test cl, cl
jns 0x14000215e
add rax, 0x3b9aca00
jmp 0x140002168
movabs rax, 0x7fffffffffffffff
mov qword [rsp + 0x30], rax
lea rcx, [rsp + 0x30]
call fcn.140007d40
lea rdx, [0x140010ae8]
lea rcx, [rbp - 0x10]
call fcn.140006690
nop
lea rdx, [0x140010aa8]
lea rcx, [rbp + 0x10]
call fcn.140006690
nop
lea rcx, [rbp - 0x10]
cmp qword [rbp + 8], 7
cmova rcx, qword [rbp - 0x10]
mov r8d, 0x104
lea rdx, [rbp + 0x50]
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
lea rax, [rbp + 0x50]
mov rdx, 0xffffffffffffffff
inc rdx
cmp word [rax + rdx*2], 0
jne 0x1400021c2
mov rax, qword [rbp + 8]
cmp rdx, rax
ja 0x1400021ff
lea rdi, [rbp - 0x10]
cmp rax, 7
cmova rdi, qword [rbp - 0x10]
mov qword [rbp], rdx
lea rbx, [rdx + rdx]
mov r8, rbx
lea rdx, [rbp + 0x50]
mov rcx, rdi
call sub.VCRUNTIME140.dll_memmove
mov word [rbx + rdi], si
jmp 0x14000220c
lea r9, [rbp + 0x50]
lea rcx, [rbp - 0x10]
call fcn.140007670
lea r8, [rbp - 0x10]
cmp qword [rbp + 8], 7
cmova r8, qword [rbp - 0x10]
lea rdx, [rbp + 0x10]
cmp qword [rbp + 0x28], 7
cmova rdx, qword [rbp + 0x10]
mov qword [rsp + 0x20], rsi
xor r9d, r9d
xor ecx, ecx
call qword [sym.imp.urlmon.dll_URLDownloadToFileW]
mov ebx, eax
test eax, eax
jns 0x140002294
lea rdx, str.Failed_to_download_file._HRESULT:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140006c90
mov edx, ebx
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___long_int____ptr64]
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea rdx, str.Failed_to_download_the_new_version.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.140006c90
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
jmp 0x14000262a
mov r8d, 0x104
lea rdx, [rbp + 0x260]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x1400022ff
lea rdx, str.Failed_to_get_executable_path._Error_code:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140006c90
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___unsigned_long_int____ptr64]
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
xorps xmm0, xmm0
movups xmmword [rbp - 0x30], xmm0
mov qword [rbp - 0x20], rsi
mov qword [rbp - 0x18], rsi
xor r8d, r8d
lea rdx, [0x14000a944]
jmp 0x140002332
xorps xmm0, xmm0
movups xmmword [rbp - 0x30], xmm0
mov qword [rbp - 0x20], rsi
mov qword [rbp - 0x18], rsi
lea rax, [rbp + 0x260]
mov r8, 0xffffffffffffffff
nop dword [rax]
inc r8
cmp word [rax + r8*2], 0
jne 0x140002320
lea rdx, [rbp + 0x260]
lea rcx, [rbp - 0x30]
call fcn.140001430
nop
lea rdx, [rbp - 0x10]
lea rcx, [rbp - 0x30]
call fcn.140001a40
test al, al
je 0x1400025c2
lea rdx, [rbp - 0x30]
mov r10, qword [rbp - 0x30]
mov r11, qword [rbp - 0x18]
cmp r11, 7
cmova rdx, r10
mov r9, qword [rbp - 0x20]
test r9, r9
je 0x1400023a8
lea rcx, [r9 - 1]
mov rax, 0xffffffffffffffff
cmp rcx, rax
cmovb rax, rcx
lea r8, [rdx + rax*2]
cmp word [r8], 0x5c
je 0x1400023a0
nop dword [rax + rax]
cmp r8, rdx
je 0x1400023a8
sub r8, 2
cmp word [r8], 0x5c
jne 0x140002390
sub r8, rdx
sar r8, 1
jmp 0x1400023af
mov r8, 0xffffffffffffffff
xorps xmm0, xmm0
movups xmmword [rsp + 0x38], xmm0
xorps xmm1, xmm1
movdqu xmmword [rsp + 0x48], xmm1
inc r8
cmp r9, r8
cmovb r8, r9
lea rdx, [rbp - 0x30]
cmp r11, 7
cmova rdx, r10
lea rcx, [rsp + 0x38]
call fcn.140001430
nop
mov rdi, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x50]
mov rax, rcx
sub rax, rdi
cmp rax, 0xc
jb 0x140002431
lea rax, [rdi + 0xc]
mov qword [rsp + 0x48], rax
lea rbx, [rsp + 0x38]
cmp rcx, 7
cmova rbx, qword [rsp + 0x38]
lea rcx, [rbx + rdi*2]
mov r8d, 0x18
lea rdx, str.todelete.exe
call sub.VCRUNTIME140.dll_memmove
mov word [rbx + rdi*2 + 0x18], si
lea rax, [rsp + 0x38]
jmp 0x140002450
mov qword [rsp + 0x20], 0xc
lea r9, str.todelete.exe
mov edx, 0xc
lea rcx, [rsp + 0x38]
call fcn.1400077d0
xorps xmm0, xmm0
movups xmmword [rbp + 0x30], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp + 0x40], xmm1
movups xmm0, xmmword [rax]
movups xmmword [rbp + 0x30], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp + 0x40], xmm1
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], 7
mov word [rax], si
mov rdx, qword [rsp + 0x50]
cmp rdx, 7
jbe 0x1400024c2
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x38]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400024bd
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400024bd
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400089e4
movdqa xmm0, xmmword [0x14000b9b0]
movdqu xmmword [rsp + 0x48], xmm0
mov word [rsp + 0x38], si
lea rcx, [rbp + 0x30]
call fcn.140001cf0
xorps xmm0, xmm0
movups xmmword [rsp + 0x60], xmm0
movups xmmword [rsp + 0x70], xmm0
movups xmmword [rbp - 0x80], xmm0
movups xmmword [rbp - 0x70], xmm0
movups xmmword [rbp - 0x60], xmm0
movups xmmword [rbp - 0x50], xmm0
movups xmmword [rbp - 0x40], xmm0
mov dword [rsp + 0x60], 0x70
lea rax, str.open
mov qword [rsp + 0x70], rax
lea rax, [rbp - 0x30]
cmp qword [rbp - 0x18], 7
cmova rax, qword [rbp - 0x30]
mov qword [rsp + 0x78], rax
mov dword [rbp - 0x70], 1
lea rcx, [rsp + 0x60]
call qword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x140002545
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_ExitProcess]
lea rdx, str.Failed_to_start_new_executable._Error_code:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140006c90
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___unsigned_long_int____ptr64]
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
nop
mov rdx, qword [rbp + 0x48]
cmp rdx, 7
jbe 0x1400025e6
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400025bb
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400025bb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400089e4
jmp 0x1400025e6
lea rdx, str.Failed_to_replace_old_executable_with_new_one.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.140006c90
lea rdx, [0x140006e70]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
nop
mov rdx, qword [rbp - 0x18]
cmp rdx, 7
jbe 0x14000262a
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002624
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002624
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400089e4
nop
mov rdx, qword [rbp + 0x28]
cmp rdx, 7
jbe 0x14000266d
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x10]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002668
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002668
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400089e4
movdqa xmm0, xmmword [0x14000b9b0]
movdqu xmmword [rbp + 0x20], xmm0
mov word [rbp + 0x10], si
mov rdx, qword [rbp + 8]
cmp rdx, 7
jbe 0x1400026c1
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x10]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400026bc
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400026bc
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400089e4
mov rcx, qword [rbp + 0x470]
xor rcx, rsp
call fcn.140008740
lea r11, [rsp + 0x580]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret