Function at 0x1400d1d40
Capabilities:
Get common file path
Link many functions at runtime

Disassembly:
mov r11, rsp
push rbp
push rbx
lea rbp, [r11 - 0x588]
sub rsp, 0x678
mov rax, qword [0x1403ceac0]
xor rax, rsp
mov qword [rbp + 0x550], rax
mov eax, dword [rcx + 0x30]
mov rbx, rcx
test eax, eax
jne 0x1400d24b6
mov qword [r11 + 0x10], rsi
mov qword [r11 + 0x18], rdi
xor edi, edi
mov qword [r11 + 0x20], r12
mov qword [r11 - 0x18], r13
lea r13, [rcx + 8]
mov rcx, qword [rcx + 8]
mov qword [r11 - 0x20], r14
mov qword [r11 - 0x28], r15
test rcx, rcx
jne 0x1400d1dc1
cmp qword [rbx + 0x10], rdi
lea rsi, [rbx + 0x10]
jne 0x1400d1dc1
cmp qword [rbx + 0x18], rdi
lea r15, [rbx + 0x18]
jne 0x1400d1dc1
cmp qword [rbx + 0x20], rdi
lea r14, [rbx + 0x20]
jne 0x1400d1dc1
cmp qword [rbx + 0x28], rdi
lea r12, [rbx + 0x28]
je 0x1400d1e3f
test r13, r13
je 0x1400d1dd5
test rcx, rcx
je 0x1400d1dd5
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov qword [r13], rdi
lea rsi, [rbx + 0x10]
test rsi, rsi
je 0x1400d1def
mov rcx, qword [rsi]
test rcx, rcx
je 0x1400d1def
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov qword [rsi], rdi
lea r15, [rbx + 0x18]
test r15, r15
je 0x1400d1e09
mov rcx, qword [r15]
test rcx, rcx
je 0x1400d1e09
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov qword [r15], rdi
lea r14, [rbx + 0x20]
test r14, r14
je 0x1400d1e23
mov rcx, qword [r14]
test rcx, rcx
je 0x1400d1e23
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov qword [r14], rdi
lea r12, [rbx + 0x28]
test r12, r12
je 0x1400d1e3f
mov rcx, qword [r12]
test rcx, rcx
je 0x1400d1e3f
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov qword [r12], rdi
mov edi, 0x104
test r15, r15
je 0x1400d1eda
xor eax, eax
lea rcx, [rsp + 0x20]
mov edx, edi
mov word [rsp + 0x20], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp qword [r15], 0
jne 0x1400d1eda
lea r8, [rsp + 0x20]
mov edx, edi
lea rax, [rbp + 0x130]
sub r8, rax
lea rcx, [rbp + 0x130]
nop
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400d1ea3
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400d1ea3
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400d1e80
lea rax, [rcx - 2]
test rdx, rdx
lea r8, str.kernel32.dll
mov edx, 0x209
cmovne rax, rcx
xor ecx, ecx
mov word [rax], cx
lea rcx, [rbp + 0x130]
call fcn.14003b8b0
lea rcx, [rbp + 0x130]
call fcn.1400e6e50
mov qword [r15], rax
test r13, r13
je 0x1400d1f7b
xor eax, eax
lea rcx, [rsp + 0x20]
mov edx, edi
mov word [rsp + 0x20], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp qword [r13], 0
jne 0x1400d1f7b
lea r8, [rsp + 0x20]
mov rdx, rdi
lea rax, [rbp + 0x130]
sub r8, rax
lea rcx, [rbp + 0x130]
nop word [rax + rax]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400d1f43
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400d1f43
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400d1f20
lea rax, [rcx - 2]
test rdx, rdx
lea r8, str._advapi32.dll
mov edx, 0x209
cmovne rax, rcx
xor ecx, ecx
mov word [rax], cx
lea rcx, [rbp + 0x130]
call fcn.14003b8b0
lea rcx, [rbp + 0x130]
call fcn.1400e6e50
mov qword [r13], rax
test rsi, rsi
je 0x1400d201a
xor eax, eax
lea rcx, [rsp + 0x20]
mov edx, edi
mov word [rsp + 0x20], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp qword [rsi], 0
jne 0x1400d201a
lea r8, [rsp + 0x20]
mov rdx, rdi
lea rax, [rbp + 0x130]
sub r8, rax
lea rcx, [rbp + 0x130]
nop word [rax + rax]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400d1fe3
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400d1fe3
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400d1fc0
lea rax, [rcx - 2]
test rdx, rdx
lea r8, str.wtsapi32.dll
mov edx, 0x209
cmovne rax, rcx
xor ecx, ecx
mov word [rax], cx
lea rcx, [rbp + 0x130]
call fcn.14003b8b0
lea rcx, [rbp + 0x130]
call fcn.1400e6e50
mov qword [rsi], rax
test r14, r14
je 0x1400d20ba
xor eax, eax
lea rcx, [rsp + 0x20]
mov edx, edi
mov word [rsp + 0x20], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp qword [r14], 0
jne 0x1400d20ba
lea r8, [rsp + 0x20]
mov rdx, rdi
lea rax, [rbp + 0x130]
sub r8, rax
lea rcx, [rbp + 0x130]
nop word [rax + rax]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400d2083
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400d2083
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400d2060
lea rax, [rcx - 2]
test rdx, rdx
lea r8, str.user32.dll
mov edx, 0x209
cmovne rax, rcx
xor ecx, ecx
mov word [rax], cx
lea rcx, [rbp + 0x130]
call fcn.14003b8b0
lea rcx, [rbp + 0x130]
call fcn.1400e6e50
mov qword [r14], rax
test r12, r12
je 0x1400d214f
xor eax, eax
lea rcx, [rsp + 0x20]
mov edx, edi
mov word [rsp + 0x20], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp qword [r12], 0
jne 0x1400d214f
lea r8, [rsp + 0x20]
lea rax, [rbp + 0x130]
sub r8, rax
lea rcx, [rbp + 0x130]
lea rax, [rdi + 0x7ffffefa]
test rax, rax
je 0x1400d2117
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400d2117
mov word [rcx], ax
add rcx, 2
sub rdi, 1
jne 0x1400d20f4
lea rax, [rcx - 2]
test rdi, rdi
lea r8, str.psapi.dll
mov edx, 0x209
cmovne rax, rcx
xor ecx, ecx
mov word [rax], cx
lea rcx, [rbp + 0x130]
call fcn.14003b8b0
lea rcx, [rbp + 0x130]
call fcn.1400e6e50
mov qword [r12], rax
mov rcx, qword [r15]
mov rdi, qword [rsp + 0x6a0]
test rcx, rcx
je 0x1400d21a1
lea rdx, str.RegisterServiceProcess
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r15]
lea rdx, [0x140375930]
mov qword [rbx + 0xe8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r15]
lea rdx, str.WTSGetActiveConsoleSessionId
mov qword [rbx + 0xe0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0xc8], rax
mov rcx, qword [r13]
mov r15, qword [rsp + 0x660]
test rcx, rcx
je 0x1400d2317
lea rdx, [0x1403759c8]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x1403759a8]
mov qword [rbx + 0x38], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375990]
mov qword [rbx + 0x40], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375a40]
mov qword [rbx + 0x48], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375a28]
mov qword [rbx + 0x50], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.CreateServiceW
mov qword [rbx + 0x58], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375a08]
mov qword [rbx + 0x60], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.ControlService
mov qword [rbx + 0x68], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.DeleteService
mov qword [rbx + 0x70], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.ChangeServiceConfigW
mov qword [rbx + 0x78], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.CreateProcessAsUserW
mov qword [rbx + 0x80], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375ae8]
mov qword [rbx + 0x88], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.LookupPrivilegeValueW
mov qword [rbx + 0x90], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.AdjustTokenPrivileges
mov qword [rbx + 0x98], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, str.QueryServiceStatus
mov qword [rbx + 0xa0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r13]
lea rdx, [0x140375b48]
mov qword [rbx + 0x138], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x140], rax
mov rcx, qword [r14]
mov r13, qword [rsp + 0x670]
test rcx, rcx
je 0x1400d23b2
lea rdx, str.OpenDesktopW
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r14]
lea rdx, str.GetUserObjectInformationW
mov qword [rbx + 0xf0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r14]
lea rdx, str.GetProcessWindowStation
mov qword [rbx + 0xf8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r14]
lea rdx, str.SetProcessWindowStation
mov qword [rbx + 0x100], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r14]
lea rdx, str.CloseWindowStation
mov qword [rbx + 0x108], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r14]
lea rdx, str.OpenWindowStationW
mov qword [rbx + 0x110], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x118], rax
mov rcx, qword [r12]
mov r14, qword [rsp + 0x668]
test rcx, rcx
je 0x1400d2407
lea rdx, str.EnumProcesses
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r12]
lea rdx, [0x140375c00]
mov qword [rbx + 0x120], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [r12]
lea rdx, str.GetModuleBaseNameW
mov qword [rbx + 0x128], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0x130], rax
mov rcx, qword [rsi]
mov r12, qword [rsp + 0x6a8]
test rcx, rcx
je 0x1400d24a2
lea rdx, str.WTSQueryUserToken
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rsi]
lea rdx, str.WTSQuerySessionInformation
mov qword [rbx + 0xa8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rsi]
lea rdx, [0x140375c58]
mov qword [rbx + 0xb0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rsi]
lea rdx, str.WTSEnumerateSessionsExW
mov qword [rbx + 0xb8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rsi]
lea rdx, [0x140375c30]
mov qword [rbx + 0xc0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rsi]
lea rdx, [0x140375c18]
mov qword [rbx + 0xd0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rbx + 0xd8], rax
mov rsi, qword [rsp + 0x698]
mov eax, 1
mov dword [rbx + 0x30], 1
mov rcx, qword [rbp + 0x550]
xor rcx, rsp
call fcn.140296f70
add rsp, 0x678
pop rbx
pop rbp
ret