Function at 0x140043580
Capabilities:
Check if file exists
Get file attributes
Query or enumerate registry value

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 - 0x37]
sub rsp, 0x90
mov rax, qword [0x140063010]
xor rax, rsp
mov qword [rbp + 0x27], rax
mov r8d, 0x104
lea r13, [0x1400654d0]
mov rdx, r13
lea rcx, [0x140000000]
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x140043818
mov rcx, r13
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea rax, str.skinltr_
mov qword [rbp + 0xf], rax
lea rax, str..._skinltr_
mov qword [rbp + 0x17], rax
lea rcx, str.skin_
mov qword [rbp + 0x1f], rcx
lea rax, str.skin_rtl_
mov qword [rbp - 9], rax
lea rax, str..._skin_rtl_
mov qword [rbp - 1], rax
mov qword [rbp + 7], rcx
xor r12d, r12d
mov qword [rbp - 0x11], r12
mov dword [rbp - 0x19], 4
mov dword [rbp - 0x29], r12d
lea rax, [rbp - 0x11]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, str..DEFAULTSoftwareSetID
mov rcx, 0xffffffff80000003
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140043696
lea rax, [rbp - 0x19]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x29]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea rdx, [0x1400549b8]
mov rcx, qword [rbp - 0x11]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ecx, dword [rbp - 0x29]
test eax, eax
cmovne ecx, r12d
mov dword [rbp - 0x29], ecx
mov rcx, qword [rbp - 0x11]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea r14, [rbp - 9]
lea rax, [rbp + 0xf]
cmp dword [rbp - 0x29], 1
cmovne r14, rax
mov r15d, r12d
mov rsi, 0xffffffffffffffff
call fcn.1400027a0
test rax, rax
je 0x140043852
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rbp - 0x21], rax
cmp r13, 0x10000
jae 0x1400436e7
movzx edx, r13w
lea rcx, [rbp - 0x21]
call fcn.140002020
jmp 0x14004370c
mov rax, rsi
nop word [rax + rax]
inc rax
cmp word [r13 + rax*2], 0
jne 0x1400436f0
mov r8d, eax
mov rdx, r13
lea rcx, [rbp - 0x21]
call fcn.1400023d0
nop
mov rbx, qword [rbp - 0x21]
mov ecx, 1
sub ecx, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, 0x104
or eax, ecx
jge 0x140043736
mov edx, 0x104
lea rcx, [rbp - 0x21]
call fcn.1400022b0
mov rbx, qword [rbp - 0x21]
mov rdx, qword [r14]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
test eax, eax
je 0x1400437fe
test rbx, rbx
jne 0x140043754
mov eax, r12d
jmp 0x140043769
movsxd rdx, dword [rbx - 0xc]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsnlen]
test eax, eax
js 0x140043847
cmp eax, dword [rbx - 0xc]
jg 0x140043847
mov dword [rbx - 0x10], eax
mov eax, eax
mov word [rbx + rax*2], r12w
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1400437bd
mov eax, esi
lock xadd dword [rbx - 8], eax
sub eax, 1
jg 0x1400437a7
lfence
mov rcx, qword [rbx - 0x18]
mov rax, qword [rcx]
lea rdx, [rbx - 0x18]
call qword [rax + 8]
inc r15d
add r14, 8
cmp r15d, 3
jb 0x1400436b0
mov eax, r12d
jmp 0x14004381a
mov r8, rbx
mov edx, 0x104
mov rcx, r13
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
nop
lea rdx, [rbx - 0x18]
lock xadd dword [rdx + 0x10], esi
sub esi, 1
jg 0x1400437e9
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
lea rdx, str.images_2_
mov rcx, r13
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
mov r12d, eax
jmp 0x14004381a
lea rdx, [rbx - 0x18]
lock xadd dword [rdx + 0x10], esi
sub esi, 1
jg 0x140043818
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
xor eax, eax
mov rcx, qword [rbp + 0x27]
xor rcx, rsp
call fcn.140045c20
lea r11, [rsp + 0x90]
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
mov ecx, 0x80070057
call fcn.140002900
nop
mov ecx, 0x80004005
call fcn.140002900
int3