Function at 0x14002f268
Capabilities:
Get common file path
Query or enumerate registry key
Query or enumerate registry value
Set environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
push r13
push r14
push r15
sub rsp, 0x540
mov rax, qword [0x1400d1548]
xor rax, rsp
mov qword [rsp + 0x530], rax
mov rcx, qword [0x1400d2280]
xor esi, esi
lea rax, [0x140028fa0]
test rcx, rcx
jne 0x14004e542
mov qword [0x1400d2280], rax
mov r14d, 1
mov dword [rsp + 0x60], r14d
lea ebx, [r14 + 3]
mov r8d, ebx
lea rdx, [rsp + 0x60]
lea r12d, [r14 + 1]
mov ecx, r12d
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_1.dll_SetProcessMitigationPolicy]
nop dword [rax + rax]
mov dword [rsp + 0x48], r12d
mov r8d, ebx
lea rdx, [rsp + 0x48]
lea r15d, [r14 + 8]
mov ecx, r15d
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_1.dll_SetProcessMitigationPolicy]
nop dword [rax + rax]
mov dword [rsp + 0x68], r14d
mov r8d, ebx
lea rdx, [rsp + 0x68]
lea ecx, [rbx + 6]
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_1.dll_SetProcessMitigationPolicy]
nop dword [rax + rax]
mov r13d, esi
mov dword [rsp + 0x48], esi
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoInitializeEx]
nop dword [rax + rax]
test eax, eax
js 0x14004e56e
xor r9d, r9d
xor r8d, r8d
mov edx, r14d
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapSetInformation]
nop dword [rax + rax]
mov rdi, rsi
mov qword [rsp + 0x78], rsi
call fcn.14002f9e0
test al, al
je 0x14002f4e5
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], r15d
lea r8, str.SOFTWAREMicrosoftWindows_SearchGatherWindowsSystemIndexProtocols
mov rdx, 0xffffffff80000002
call fcn.140024fd4
test eax, eax
jne 0x14002f4e5
mov r15d, 0xff
mov ebx, esi
mov dword [rsp + 0x68], r15d
mov qword [rsp + 0x38], rsi
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x28], rsi
mov qword [rsp + 0x20], rsi
lea r9, [rsp + 0x68]
lea r8, [rsp + 0x120]
mov edx, ebx
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegEnumKeyExW]
nop dword [rax + rax]
test eax, eax
jne 0x14002f4d4
mov rdx, r15
lea rax, [rsp + 0x120]
cmp word [rax], si
je 0x14002f3f6
add rax, r12
sub rdx, r14
jne 0x14002f3e9
test rdx, rdx
je 0x14002f444
lea rax, [rdx + rdx]
lea rcx, [rsp + 0x31e]
sub rcx, rax
mov eax, 0x7ffffffe
lea r9, [0x1400ab404]
sub r9, rcx
test rax, rax
je 0x14002f441
movzx r8d, word [r9 + rcx]
test r8w, r8w
je 0x14002f438
mov word [rcx], r8w
add rcx, r12
sub rax, r14
sub rdx, r14
jne 0x14002f419
test rdx, rdx
je 0x14004e578
mov word [rcx], si
lea rax, [rsp + 0x70]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], r14d
lea r8, [rsp + 0x120]
mov rdx, qword [rsp + 0x58]
call fcn.140024fd4
test eax, eax
jne 0x14002f4cc
mov dword [rsp + 0x60], r15d
mov dword [rsp + 0x50], r14d
lea rax, [rsp + 0x60]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x320]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x50]
xor r8d, r8d
lea rdx, str.ProgIdHandler
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
nop dword [rax + rax]
test eax, eax
jne 0x14002f4bb
lea rcx, [rsp + 0x320]
call fcn.14002f970
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
nop dword [rax + rax]
add ebx, r14d
jmp 0x14002f39d
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
nop dword [rax + rax]
call fcn.140036050
test byte [0x1400d3b02], 8
jne 0x14004e581
test byte [0x1400d3b01], 8
jne 0x14004e5aa
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_GetCurrentThread]
nop dword [rax + rax]
mov rcx, rax
lea rdx, str.Main_Service_Thread
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_3.dll_SetThreadDescription]
nop dword [rax + rax]
call fcn.14002ffc8
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_GetCurrentProcess]
nop dword [rax + rax]
mov rcx, rax
mov edx, 0x20
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_SetPriorityClass]
nop dword [rax + rax]
xor r9d, r9d
xor r8d, r8d
lea rdx, [0x14002bd30]
lea rcx, [0x1400d23d0]
call qword [sym.imp.api_ms_win_core_synch_l1_2_0.dll_InitOnceExecuteOnce]
nop dword [rax + rax]
cmp byte [0x1400d2292], sil
jne 0x14004e5d2
mov byte [rsp + 0x69], r14b
mov ecx, 8
call fcn.140037598
mov rbx, rax
mov qword [rsp + 0x60], rax
mov r8d, r12d
mov edx, 8
mov rcx, rax
call qword [sym.imp.api_ms_win_security_base_l1_1_0.dll_InitializeAcl]
nop dword [rax + rax]
test eax, eax
je 0x14004e5dd
lea rcx, [rsp + 0xb0]
call fcn.140032224
nop
lea rcx, [rsp + 0x58]
call fcn.140030d10
nop
lea rcx, [rsp + 0x70]
call fcn.140030cdc
nop
lea rax, [rsp + 0x320]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
mov edx, 0x801c
xor ecx, ecx
call qword [sym.imp.ext_ms_win_shell32_shellfolders_l1_1_0.dll_SHGetFolderPathW]
nop dword [rax + rax]
mov r15d, eax
test eax, eax
js 0x14004e5f7
lea rdx, [rsp + 0x320]
lea rcx, str.LOCALAPPDATA
call qword [sym.imp.api_ms_win_core_processenvironment_l1_1_0.dll_SetEnvironmentVariableW]
nop dword [rax + rax]
test eax, eax
je 0x14004e66d
lea rcx, [rsp + 0xb0]
call fcn.140034728
mov byte [rsp + 0x40], sil
mov ebx, 0xc0100000
mov dword [rsp + 0x50], ebx
mov rax, qword [rsp + 0x58]
mov qword [rsp + 0x100], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x100]
lea rcx, [rsp + 0x60]
call fcn.140034a5c
mov byte [rsp + 0x40], sil
mov dword [rsp + 0x50], ebx
mov rax, qword [rsp + 0x70]
mov qword [rsp + 0x100], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x100]
lea rcx, [rsp + 0x60]
call fcn.140034a5c
mov rbx, qword [rsp + 0x60]
mov r8, rbx
lea rcx, [rsp + 0xb0]
call fcn.1400322dc
mov dword [rsp + 0x80], SafeArrayPutElement
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x88], rax
mov dword [rsp + 0x90], esi
mov dword [rsp + 0x60], esi
mov r15d, esi
lea r12, str.onecoreuap_base_appmodel_search_searchindexerexemain.cxx
cmp r15d, 0xf
jae 0x14002f754
lea r8, str.SearchServiceMUT
mov edx, r14d
lea rcx, [rsp + 0x80]
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_CreateMutexW]
nop dword [rax + rax]
mov rdx, rax
lea rcx, [0x1400d2730]
call fcn.14000fd7c
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
mov dword [rsp + 0x50], eax
mov rcx, qword [0x1400d2730]
dec rcx
cmp rcx, 0xfffffffffffffffd
ja 0x14004e6ec
test eax, eax
jne 0x14004e6ec
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x14002f764
call fcn.14003729c
nop
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14002f774
call fcn.14003729c
nop
lea rcx, [rsp + 0xb0]
call fcn.140032030
nop
mov rcx, rbx
call fcn.14003729c
nop
lea rcx, [rsp + 0x60]
call fcn.140032de4
mov rdi, rax
mov qword [rsp + 0x78], rax
test rax, rax
je 0x14004e7f0
cmp dword [rsp + 0x60], 2
jne 0x14002f7f6
mov ebx, r14d
cmp ebx, dword [rsp + 0x60]
jge 0x14002f7f6
movsxd rax, ebx
mov rcx, qword [rdi + rax*8]
movzx eax, word [rcx]
sub ax, 0x2d
mov edx, 0xfffd
test dx, ax
jne 0x14004e831
add rcx, 2
lea rdx, str.Embedding
call qword [sym.imp.api_ms_win_crt_private_l1_1_0.dll__o__wcsicmp]
nop dword [rax + rax]
test eax, eax
jne 0x14004e872
add ebx, r14d
jmp 0x14002f7b0
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoInitializeEx]
nop dword [rax + rax]
mov ebx, eax
mov dword [rsp + 0x50], eax
mov r15d, eax
mov rcx, qword [rsp + 0x558]
test eax, eax
js 0x14004e8b3
mov qword [rsp + 0x58], rsi
lea rax, [rsp + 0x58]
mov qword [rsp + 0x20], rax
lea r9, [0x1400ab870]
mov r8d, r14d
xor edx, edx
lea rcx, [0x1400ac0e8]
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoCreateInstance]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x558]
test eax, eax
js 0x14004e907
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14002f896
mov rax, qword [rcx]
movabs r10, 0x8c45af813654d170
mov r8, r14
mov edx, 5
mov rax, qword [rax + 0x18]
call qword [case.0x14001f589.0]
mov rcx, qword [rsp + 0x558]
test eax, eax
js 0x14004e921
call fcn.1400323e8
mov r15d, eax
mov rcx, qword [rsp + 0x558]
test eax, eax
js 0x14004e93b
lea rcx, [rsp + 0x58]
call fcn.140003bbc
test r15d, r15d
js 0x14004e8c7
mov bl, sil
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x8c], xmm0
mov dword [rsp + 0x9c], esi
mov r15d, 3
mov dword [rsp + 0x88], r15d
lea rax, str.AllowWindowsIndexer
mov qword [rsp + 0x80], rax
movups xmm0, xmmword [rsp + 0x80]
movaps xmmword [rsp + 0x100], xmm0
movups xmm1, xmmword [rsp + 0x90]
movaps xmmword [rsp + 0x110], xmm1
xor edx, edx
lea rcx, [rsp + 0x100]
call fcn.140027830
test eax, eax
je 0x14004e8f9
mov dl, bl
call fcn.1400357a8
mov dword [rsp + 0x50], r15d
lea rcx, [rsp + 0x50]
call fcn.14005ced8
nop
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoUninitialize]
nop dword [rax + rax]
nop
jmp 0x14004e965
cmp rcx, rax
je 0x14002f2b3
xor edx, edx
mov r8d, 0x98
lea rcx, [rsp + 0x120]
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
lea rcx, [rsp + 0x120]
call fcn.1400529a8
int3
mov eax, 0x800401f0
jmp 0x14004ea2a
add rcx, 0xfffffffffffffffe
jmp 0x14002f441
lea rax, [rsp + 0x100]
mov qword [rsp + 0x20], rax
mov r9d, r14d
lea rdx, [0x1400b12f8]
lea rcx, [0x1400d0680]
call fcn.14005cb7c
nop
jmp 0x14002f4f7
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_GetCurrentProcessId]
nop dword [rax + rax]
mov r8d, eax
lea rdx, [0x1400b1938]
lea rcx, [0x1400d0680]
call fcn.14005cbdc
nop
jmp 0x14002f504
call fcn.140060b14
nop
jmp 0x14002f578
mov rcx, qword [rsp + 0x558]
lea r8, [0x1400b1980]
mov edx, 0x169
call fcn.140063d80
nop
mov rcx, qword [rsp + 0x558]
mov r9d, r15d
lea r8, [0x1400acdc0]
mov edx, 0xfc
call fcn.14005acc8
mov r9d, r15d
lea r8, str._SrchCommon__Couldnt_get_LOCALAPPDATA_value_from_shell._LastErr0x_x_n
mov edx, 0xfd
lea rcx, str.onecoreuap_base_appmodel_search_searchindexerexemain.cxx
call fcn.1400599a4
mov r13d, r14d
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x14004e641
call fcn.14003729c
nop
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14004e651
call fcn.14003729c
nop
lea rcx, [rsp + 0xb0]
call fcn.140032030
nop
mov rcx, rbx
call fcn.14003729c
nop
jmp 0x14004e965
mov rcx, qword [rsp + 0x558]
lea r8, [0x1400acdc0]
mov edx, 0x106
call fcn.140060f2c
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
mov r9d, eax
lea r8, str._SrchCommon__Couldnt_set_LOCALAPPDATA_envvar._LastErr_d_n
mov edx, 0x107
lea rcx, str.onecoreuap_base_appmodel_search_searchindexerexemain.cxx
call fcn.1400599a4
mov r13d, r14d
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x14004e6c0
call fcn.14003729c
nop
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14004e6d0
call fcn.14003729c
nop
lea rcx, [rsp + 0xb0]
call fcn.140032030
nop
mov rcx, rbx
call fcn.14003729c
nop
jmp 0x14004e965
xor edx, edx
lea rcx, [0x1400d2730]
call fcn.14000fd7c
mov r9d, dword [rsp + 0x50]
mov eax, Ordinal_184
mov rcx, r12
cmp r9d, eax
je 0x14004e75a
lea r8, str._SrchCommon__Failed_to_obtain_an_app_mutex._LastErr_d_n
lea edx, [rax + 0x79]
call fcn.1400599a4
mov r13d, r14d
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x14004e72e
call fcn.14003729c
nop
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14004e73e
call fcn.14003729c
nop
lea rcx, [rsp + 0xb0]
call fcn.140032030
nop
mov rcx, rbx
call fcn.14003729c
nop
jmp 0x14004e965
mov r9d, eax
lea r8, str._SrchCommon__Failed_to_obtain_an_app_mutex._Will_retry._LastErr_d_n
mov edx, VarBstrCmp
call fcn.1400318ac
cmp r15d, 0xe
jne 0x14004e7c8
lea r8, str._SrchCommon__Another_copy_of_mssearch_is_running__This_will_terminate._n
mov edx, reloc.OLEAUT32.dll_VarBstrCmp
mov rcx, r12
call fcn.1400599a4
lea r13d, [r15 - 0xc]
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x14004e79c
call fcn.14003729c
nop
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x14004e7ac
call fcn.14003729c
nop
lea rcx, [rsp + 0xb0]
call fcn.140032030
nop
mov rcx, rbx
call fcn.14003729c
nop
jmp 0x14004e965
lea rcx, [rsp + 0x60]
call fcn.14005d234
mov ecx, 0x7d0
call qword [sym.imp.api_ms_win_core_synch_l1_2_0.dll_Sleep]
nop dword [rax + rax]
inc r15d
mov dword [rsp + 0x60], r15d
jmp 0x14002f6f5
lea r8, str._SrchCommon__Error_parsing_cmd_line__Exiting..._n
mov edx, 0x15b
mov rcx, r12
call fcn.1400599a4
mov r13d, r14d
mov dword [rsp + 0x48], r14d
mov rcx, qword [rsp + 0x558]
mov r9d, 0x80070057
lea r8, [0x1400acdc0]
mov edx, 0x15d
call fcn.14005acc8
nop
jmp 0x14004e965
lea r8, str._SrchCommon__Cant_be_started_without_parameters_n
mov edx, 0x167
mov rcx, r12
call fcn.1400599a4
mov r13d, r14d
mov dword [rsp + 0x48], r14d
mov rcx, qword [rsp + 0x558]
mov r9d, 0x80070057
lea r8, [0x1400acdc0]
mov edx, 0x169
call fcn.14005acc8
nop
jmp 0x14004e965
lea r8, str._SrchCommon__Cant_be_started_without_parameters_n
mov edx, 0x173
mov rcx, r12
call fcn.1400599a4
mov r13d, r14d
mov dword [rsp + 0x48], r14d
mov rcx, qword [rsp + 0x558]
mov r9d, 0x80070057
lea r8, [0x1400acdc0]
mov edx, 0x175
call fcn.14005acc8
nop
jmp 0x14004e965
mov r9d, ebx
lea r8, [0x1400acdc0]
mov edx, 0x17d
call fcn.14002889c
mov r9d, r15d
lea r8, str._SrchCommon__Failed_to_initialize__hr___08X_n
mov edx, 0x191
mov rcx, r12
call fcn.1400599a4
mov r13d, r15d
mov dword [rsp + 0x48], r15d
test ebx, ebx
js 0x14004e8f7
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoUninitialize]
nop dword [rax + rax]
nop
jmp 0x14004e965
mov bl, r14b
call fcn.140060a7c
nop
jmp 0x14002f92b
mov r9d, eax
lea r8, [0x1400acdc0]
mov edx, 0x185
call fcn.14002889c
nop
jmp 0x14002f85d
mov r9d, eax
lea r8, [0x1400acdc0]
mov edx, 0x188
call fcn.14002889c
nop
jmp 0x14002f896
mov r9d, r15d
lea r8, [0x1400acdc0]
mov edx, 0x18c
call fcn.14002889c
nop
jmp 0x14002f8ae
call qword [sym.imp.MSSRCH.DLL_public:_static_void___cdecl_CSearchServiceObj::Cleanup_void_]
nop dword [rax + rax]
call fcn.14002f9e0
test al, al
je 0x14004e994
lea rdx, [0x14005cd70]
call fcn.14002fa04
mov r8b, r14b
mov edx, dword [0x1400d3c40]
call fcn.1400609a4
test byte [0x1400d3b01], 8
je 0x14004e9bf
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_GetCurrentProcessId]
nop dword [rax + rax]
mov r8d, eax
lea rdx, [0x1400b1928]
lea rcx, [0x1400d0680]
call fcn.14005cbdc
test byte [0x1400d3b02], 8
je 0x14004e9eb
lea rax, [rsp + 0x100]
mov qword [rsp + 0x20], rax
mov r9d, r14d
lea rdx, [0x1400b12d8]
lea rcx, [0x1400d0680]
call fcn.14005cb7c
call fcn.140065074
call qword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoUninitialize]
nop dword [rax + rax]
nop
mov ecx, dword [0x1400d1650]
cmp ecx, 0xffffffff
je 0x14004ea15
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_TlsFree]
nop dword [rax + rax]
nop
test rdi, rdi
je 0x14004ea27
mov edx, 8
mov rcx, rdi
call fcn.140037228
mov eax, r13d
mov rcx, qword [rsp + 0x530]
xor rcx, rsp
call fcn.140036b80
lea r11, [rsp + 0x540]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r13
ret