Function at 0x140055114
Capabilities:
Check if file exists
Get common file path
Get file attributes
Get file version info
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x850]
sub rsp, 0x950
mov rax, qword [0x1400b8288]
xor rax, rsp
mov qword [rbp + 0x840], rax
movups xmm0, xmmword [str.StringFileInfo_04x_04x_s]
xor edi, edi
mov rsi, r8
movups xmm1, xmmword [0x1400a7768]
mov r15, rdx
mov r12, rcx
movups xmmword [rbp - 0x40], xmm0
mov qword [rbp - 0x68], rcx
xor edx, edx
movups xmm0, xmmword [0x1400a7778]
mov r8d, 0x208
lea rcx, [rbp]
movups xmmword [rbp - 0x30], xmm1
mov r14d, edi
mov dword [rbp - 0x80], edi
movsd xmm1, qword [0x1400a7788]
mov r13d, edi
movups xmmword [rbp - 0x20], xmm0
mov dword [rbp - 0x78], edi
mov dword [rsp + 0x44], edi
mov dword [rsp + 0x48], edi
mov dword [rsp + 0x68], edi
mov dword [rbp - 0x60], edi
mov dword [rsp + 0x4c], edi
mov dword [rbp - 0x7c], edi
mov dword [rbp - 0x74], edi
mov dword [rbp - 0x70], edi
mov dword [rsp + 0x70], edi
mov qword [rbp - 0x48], rdi
mov qword [rbp - 0x58], rdi
mov qword [rsp + 0x78], rdi
mov qword [rbp - 0x50], rdi
movsd qword [rbp - 0x10], xmm1
call sub.msvcrt.dll_memset
test r12, r12
je 0x140055d1d
lea rax, [rsi - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140055d1d
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
nop dword [rax + rax]
cmp eax, 0xffffffff
jne 0x140055203
lea r14d, [rdi + 3]
jmp 0x140055d23
mov ebx, edi
jmp 0x14005520b
mov r12, qword [rbp - 0x68]
cmp ebx, 5
jae 0x140055cf8
lea rax, [rbp]
mov r8, r12
sub r8, rax
lea rcx, [rbp]
mov edx, 0x104
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x14005524a
movzx eax, word [r8 + rcx]
test ax, ax
je 0x14005524a
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x140055227
test rdx, rdx
mov r8d, ebx
lea rax, [rcx - 2]
mov edx, 0x104
cmovne rax, rcx
lea rcx, [rbp]
mov word [rax], di
lea rax, str.pq_n_
mov r8, qword [rax + r8*8]
call fcn.1400010f8
lea r8, [rsp + 0x68]
mov ecx, 1
lea rdx, [rbp]
call qword [sym.imp.VERSION.dll_GetFileVersionInfoSizeExW]
nop dword [rax + rax]
inc ebx
mov r12d, eax
test eax, eax
je 0x140055207
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
nop dword [rax + rax]
mov r8d, r12d
mov edx, 8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
nop dword [rax + rax]
mov qword [rbp - 0x48], rax
mov rbx, rax
test rax, rax
jne 0x1400552d3
lea r14d, [rax + 0xe]
jmp 0x140055d23
lea rdx, str.WINDOWS
mov rcx, rsi
call fcn.140052b40
test eax, eax
je 0x140055cf8
mov r8d, dword [rsp + 0x68]
lea rdx, [rbp]
mov r9d, r12d
mov qword [rsp + 0x20], rbx
mov ecx, 3
call qword [sym.imp.VERSION.dll_GetFileVersionInfoExW]
nop dword [rax + rax]
test eax, eax
je 0x140055cf8
lea r9, [rbp - 0x60]
mov rcx, rbx
lea r8, [rbp - 0x58]
lea rdx, str.VarFileInfoTranslation
call qword [sym.imp.VERSION.dll_VerQueryValueW]
nop dword [rax + rax]
test eax, eax
je 0x140055cf8
mov r12d, 0x208
mov qword [rsp + 0x50], rdi
mov r8d, r12d
mov qword [rsp + 0x60], rdi
xor edx, edx
mov byte [rsp + 0x40], dil
lea rcx, [rbp + 0x210]
mov dword [rsp + 0x6c], edi
call sub.msvcrt.dll_memset
mov r8d, r12d
lea rcx, [rbp + 0x630]
xor edx, edx
call sub.msvcrt.dll_memset
mov r8d, r12d
lea rcx, [rbp + 0x420]
xor edx, edx
call sub.msvcrt.dll_memset
lea rcx, [rbp]
call fcn.14005404c
cmp eax, 0xffff
je 0x140055d15
mov r12d, 0x104
lea r8, [0x14009e38c]
mov edx, r12d
lea rcx, [rbp]
mov r9d, eax
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.ARCH
call fcn.140052db0
mov rax, qword [rbp - 0x58]
lea r8, [rbp - 0x40]
mov edx, r12d
movzx ecx, word [rax + 2]
movzx r9d, word [rax]
lea rax, [0x1400a77d8]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], ecx
lea rcx, [rbp]
call fcn.1400011bc
lea r9, [rsp + 0x68]
mov rcx, rbx
lea r8, [rsp + 0x78]
lea rdx, [rbp]
call qword [sym.imp.VERSION.dll_VerQueryValueW]
nop dword [rax + rax]
mov r8, qword [rsp + 0x78]
test r8, r8
je 0x140055430
lea rdx, str.PRODUCTNAME
mov rcx, rsi
call fcn.140052db0
mov qword [rsp + 0x78], rdi
lea r8, [0x14009b488]
mov rdx, r12
lea rcx, [rbp]
call fcn.1400011bc
lea r9, [rsp + 0x68]
mov rcx, rbx
lea r8, [rsp + 0x78]
lea rdx, [rbp]
call qword [sym.imp.VERSION.dll_VerQueryValueW]
nop dword [rax + rax]
mov rax, qword [rsp + 0x78]
test rax, rax
je 0x140055471
movzx r12d, word [rax + 0x12]
jmp 0x140055477
mov r12d, 6
xor r8d, r8d
lea r9, [rsp + 0x40]
mov dl, 1
lea ecx, [r8 + 0x12]
call qword [sym.imp.ntdll.dll_RtlAdjustPrivilege]
nop dword [rax + rax]
test eax, eax
js 0x140055d0d
test r15, r15
je 0x1400554f3
cmp word [r15], di
je 0x1400554f3
lea rax, [rbp + 0x210]
mov edx, 0x104
sub r15, rax
lea rcx, [rbp + 0x210]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400554dd
movzx eax, word [r15 + rcx]
test ax, ax
je 0x1400554dd
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400554ba
test rdx, rdx
lea rax, [rcx - 2]
mov r15d, 0x104
cmovne rax, rcx
mov word [rax], di
jmp 0x14005550f
mov r15d, 0x104
lea rdx, [rbp + 0x210]
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
nop dword [rax + rax]
cmp word [rbp + 0x210], di
je 0x140055536
lea rcx, [rbp + 0x210]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
nop dword [rax + rax]
cmp eax, 0xffffffff
je 0x140055536
and al, 0x11
cmp al, 0x10
je 0x14005557f
lea r8, [rbp]
mov rdx, r15
lea rax, [rbp + 0x210]
sub r8, rax
lea rcx, [rbp + 0x210]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x140055571
movzx eax, word [r8 + rcx]
test ax, ax
je 0x140055571
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x14005554e
test rdx, rdx
lea rax, [rcx - 2]
cmovne rax, rcx
mov word [rax], di
lea r8, str.SOFTWARE
mov rdx, r15
lea rax, [rbp + 0x420]
sub r8, rax
lea rcx, [rbp + 0x420]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400555bd
movzx eax, word [r8 + rcx]
test ax, ax
je 0x1400555bd
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x14005559a
mov rbx, qword [rbp - 0x68]
lea rax, [rcx - 2]
test rdx, rdx
cmovne rax, rcx
mov word [rax], di
je 0x14005584a
lea rax, [rsp + 0x6c]
mov rcx, rbx
mov qword [rsp + 0x38], rax
lea r8, [rbp + 0x420]
lea rax, [rsp + 0x50]
mov qword [rsp + 0x30], rax
lea rdx, [rbp + 0x210]
lea rax, [rbp + 0x630]
mov qword [rsp + 0x20], rax
call fcn.1400547b4
test eax, eax
je 0x14005584a
mov rcx, qword [rsp + 0x50]
lea rax, [rsp + 0x58]
mov r9d, 0x20019
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov qword [rsp + 0x58], rdi
lea rdx, str.MicrosoftWindows_NTCurrentVersion
mov dword [rsp + 0x44], edi
mov dword [rsp + 0x48], 0x208
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
nop dword [rax + rax]
test eax, eax
jne 0x1400556b0
mov rcx, qword [rsp + 0x58]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x44]
lea rax, [rbp]
xor r8d, r8d
lea rdx, str.EditionID
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x58]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop dword [rax + rax]
test ebx, ebx
jne 0x1400556b0
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.EDITIONID
call fcn.140052db0
mov rcx, qword [rsp + 0x50]
lea rax, [rsp + 0x58]
mov r9d, 0x20019
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov qword [rsp + 0x58], rdi
lea rdx, str.MicrosoftWindows_NTCurrentVersion
mov dword [rsp + 0x44], edi
mov dword [rsp + 0x48], 0x208
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
nop dword [rax + rax]
test eax, eax
jne 0x14005574d
mov rcx, qword [rsp + 0x58]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x44]
lea rax, [rbp]
xor r8d, r8d
lea rdx, str.InstallationType
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x58]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop dword [rax + rax]
test ebx, ebx
jne 0x14005574d
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.INSTALLATIONTYPE
call fcn.140052db0
mov rcx, qword [rsp + 0x50]
lea rdx, [rbp - 0x7c]
call fcn.140053bc4
mov rcx, qword [rsp + 0x50]
lea rdx, [rbp - 0x74]
mov dword [rbp - 0x80], eax
call fcn.140053c74
mov rcx, qword [rsp + 0x50]
lea rdx, [rbp - 0x70]
mov dword [rbp - 0x78], eax
call fcn.140053d24
mov rcx, qword [rsp + 0x50]
lea rdx, [rsp + 0x70]
mov dword [rsp + 0x44], eax
call fcn.140053e10
mov rcx, qword [rsp + 0x50]
lea rdx, [rbp]
mov dword [rsp + 0x48], eax
call fcn.140053ec0
test eax, eax
je 0x140055812
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
nop dword [rax + rax]
mov edx, 8
mov r8d, 0x208
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
nop dword [rax + rax]
mov r13, rax
test rax, rax
je 0x140055812
lea r8, [rbp]
mov rdx, r15
sub r8, rax
mov rcx, rax
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x140055804
movzx eax, word [r8 + rcx]
test ax, ax
je 0x140055804
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400557e1
test rdx, rdx
lea rax, [rcx - 2]
cmovne rax, rcx
mov word [rax], di
mov rcx, qword [rsp + 0x50]
mov rdx, rsi
call fcn.140053068
mov eax, dword [rsp + 0x6c]
lea r8, [rbp + 0x630]
mov r9, qword [rsp + 0x50]
lea rdx, [rbp + 0x420]
lea rcx, [rbp + 0x210]
mov dword [rsp + 0x20], eax
call fcn.140054ea8
mov rbx, qword [rbp - 0x68]
lea r8, str.SYSTEM
mov rdx, r15
lea rax, [rbp + 0x420]
sub r8, rax
lea rcx, [rbp + 0x420]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x140055888
movzx eax, word [r8 + rcx]
test ax, ax
je 0x140055888
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x140055865
test rdx, rdx
lea rax, [rcx - 2]
cmovne rax, rcx
mov word [rax], di
je 0x140055b0b
lea rax, [rsp + 0x6c]
mov rcx, rbx
mov qword [rsp + 0x38], rax
lea r8, [rbp + 0x420]
lea rax, [rsp + 0x50]
mov qword [rsp + 0x30], rax
lea rdx, [rbp + 0x210]
lea rax, [rbp + 0x630]
mov qword [rsp + 0x20], rax
call fcn.1400547b4
test eax, eax
je 0x140055b0b
mov rcx, qword [rsp + 0x50]
lea rdx, [rsp + 0x60]
call fcn.140052ef8
test eax, eax
je 0x140055b0b
mov r15, qword [rsp + 0x60]
lea rdx, [rbp]
mov rcx, r15
call fcn.14005326c
test eax, eax
je 0x140055919
lea r8, [rbp]
mov rcx, rsi
lea rdx, [0x1400a7870]
call fcn.140052db0
lea rax, [rsp + 0x60]
mov qword [rsp + 0x60], rdi
mov r9d, 0x20019
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov dword [rsp + 0x58], edi
lea rdx, str.ControlProductOptions
mov dword [rsp + 0x4c], 0x208
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
nop dword [rax + rax]
test eax, eax
jne 0x1400559b4
mov rcx, qword [rsp + 0x60]
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x58]
lea rax, [rbp]
xor r8d, r8d
lea rdx, str.ProductType
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x60]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop dword [rax + rax]
test ebx, ebx
jne 0x1400559b4
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.PRODUCTTYPE
call fcn.140052db0
lea rax, [rsp + 0x60]
mov qword [rsp + 0x60], rdi
mov r9d, 0x20019
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov dword [rsp + 0x4c], edi
lea rdx, str.ControlProductOptions
mov dword [rsp + 0x58], 0x208
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
nop dword [rax + rax]
test eax, eax
jne 0x140055a4f
mov rcx, qword [rsp + 0x60]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x4c]
lea rax, [rbp]
xor r8d, r8d
lea rdx, str.ProductSuite
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x60]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop dword [rax + rax]
test ebx, ebx
jne 0x140055a4f
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.PRODUCTSUITE
call fcn.140052db0
lea rdx, [rbp]
mov rcx, r15
call fcn.140053430
test eax, eax
je 0x140055ac3
lea rdx, str.LANGUAGES
mov rcx, rsi
call fcn.140052b40
test eax, eax
je 0x140055ac3
cmp r12d, 6
jb 0x140055a8e
lea rax, [rbp]
mov rdx, rsi
mov rcx, r15
mov qword [rsp + 0x20], rax
call fcn.140053a14
jmp 0x140055ab4
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.LANGUAGE
call fcn.140052db0
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.DEFAULT
call fcn.140052db0
lea rdx, str.LANGUAGES
mov rcx, rsi
call fcn.140052c78
mov rcx, r15
call fcn.140053b14
mov rcx, r15
mov dword [rsp + 0x4c], eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop dword [rax + rax]
mov eax, dword [rsp + 0x6c]
lea r8, [rbp + 0x630]
mov r9, qword [rsp + 0x50]
lea rdx, [rbp + 0x420]
lea rcx, [rbp + 0x210]
mov dword [rsp + 0x20], eax
call fcn.140054ea8
mov r15d, 0x104
cmp byte [rsp + 0x40], dil
jne 0x140055b2b
xor edx, edx
lea r9, [rsp + 0x40]
xor r8d, r8d
lea ecx, [rdx + 0x12]
call qword [sym.imp.ntdll.dll_RtlAdjustPrivilege]
nop dword [rax + rax]
mov rbx, qword [rsp + 0x78]
test rbx, rbx
je 0x140055c97
lea rdx, str.VERSION
mov rcx, rsi
call fcn.140052b40
test eax, eax
je 0x140055c97
cmp dword [rbp - 0x80], edi
movzx r9d, word [rbx + 0x12]
cmovne r9d, dword [rbp - 0x7c]
cmp dword [rbp - 0x78], edi
movzx r15d, word [rbx + 0x10]
cmovne r15d, dword [rbp - 0x74]
cmp dword [rsp + 0x44], edi
movzx r12d, word [rbx + 0x16]
cmovne r12d, dword [rbp - 0x70]
movzx ebx, word [rbx + 0x14]
cmp dword [rsp + 0x48], edi
je 0x140055b8b
cmp dword [rsp + 0x70], ebx
cmova ebx, dword [rsp + 0x70]
lea r8, [0x14009e38c]
mov edx, 0x104
lea rcx, [rbp]
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.MAJOR
call fcn.140052db0
mov r9d, r15d
lea r8, [0x14009e38c]
mov r15d, 0x104
lea rcx, [rbp]
mov edx, r15d
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.MINOR
call fcn.140052db0
mov r9d, r12d
lea rcx, [rbp]
lea r12, [0x14009e38c]
mov edx, r15d
mov r8, r12
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.BUILD
call fcn.140052db0
mov r9d, ebx
lea rcx, [rbp]
mov r8, r12
mov edx, r15d
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.SPBUILD
call fcn.140052db0
mov r9d, dword [rsp + 0x4c]
lea rcx, [rbp]
mov r8, r12
mov edx, r15d
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.SPLEVEL
call fcn.140052db0
test r13, r13
je 0x140055c88
mov r9, r13
lea r8, [0x14009bcbc]
mov edx, r15d
lea rcx, [rbp]
call fcn.1400011bc
lea r8, [rbp]
mov rcx, rsi
lea rdx, str.BRANCH
call fcn.140052db0
lea rdx, str.VERSION
mov rcx, rsi
call fcn.140052c78
xor edx, edx
lea rcx, [rbp]
mov r8d, 0x208
call sub.msvcrt.dll_memset
mov rcx, qword [rbp - 0x68]
lea r9, [rbp - 0x50]
lea r8, [rbp]
mov edx, r15d
call qword [sym.imp.KERNEL32.dll_GetFullPathNameW]
nop dword [rax + rax]
test eax, eax
je 0x140055ce5
cmp word [rbp], di
je 0x140055ce5
mov r8, qword [rbp - 0x50]
test r8, r8
je 0x140055ce5
lea rdx, str.SYSTEMROOT
mov rcx, rsi
call fcn.140052db0
lea rdx, str.WINDOWS
mov rcx, rsi
call fcn.140052c78
test eax, eax
jne 0x140055d32
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov r14d, eax
test eax, eax
je 0x140055d32
jmp 0x140055d23
mov r14d, 5
jmp 0x140055d23
mov r14d, 0xb
jmp 0x140055d23
mov r14d, 0x57
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
nop dword [rax + rax]
test r13, r13
je 0x140055d57
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
nop dword [rax + rax]
mov r8, r13
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
nop dword [rax + rax]
mov rbx, qword [rbp - 0x48]
test rbx, rbx
je 0x140055d80
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
nop dword [rax + rax]
mov r8, rbx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
nop dword [rax + rax]
test r14d, r14d
sete dil
mov eax, edi
mov rcx, qword [rbp + 0x840]
xor rcx, rsp
call fcn.140096bd0
mov rbx, qword [rsp + 0x998]
add rsp, 0x950
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret