Function at 0x140156aa0
Capabilities:
Query environment variable
Set current directory

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x31e0]
mov eax, 0x32e0
call fcn.140160160
sub rsp, rax
mov rax, qword [0x1403fad18]
xor rax, rsp
mov qword [rbp + 0x31d0], rax
mov rax, qword [sym.imp.MSVCR100.dll___argc]
mov ebx, 1
movsxd r13, dword [rax]
mov rax, qword [sym.imp.MSVCR100.dll___argv]
mov rcx, qword [rax]
mov rsi, r13
mov qword [rsp + 0x78], rcx
cmp rbx, r13
jge 0x140156b9f
nop dword [rax + rax]
mov rax, qword [rsp + 0x78]
mov rcx, qword [rax + rbx*8]
movzx eax, byte [rcx]
cmp al, 0x2f
je 0x140156b24
cmp al, 0x2d
jne 0x140156b93
lea rdx, str.embedding
inc rcx
call qword [sym.imp.MSVCR100.dll__stricmp]
test eax, eax
jne 0x140156b93
lea rdx, [rbp + 0x11c0]
lea rcx, str.HOMEDRIVE
mov r8d, 0x1004
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x140156b93
cmp eax, 0x1004
jae 0x140156b93
mov edi, 0x1004
lea rcx, [0x1402e6a80]
sub edi, eax
mov eax, eax
lea rdx, [rbp + rax*2 + 0x11c0]
mov r8d, edi
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x140156b93
cmp eax, edi
jae 0x140156b93
lea rcx, [rbp + 0x11c0]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
inc rbx
cmp rbx, r13
jl 0x140156b10
lea rdx, [rsp + 0x78]
xor r8d, r8d
mov ecx, r13d
call qword [sym.imp.BstkRT.dll_RTR3InitExe]
mov r8, qword [rsp + 0x78]
xor ebx, ebx
mov dword [rsp + 0x30], ebx
xor r12d, r12d
lea r9, str.__embedding
lea rcx, [rbp - 0x40]
mov edx, r13d
mov dword [rsp + 0x28], 1
mov qword [rsp + 0x20], 0x1b
mov sil, 1
lea r14d, [r12 + 0xa]
mov r15d, 0x15180
mov qword [rbp + 0x20], 0x6400000
call qword [sym.imp.BstkRT.dll_RTGetOptInit]
lea rdx, [rbp + 0x10]
lea rcx, [rbp - 0x40]
call qword [sym.imp.BstkRT.dll_RTGetOpt]
mov edi, eax
test eax, eax
je 0x140156ddf
lea r13, [0x140000000]
lea eax, [rdi - 0x46]
cmp eax, 0x2f
ja case.0x140156c37.79
movsxd rcx, eax
movzx eax, byte [r13 + rcx + 0x1571fc]
mov ecx, dword [r13 + rax*4 + 0x1571d4]
add rcx, r13
jmp rcx
xor sil, sil
jmp case.0x140156c37.76
mov rax, qword [rbp + 0x10]
lea r12, [0x140247df8]
test rax, rax
cmovne r12, rax
xor sil, sil
jmp case.0x140156c37.76
mov rbx, qword [rbp + 0x10]
jmp case.0x140156c37.76
mov r14d, dword [rbp + 0x10]
jmp case.0x140156c37.76
mov rax, qword [rbp + 0x10]
mov qword [rbp + 0x20], rax
jmp case.0x140156c37.76
mov r15d, dword [rbp + 0x10]
jmp case.0x140156c37.76
lea rdx, [rbp + 0x10]
mov ecx, edi
call qword [sym.imp.BstkRT.dll_RTGetOptPrintError]
lea rdx, [rbp + 0x10]
lea rcx, [rbp - 0x40]
call qword [sym.imp.BstkRT.dll_RTGetOpt]
mov edi, eax
test eax, eax
jne 0x140156c18
test sil, sil
je 0x140156ea7
test rbx, rbx
je 0x140156ddf
lea r8, [0x140248d24]
lea rcx, [rbp + 0x1b0]
mov r9, rbx
mov edx, 0x1004
call qword [sym.imp.BstkRT.dll_RTStrPrintf]
test rax, rax
jne 0x140156e1c
mov eax, 0xfffffff8
lea rdx, str.failed_to_create_logging_file_name__rc_Rrc
mov r8d, eax
mov ecx, 1
call qword [sym.imp.BstkRT.dll_RTMsgErrorExit]
mov rcx, qword [rbp + 0x31d0]
xor rcx, rsp
call fcn.14015fe00
lea r11, [rsp + 0x32e0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
lea rcx, [rbp + 0x40]
lea rdx, str.Options:_n_n_RegServer:_tregister_COM_out_of_proc_server_n_UnregServer:_tunregister_COM_out_of_proc_server_n_ReregServer:_tunregister_and_register_COM_server_nno_options:_trun_the_server
mov r8d, 0x164
call sub.MSVCR100.dll_memcpy
mov rax, qword [str.Usage]
lea r8, [rbp + 0x20]
mov qword [rbp + 0x20], rax
mov eax, dword [0x1402e6720]
lea rdx, [rbp + 0x40]
xor r9d, r9d
xor ecx, ecx
mov dword [rbp + 0x28], eax
call qword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
jmp 0x140156ce2
xor edi, edi
mov qword [rsp + 0x70], rdi
call qword [sym.imp.BstkRT.dll_RTBldCfgRevisionStr]
mov rbx, rax
call qword [sym.imp.BstkRT.dll_RTBldCfgVersion]
lea rdx, str._sr_s_n
lea rcx, [rsp + 0x70]
mov r9, rbx
mov r8, rax
call fcn.14001bff0
mov rcx, qword [rsp + 0x70]
lea r8, str.C:_virtualbox_srcVBoxMain_src_serverwin_svcmain.cpp
lea rdx, [rbp + 0x20]
mov qword [rbp + 0x20], rdi
call qword [sym.imp.BstkRT.dll_RTStrToUtf16Tag]
mov rax, qword [str.Version]
mov rdx, qword [rbp + 0x20]
mov qword [rbp + 0x30], rax
mov rax, qword [0x1402e66d0]
lea r8, [rbp + 0x30]
xor r9d, r9d
xor ecx, ecx
mov qword [rbp + 0x38], rax
call qword [sym.imp.USER32.dll_MessageBoxW]
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.BstkRT.dll_RTStrFree]
mov rcx, qword [rbp + 0x20]
call qword [sym.imp.BstkRT.dll_RTUtf16Free]
xor eax, eax
jmp 0x140156ce2
lea rcx, [rbp + 0x1b0]
mov r8b, 1
mov edx, 0x1004
call fcn.1401e74f0
test eax, eax
js 0x140156ccd
lea r8, str.BstkServer.log
lea rcx, [rbp + 0x1b0]
mov edx, 0x1004
call qword [sym.imp.BstkRT.dll_RTPathAppend]
test eax, eax
js 0x140156ccd
mov qword [rsp + 0x58], 0x1084
lea rax, [rbp + 0x11c0]
lea r9, [0x140271bc0]
mov qword [rsp + 0x50], rax
mov rax, qword [rbp + 0x20]
lea rdx, [rbp + 0x1b0]
mov qword [rsp + 0x48], rax
mov dword [rsp + 0x40], r15d
mov dword [rsp + 0x38], r14d
lea rax, str.VBOXSVC_RELEASE_LOG
mov dword [rsp + 0x30], 0xffffffff
lea rcx, str.COM_Server
mov r8d, 0x4800000
mov dword [rsp + 0x28], 1
mov qword [rsp + 0x20], rax
call fcn.1401e79f0
mov edi, eax
test eax, eax
jns 0x140156ea7
lea r8, [rbp + 0x11c0]
lea rdx, str.failed_to_open_release_log___s___Rrc_
mov r9d, eax
mov ecx, 1
call qword [sym.imp.BstkRT.dll_RTMsgErrorExit]
jmp 0x140156ce2
call qword [sym.imp.BstkRT.dll_RTBldCfgRevision]
mov ebx, eax
call qword [sym.imp.BstkRT.dll_RTBldCfgVersion]
lea r8, [0x1402e6660]
mov qword [rsp + 0x60], r8
lea rdx, [0x1402e665c]
lea rcx, [0x1402e6658]
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x50], rcx
lea r9, [0x1402e6654]
mov qword [rsp + 0x48], r9
mov dword [rsp + 0x40], ebx
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], r8
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x20], rcx
lea rcx, [0x1403fcce8]
lea r8, str._s_s_s_s_VirtualBox__s_r_u__s_s_s_s
mov edx, 0x30
call qword [sym.imp.BstkRT.dll_RTStrPrintf]
xor r14d, r14d
movzx edx, sil
xor ecx, ecx
mov r13d, r14d
call fcn.1401e7af0
mov ebx, eax
test eax, eax
jns 0x140156fb6
mov ecx, 0xa80010
call qword [sym.imp.BstkRT.dll_RTLogRelGetDefaultInstanceEx]
test rax, rax
je 0x140156f87
lea rdx, str.SUCCEEDED_hRes_
lea rcx, str.C:_virtualbox_srcVBoxMain_src_serverwin_svcmain.cpp
lea r9, str.AssertLogRel__s__d___s:__s_n
mov qword [rsp + 0x38], rdx
lea rdx, str.int___cdecl_WinMain_struct_HINSTANCE____struct_HINSTANCE____char__int_
mov r8d, 0xa8
mov qword [rsp + 0x30], rdx
mov dword [rsp + 0x28], 0x1f8
mov qword [rsp + 0x20], rcx
lea edx, [r14 + 0x10]
mov rcx, rax
call qword [sym.imp.BstkRT.dll_RTLogLoggerEx]
mov ecx, 0xa80010
call qword [sym.imp.BstkRT.dll_RTLogRelGetDefaultInstanceEx]
test rax, rax
je 0x140156fb6
lea r9, str.SVCMAIN:_init_failed:__Rhrc_n
mov edx, reloc.OLEAUT32.dll_SafeArrayGetDim
mov r8d, 0xa8
mov rcx, rax
mov dword [rsp + 0x20], ebx
call qword [sym.imp.BstkRT.dll_RTLogLoggerEx]
mov ecx, 0x68
call sub.MSVCR100.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rbx, rax
test rax, rax
je 0x140156fdc
mov rcx, rax
call fcn.1401567f0
lea r11, vtable.CExeModule.0
mov qword [rbx], r11
jmp 0x140156fdf
mov rbx, r14
mov qword [0x1403fccd0], rbx
test rbx, rbx
jne 0x140157000
lea rdx, str.not_enough_memory_to_create_ExeModule.
lea ecx, [rbx + 1]
call qword [sym.imp.BstkRT.dll_RTMsgErrorExit]
jmp 0x140156ce2
mov eax, dword [0x140321da8]
mov dword [0x1403fc678], eax
mov eax, dword [0x140321dac]
mov dword [0x1403fc67c], eax
mov eax, dword [0x140321db0]
mov dword [0x1403fc680], eax
mov eax, dword [0x140321db4]
mov dword [0x1403fc684], eax
lea rax, [0x1403fa420]
cmp rax, 0xffffffffffffffff
je 0x140157059
mov qword [rbx + 0x48], rax
cmp qword [0x1403fa420], r13
je 0x140157059
nop word [rax + rax]
add rax, 0x28
cmp qword [rax], r13
jne 0x140157050
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov rcx, qword [0x1403fccd0]
mov dword [rcx + 0x50], eax
test sil, sil
jne 0x1401570c3
test r12, r12
je 0x14015719c
cmp byte [r12], r13b
je 0x1401570b8
test edi, edi
js 0x1401570b8
lea rcx, [rbp - 0x80]
call fcn.140157a90
lea rcx, [rbp - 0x80]
mov rdx, r12
call fcn.140157cb0
mov ebx, eax
test eax, eax
js 0x1401570a7
lea rcx, [rbp - 0x80]
call fcn.140157ad0
mov ebx, eax
lea rcx, [rbp - 0x80]
call fcn.140157840
test ebx, ebx
jns 0x14015719c
mov r13d, 1
jmp 0x14015719c
mov rcx, qword [0x1403fccd0]
call fcn.1401563f0
mov rcx, qword [0x1403fccd0]
mov edx, 4
lea r8d, [rdx + 1]
call fcn.140155d10
call qword [sym.imp.ole32.dll_CoResumeClassObjects]
call fcn.140156010
lea rcx, [rbp - 0x80]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jle 0x14015712f
lea rcx, [rbp - 0x80]
call qword [sym.imp.USER32.dll_DispatchMessageW]
lea rcx, [rbp - 0x80]
call qword [sym.imp.USER32.dll_TranslateMessage]
lea rcx, [rbp - 0x80]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jg 0x140157105
mov rcx, qword [0x1403fccd8]
test rcx, rcx
je 0x140157168
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [0x1403fcce0]
mov qword [0x1403fccd8], r14
test rdx, rdx
je 0x140157168
lea rcx, str.VirtualBox_Interface
call qword [sym.imp.USER32.dll_UnregisterClassW]
mov qword [0x1403fcce0], r14
mov rax, qword [0x1403fccd0]
mov edx, r14d
mov rbx, qword [rax + 0x48]
test rbx, rbx
je 0x14015719c
cmp qword [rbx], rdx
je 0x14015719c
test edx, edx
js 0x14015719c
mov ecx, dword [rbx + 0x20]
test ecx, ecx
je 0x140157193
call qword [sym.imp.ole32.dll_CoRevokeClassObject]
mov edx, eax
add rbx, 0x28
cmp qword [rbx], r13
jne 0x140157180
mov rcx, qword [0x1403fccd0]
call fcn.140155c70
call fcn.1401e7c70
mov rcx, qword [0x1403fccd0]
test rcx, rcx
je 0x1401571c4
mov r8, qword [rcx]
mov edx, 1
call qword [r8]
mov qword [0x1403fccd0], r14
mov eax, r13d
jmp 0x140156ce2