Function at 0x140002540
Capabilities:
Create directory

Disassembly:
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x238
mov rdi, rdx
mov ebp, ecx
mov rax, qword [0x140037010]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov rcx, qword [rdx + 8]
lea rdx, str.forceinstall
mov rbx, qword [sym.imp.KERNEL32.dll_lstrcmpiW]
call rbx
mov esi, eax
mov rcx, qword [rdi + 8]
lea rdx, [0x140030054]
call rbx
test esi, esi
je 0x1400025fe
test eax, eax
je 0x1400025fe
mov rcx, qword [rdi + 8]
lea rdx, [0x140030232]
call qword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x1400026e3
mov rcx, qword [rdi + 8]
lea rdx, str.uninstall
call qword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x14000278f
mov rcx, qword [rdi + 8]
lea rdx, [0x14002fea4]
call qword [sym.imp.KERNEL32.dll_lstrcmpiW]
cmp ebp, 3
jl 0x14000286c
test eax, eax
jne 0x14000286c
mov rcx, qword [rdi + 0x10]
mov rdx, qword [rdi + 0x18]
xor r8d, r8d
call fcn.14000af00
xor esi, esi
test eax, eax
sete sil
jmp 0x140002960
lea rdx, [rsp + 0x20]
xor ecx, ecx
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x140002628
lea rcx, [rsp + 0x20]
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
jne 0x14000297e
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
mov ecx, dword [rcx + 4]
test esi, esi
je 0x140002659
mov esi, 1
lea rdi, str.Installing_service...
jmp 0x140002665
mov esi, 2
lea rdi, str.Installing_service_with_force_specified...
cmp eax, ecx
jg 0x140002b30
lea rcx, [0x140038f88]
mov rdx, rdi
call fcn.14000b9f0
mov ecx, esi
call fcn.140003e00
mov ecx, dword [0x140039198]
mov edx, dword [0x140037cbc]
mov rbp, qword gs:[0x58]
mov rdx, qword [rbp + rdx*8]
mov edx, dword [rdx + 4]
test eax, eax
je 0x1400026c2
cmp ecx, edx
jg 0x140002b71
lea rcx, [0x140038f88]
lea rdx, str.The_service_was_installed_successfully
jmp 0x140002834
cmp ecx, edx
jg 0x140002bf3
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [0x140038f88]
lea rdx, str.Could_not_install_service.____d_
jmp 0x140002912
lea rdx, [rsp + 0x20]
xor ecx, ecx
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x14000270d
lea rcx, [rsp + 0x20]
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
jne 0x1400029f9
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002c34
lea rcx, [0x140038f88]
lea rdx, str.Upgrading_service_if_installed...
call fcn.14000b9f0
xor ecx, ecx
call fcn.140003e00
mov ecx, dword [0x140039198]
mov edx, dword [0x140037cbc]
mov rbp, qword gs:[0x58]
mov rdx, qword [rbp + rdx*8]
mov edx, dword [rdx + 4]
test eax, eax
je 0x1400028d8
cmp ecx, edx
jg 0x140002c75
lea rcx, [0x140038f88]
lea rdx, str.The_service_was_upgraded_successfully
jmp 0x140002834
lea rdx, [rsp + 0x20]
xor ecx, ecx
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x1400027b9
lea rcx, [rsp + 0x20]
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
jne 0x140002a74
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002cb6
lea rcx, [0x140038f88]
lea rdx, str.Uninstalling_service...
call fcn.14000b9f0
call fcn.1400056e0
mov ecx, dword [0x140039198]
mov edx, dword [0x140037cbc]
mov rbp, qword gs:[0x58]
mov rdx, qword [rbp + rdx*8]
mov edx, dword [rdx + 4]
test eax, eax
je 0x1400028f6
cmp ecx, edx
jg 0x140002cf7
lea rcx, [0x140038f88]
lea rdx, str.The_service_was_uninstalled_successfully
call fcn.14000b9f0
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002aef
mov rcx, qword [0x140038f88]
xor esi, esi
jmp 0x14000294b
movaps xmm0, xmmword [0x14002d6f0]
lea rcx, [rsp + 0x20]
movaps xmmword [rcx + 0x10], xmm0
movaps xmm0, xmmword [str.MozillaMaintenance]
movaps xmmword [rcx], xmm0
call qword [sym.imp.ADVAPI32.dll_StartServiceCtrlDispatcherW]
test eax, eax
jne 0x1400028d1
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002dba
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [0x140038f88]
lea rdx, str.StartServiceCtrlDispatcher_failed.____d_
mov r8d, eax
call fcn.14000ba70
xor esi, esi
jmp 0x140002960
cmp ecx, edx
jg 0x140002d38
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [0x140038f88]
lea rdx, str.Could_not_upgrade_service.____d_
jmp 0x140002912
cmp ecx, edx
jg 0x140002d79
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [0x140038f88]
lea rdx, str.Could_not_uninstall_service.____d_
mov r8d, eax
call fcn.14000ba70
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002bb2
mov rcx, qword [0x140038f88]
mov esi, 1
test rcx, rcx
je 0x140002960
call fcn.1400158b0
mov qword [0x140038f88], 0
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.1400187d0
mov eax, esi
add rsp, 0x238
pop rbx
pop rbp
pop rdi
pop rsi
ret
lea rdx, str.logs
lea rcx, [rsp + 0x20]
call fcn.140027670
test eax, eax
je 0x140002628
lea rdi, [rsp + 0x20]
mov rcx, rdi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea rdx, str.maintenanceservice_install.log
mov rcx, rdi
call fcn.140027670
test eax, eax
je 0x140002628
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002dfb
lea rcx, [0x140038f88]
lea rdx, [rsp + 0x20]
call fcn.14000b960
jmp 0x140002628
lea rdx, str.logs
lea rcx, [rsp + 0x20]
call fcn.140027670
test eax, eax
je 0x14000270d
lea rsi, [rsp + 0x20]
mov rcx, rsi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea rdx, str.maintenanceservice_install.log
mov rcx, rsi
call fcn.140027670
test eax, eax
je 0x14000270d
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002e3c
lea rcx, [0x140038f88]
lea rdx, [rsp + 0x20]
call fcn.14000b960
jmp 0x14000270d
lea rdx, str.logs
lea rcx, [rsp + 0x20]
call fcn.140027670
test eax, eax
je 0x1400027b9
lea rsi, [rsp + 0x20]
mov rcx, rsi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea rdx, str.maintenanceservice_uninstall.log
mov rcx, rsi
call fcn.140027670
test eax, eax
je 0x1400027b9
mov eax, dword [0x140039198]
mov ecx, dword [0x140037cbc]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140002e7d
lea rcx, [0x140038f88]
lea rdx, [rsp + 0x20]
call fcn.14000b960
jmp 0x1400027b9
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x14000285e
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x14000285e
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x14000266d
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x14000266d
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400026af
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400026af
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x14000293f
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x14000293f
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400026ca
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400026ca
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x140002732
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x140002732
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x14000277c
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x14000277c
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400027de
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400027de
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x140002826
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x140002826
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400028e0
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400028e0
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400028fe
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400028fe
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400028b5
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400028b5
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x1400029e3
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x1400029e3
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x140002a5e
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x140002a5e
lea rcx, [0x140039198]
call fcn.14000de70
cmp dword [0x140039198], 0xffffffff
jne 0x140002ad9
mov qword [0x140038f88], 0
lea rcx, [0x1400035f0]
call fcn.14000e028
lea rcx, [0x140039198]
call fcn.14000ded8
jmp 0x140002ad9