Function at 0x140001010
Capabilities:
Accept command line arguments
Check if file exists
Get common file path

Disassembly:
mov eax, 0x28
call fcn.140013cf0
sub rsp, rax
xor ecx, ecx
add rsp, 0x28
jmp 0x140013480
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x860]
mov eax, 0x960
call fcn.140013cf0
sub rsp, rax
mov rax, qword [0x140020018]
xor rax, rsp
mov qword [rbp + 0x850], rax
movzx r13d, cl
lea rdx, [rbp + 0x10]
lea rcx, [rbp + 0x640]
call fcn.14000e860
xorps xmm0, xmm0
mov dword [rsp + 0x70], 0x68
xor eax, eax
lea rcx, [rsp + 0x70]
movups xmmword [rsp + 0x74], xmm0
mov dword [rbp - 0x2c], eax
movups xmmword [rbp - 0x7c], xmm0
movups xmmword [rbp - 0x6c], xmm0
movups xmmword [rbp - 0x5c], xmm0
movups xmmword [rbp - 0x4c], xmm0
movups xmmword [rbp - 0x3c], xmm0
call qword [sym.imp.KERNEL32.dll_GetStartupInfoW]
mov rdi, 0xffffffffffffffff
mov dword [rsp + 0x50], 0xffffffff
mov rbx, rdi
lea rax, [rbp + 0x10]
nop dword [rax]
inc rbx
cmp word [rax + rbx*2], 0
jne 0x140013520
lea rdx, [rbp + 0x430]
mov ecx, 0x104
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea r8, [rbp + 0x10]
mov qword [rsp + 0x20], 0xc
mov r15d, eax
lea r8, [r8 + rbx*2]
xor eax, eax
lea r9, str.redirect.ini
cmp r15d, 0x104
lea rdx, [rbp + 0x10]
lea rcx, [rbp + 0x220]
cmovae r15d, eax
call fcn.140015760
test rax, rax
je 0x14001359f
lea rdx, [rsp + 0x54]
lea rcx, [rbp + 0x220]
call qword [sym.imp.KERNEL32.dll_GetBinaryTypeW]
test eax, eax
jne 0x14001359a
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x14001359f
mov r14b, 1
jmp 0x1400135a2
xor r14b, r14b
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov rsi, rax
mov rdx, rdi
nop
inc rdx
cmp word [rax + rdx*2], 0
jne 0x1400135b0
lea eax, [r15*4]
add rax, rdx
lea rcx, [rax + 0x36]
add rcx, rbx
test r14b, r14b
cmove rcx, rax
mov eax, 2
add rcx, 0x12
mul rcx
cmovo rax, rdi
mov rcx, rax
call fcn.140014088
mov r12, rax
mov rbx, rdi
cmp word [rsi + rbx*2 + 2], 0
lea rbx, [rbx + 1]
jne 0x1400135f1
lea r8, [rbx + 1]
mov rdx, rsi
mov rcx, r12
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
lea rbx, [r12 + rbx*2]
test r14b, r14b
je 0x14001366f
mov r8d, 0x2a
lea rdx, str.___env:INIFILENAMEvnd.sun.star.pathname:
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
add rbx, 0x52
lea rax, [rbp + 0x10]
cmp word [rax + rdi*2 + 2], 0
lea rdi, [rdi + 1]
jne 0x140013634
lea r8, [rdi + 1]
mov rcx, rbx
lea rdx, [rbp + 0x10]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
lea rbx, [rbx + rdi*2]
mov r8d, 0xe
mov rcx, rbx
lea rdx, str.redirect.ini_
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
add rbx, 0x1a
mov r8d, 0x10
lea rdx, str.___env:OOO_CWD
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
lea rdi, [rbx + 0x20]
mov r8d, 2
lea rcx, [rbx + 0x1e]
test r15d, r15d
jne 0x1400136a7
lea rdx, [0x1400189c8]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
jmp 0x1400136c6
lea rdx, [0x1400189cc]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
lea rdx, [rbp + 0x430]
mov rcx, rdi
call fcn.14000d580
mov rdi, rax
mov r8d, 2
lea rdx, [0x140018878]
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy]
lea rcx, [rsp + 0x58]
mov eax, r13d
mov qword [rsp + 0x48], rcx
xor eax, 1
lea rcx, [rsp + 0x70]
shl eax, 3
mov qword [rsp + 0x40], rcx
xor edi, edi
lea rcx, [rbp + 0x10]
xor r9d, r9d
mov qword [rsp + 0x38], rcx
xor r8d, r8d
mov qword [rsp + 0x30], rdi
lea rcx, [rbp + 0x640]
mov dword [rsp + 0x28], eax
mov rdx, r12
mov dword [rsp + 0x20], 1
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
mov rcx, r12
mov ebx, eax
call fcn.140014090
test ebx, ebx
je 0x1400137a7
nop dword [rax]
xor r8d, r8d
mov dword [rsp + 0x20], 0x4bf
mov r9d, 0xffffffff
lea rdx, [rsp + 0x58]
lea ecx, [r8 + 1]
call qword [sym.imp.USER32.dll_MsgWaitForMultipleObjects]
cmp eax, 1
jne 0x14001377d
xor r9d, r9d
mov dword [rsp + 0x20], eax
xor r8d, r8d
lea rcx, [rbp - 0x20]
xor edx, edx
call qword [sym.imp.USER32.dll_PeekMessageW]
jmp 0x140013740
mov rcx, qword [rsp + 0x58]
lea rdx, [rsp + 0x50]
mov dword [rsp + 0x50], edi
call qword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [rsp + 0x50]
mov rcx, qword [rbp + 0x850]
xor rcx, rsp
call fcn.1400141b0
lea r11, [rsp + 0x960]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret