Function at 0x1400b5940
Capabilities:
Query or enumerate registry value
Set environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0xd0
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0xc0], rax
mov rdi, rcx
mov rax, qword [rcx]
lea rdx, [rsp + 0x30]
mov rax, qword [rax + 0x40]
call qword [case.0x1400d90b6.0]
nop
mov rdx, rax
lea rcx, [rsp + 0x98]
call fcn.14000fcc0
lea rdx, [rsp + 0x98]
cmp qword [rsp + 0xb0], 8
cmovae rdx, qword [rsp + 0x98]
lea rcx, str.COMMON_APPDATA
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, qword [rsp + 0xb0]
cmp rdx, 8
jb 0x1400b59f9
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x98]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400b59f4
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400b5e55
call fcn.1401853a0
xor ebx, ebx
mov qword [rsp + 0xa8], rbx
mov qword [rsp + 0xb0], 7
mov word [rsp + 0x98], bx
lea rcx, [rsp + 0x30]
call fcn.140010b20
mov rax, qword [rdi]
lea rdx, [rsp + 0x30]
mov rcx, rdi
mov rax, qword [rax + 0x58]
call qword [case.0x1400d90b6.0]
nop
mov rdx, rax
lea rcx, [rsp + 0x98]
call fcn.14000fcc0
lea rdx, [rsp + 0x98]
cmp qword [rsp + 0xb0], 8
cmovae rdx, qword [rsp + 0x98]
lea rcx, str.PROGRAMFILESX86
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, qword [rsp + 0xb0]
cmp rdx, 8
jb 0x1400b5ab6
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x98]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400b5ab1
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400b5e5b
call fcn.1401853a0
mov qword [rsp + 0xa8], rbx
mov qword [rsp + 0xb0], 7
mov word [rsp + 0x98], bx
lea rcx, [rsp + 0x30]
call fcn.140010b20
mov rax, qword [rdi]
lea rdx, [rsp + 0x30]
mov rcx, rdi
mov rax, qword [rax + 0x50]
call qword [case.0x1400d90b6.0]
nop
mov rdx, rax
lea rcx, [rsp + 0x98]
call fcn.14000fcc0
lea rdx, [rsp + 0x98]
cmp qword [rsp + 0xb0], 8
cmovae rdx, qword [rsp + 0x98]
lea rcx, str.PROGRAMFILES
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, qword [rsp + 0xb0]
cmp rdx, 8
jb 0x1400b5b71
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x98]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400b5b6c
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400b5e61
call fcn.1401853a0
mov qword [rsp + 0xa8], rbx
mov qword [rsp + 0xb0], 7
mov word [rsp + 0x98], bx
lea rcx, [rsp + 0x30]
call fcn.140010b20
nop
xorps xmm0, xmm0
movups xmmword [rsp + 0x98], xmm0
mov qword [rsp + 0xa0], rbx
lea rsi, vtable.RegistryAccess.0
mov qword [rsp + 0x98], rsi
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x20], rax
mov r9d, 0x20119
xor r8d, r8d
lea rdx, str.SOFTWARESophosSophos_for_Virtual_EnvironmentsSGVM_Management_Service
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov edi, eax
test eax, eax
jne 0x1400b5e67
lea rax, [rsp + 0x90]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0xb8]
xor r8d, r8d
lea rdx, str.Sophos_Folder_path
mov rcx, qword [rsp + 0xa0]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
test eax, eax
jne 0x1400b5e86
mov edx, dword [rsp + 0x90]
mov ecx, dword [rsp + 0xb8]
call fcn.1401338b0
mov r9d, dword [rsp + 0x90]
lea r8, str.Sophos_Folder_path
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x98]
call fcn.140134c10
lea rdx, [rsp + 0x30]
cmp qword [rsp + 0x48], 8
cmovae rdx, qword [rsp + 0x30]
lea rcx, str.SGVM_INSTALL_DIR
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x1400b5cbf
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400b5cb9
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400b5ea5
call fcn.1401853a0
nop
lea rdi, vtable.RegistryHandle.0
mov qword [rsp + 0x98], rdi
mov rcx, qword [rsp + 0xa0]
test rcx, rcx
je 0x1400b5ce2
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
jmp 0x1400b5cf4
xorps xmm0, xmm0
movups xmmword [rsp + 0x98], xmm0
mov qword [rsp + 0xa0], rbx
mov qword [rsp + 0x98], rsi
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x20], rax
mov r9d, 0x20219
xor r8d, r8d
lea rdx, str.SOFTWARESophosSophos_for_Virtual_EnvironmentsSGVM_Management_Service
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, eax
test eax, eax
jne 0x1400b5eab
lea rax, [rsp + 0x90]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0xb8]
xor r8d, r8d
lea rdx, str.Sophos_Folder_path
mov rcx, qword [rsp + 0xa0]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ebx, eax
test eax, eax
jne 0x1400b5eca
mov edx, dword [rsp + 0x90]
mov ecx, dword [rsp + 0xb8]
call fcn.1401338b0
mov r9d, dword [rsp + 0x90]
lea r8, str.Sophos_Folder_path
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x98]
call fcn.140134c10
lea rdx, [rsp + 0x30]
cmp qword [rsp + 0x48], 8
cmovae rdx, qword [rsp + 0x30]
lea rcx, str.SGVM_INSTALL_DIR
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, qword [rsp + 0x48]
cmp rdx, 8
jb 0x1400b5e14
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400b5e0e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400b5ee9
call fcn.1401853a0
nop
mov qword [rsp + 0x98], rdi
mov rcx, qword [rsp + 0xa0]
test rcx, rcx
je 0x1400b5e30
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.140185380
lea r11, [rsp + 0xd0]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
call fcn.1401b3c00
nop
call fcn.1401b3c00
nop
call fcn.1401b3c00
nop
lea rdx, str.Failed_to_open_registry_key
lea rcx, [rsp + 0x50]
call fcn.140010040
nop
lea rdx, [rsp + 0x50]
mov ecx, edi
call fcn.140030620
nop
lea rdx, str.Failed_to_get_registry_value_length
lea rcx, [rsp + 0x70]
call fcn.140010040
nop
lea rdx, [rsp + 0x70]
mov ecx, edi
call fcn.140030620
nop
call fcn.1401b3c00
nop
lea rdx, str.Failed_to_open_registry_key
lea rcx, [rsp + 0x70]
call fcn.140010040
nop
lea rdx, [rsp + 0x70]
mov ecx, esi
call fcn.140030620
nop
lea rdx, str.Failed_to_get_registry_value_length
lea rcx, [rsp + 0x50]
call fcn.140010040
nop
lea rdx, [rsp + 0x50]
mov ecx, ebx
call fcn.140030620
nop
call fcn.1401b3c00
int3