Function at 0x18001d190
Capabilities:
Check if file exists
Delete registry key
Get common file path
Get file attributes
Get session user name
Persist via run registry key
Query or enumerate registry value

Disassembly:
mov rax, rsp
push r13
sub rsp, 0x490
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
mov rax, qword [0x1800a7b78]
xor rax, rsp
mov qword [rsp + 0x480], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r8, [rsp + 0x48]
mov edx, 0x28
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x18001d22c
lea r8, [rsp + 0x54]
lea rdx, str.SeRestorePrivilege
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov esi, 1
mov dword [rsp + 0x50], esi
mov dword [rsp + 0x5c], 2
xor ebx, ebx
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rbx
xor r9d, r9d
lea r8, [rsp + 0x50]
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
jmp 0x18001d233
mov esi, 1
xor ebx, ebx
mov dword [rsp + 0x34], ebx
xor edx, edx
mov r8d, 0x94
lea rcx, [rsp + 0x70]
call fcn.180059b10
mov dword [rsp + 0x70], 0x94
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x18001d379
cmp dword [rsp + 0x80], 2
jne 0x18001d379
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
mov r9d, esi
xor r8d, r8d
lea rdx, str.SoftwareMicrosoftWindowsCurrentVersionExplorerShell_Folders
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x18001d379
mov dword [rsp + 0x30], 0x104
lea rax, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x150]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea rdx, str.AppData
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x18001d356
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x150]
repne scasb al, byte [rdi]
not rcx
sub rcx, 2
mov dword [rsp + 0x30], ecx
mov eax, ecx
movzx ecx, byte [rsp + rax + 0x150]
lea r13, [0x180087722]
lea r12, [0x18008736c]
mov rax, r12
cmp cl, 0x5c
cmove rax, r13
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x150]
lea r8, str._s_sDMCache
mov edx, 0x104
lea rcx, [rsp + 0x260]
call fcn.18005ac08
lea rcx, [rsp + 0x260]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
cmovne ebx, esi
mov dword [rsp + 0x34], ebx
jmp 0x18001d364
lea r13, [0x180087722]
lea r12, [0x18008736c]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
jne 0x18001d492
jmp 0x18001d387
lea r13, [0x180087722]
lea r12, [0x18008736c]
mov edx, 0x104
lea rcx, [rsp + 0x150]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
je 0x18001d5c0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x150]
repne scasb al, byte [rdi]
not rcx
sub rcx, 2
mov dword [rsp + 0x30], ecx
mov eax, ecx
mov rcx, r12
cmp byte [rsp + rax + 0x150], 0x5c
cmove rcx, r13
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x150]
lea r8, str._s_sDMCache
mov edx, 0x104
lea rcx, [rsp + 0x260]
call fcn.18005ac08
cmp dword [rsp + 0x80], 2
jne 0x18001d477
mov dword [rsp + 0x38], 0x40
lea rdx, [rsp + 0x38]
lea rcx, [rsp + 0x110]
call qword [sym.imp.ADVAPI32.dll_GetUserNameA]
test eax, eax
jne 0x18001d434
lea r8, str.default_user
lea edx, [rax + 0x40]
lea rcx, [rsp + 0x110]
call fcn.18005ac08
mov eax, dword [rsp + 0x30]
cmp byte [rsp + rax + 0x150], 0x5c
cmove r12, r13
lea rax, [rsp + 0x110]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r12
lea r9, [rsp + 0x150]
lea r8, str._s_sDMCache_s
mov edx, 0x104
lea rcx, [rsp + 0x260]
call fcn.18005ac08
lea rcx, [rsp + 0x260]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x18001d5c0
mov dword [rsp + 0x34], esi
lea r9, [rsp + 0x260]
lea r8, str._s_settings.bak
mov edx, 0x104
lea rcx, [rsp + 0x370]
call fcn.18005ac08
lea rcx, [rsp + 0x370]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x18001d5be
cmp dword [rsp + 0x80], 2
jne 0x18001d4f1
xor r8d, r8d
lea rdx, [rsp + 0x370]
mov rcx, qword [0x1800a9550]
call qword [sym.imp.ADVAPI32.dll_RegRestoreKeyA]
jmp 0x18001d571
lea r8, [rsp + 0x370]
lea rdx, str.idmtmp
mov rcx, 0xffffffff80000003
call qword [sym.imp.ADVAPI32.dll_RegLoadKeyA]
test eax, eax
jne 0x18001d55d
lea rcx, str.shlwapi.dll
call fcn.18001c060
mov rdi, rax
test rax, rax
je 0x18001d55d
lea rdx, str.SHCopyKeyA
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18001d554
xor r9d, r9d
mov r8, qword [0x1800a9550]
lea rdx, str.idmtmp
mov rcx, 0xffffffff80000003
call rax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
lea rdx, str.idmtmp
mov rcx, 0xffffffff80000003
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
lea rcx, str.C:Program_FilesSpyhunter
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x18001d5a1
mov r9d, 0x10000
lea r8, str.Intenet_Download_Manager
lea rdx, str.Internet_Download_Manager_detected_that_its_registry_keys_had_been_damaged_since_the_last_run._Its_possible_that_you_run_a_flaky_spyware_remover_program_like_Spyhunter_which_corrupted_system_registry._Internet_Download_Manager_will_try_to_restore_all_damaged_data__but_some_data_may_remain_corrupted.
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxA]
jmp 0x18001d5be
mov r9d, 0x10000
lea r8, str.Intenet_Download_Manager
lea rdx, str.Internet_Download_Manager_detected_that_its_registry_keys_had_been_damaged_since_the_last_run._Its_possible_that_you_run_a_flaky_spyware_remover_program_which_corrupted_system_registry._Internet_Download_Manager_will_try_to_restore_all_damaged_data__but_some_data_may_remain_corrupted.
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxA]
nop
jmp 0x18001d5c0
mov rcx, qword [rsp + 0x480]
xor rcx, rsp
call fcn.1800590c0
lea r11, [rsp + 0x490]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov r12, qword [r11 + 0x28]
mov rsp, r11
pop r13
ret