Function at 0x14002bff4
Capabilities:
Check if file exists
Create directory
Get common file path
Get file attributes
Get geographical location
Set registry value

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x618]
sub rsp, 0x6f0
mov rax, qword [0x1400502a8]
xor rax, rsp
mov qword [rbp + 0x5e0], rax
mov rdx, qword [rcx]
xor r13d, r13d
mov rbx, rcx
mov r15d, 1
test rdx, rdx
je 0x14002c044
mov rax, rdx
jmp 0x14002c049
call fcn.14002a0c0
test rax, rax
jne 0x14002c058
mov eax, 0x80004005
jmp 0x14002c460
test rdx, rdx
je 0x14002c062
mov rax, rdx
jmp 0x14002c06a
mov rcx, rbx
call fcn.14002a0c0
cmp dword [rax + 0x130], r13d
je 0x14002c07a
xor eax, eax
jmp 0x14002c460
test rdx, rdx
je 0x14002c084
mov rax, rdx
jmp 0x14002c08c
mov rcx, rbx
call fcn.14002a0c0
cmp qword [rax + 0x50], r13
je 0x14002c45d
test rdx, rdx
jne 0x14002c0a6
mov rcx, rbx
call fcn.14002a0c0
mov rdx, rax
mov rax, qword [rdx + 0x50]
movzx ecx, word [rax]
cmp cx, word [0x14003f4a0]
je 0x14002c45d
lea rax, [rbp + 0x3d0]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], rax
mov edx, 0x801c
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x14002c45d
lea rax, [0x14003e128]
mov qword [rsp + 0x78], r13
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0x58]
lea rax, [0x14003e120]
mov qword [rbp - 0x60], r13
mov qword [rbp - 0x68], rax
mov qword [rbp - 0x58], r13
call fcn.14003a4e4
call qword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
xor r9d, r9d
xor r8d, r8d
mov ecx, eax
mov esi, eax
lea r12d, [r9 + 0x5c]
mov edx, r12d
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
mov edx, eax
lea rcx, [rsp + 0x58]
mov r14d, eax
call fcn.14003a5a8
mov edi, eax
test eax, eax
js 0x14002c427
mov r9d, r14d
mov edx, r12d
mov r14, qword [rsp + 0x58]
mov ecx, esi
mov r8, r14
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jne 0x14002c173
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
test edi, edi
js 0x14002c427
mov rcx, qword [rbx]
test rcx, rcx
jne 0x14002c18e
mov rcx, rbx
call fcn.14002a0c0
mov rcx, rax
cmp qword [rcx], r13
lea r12, [0x14003f4a0]
mov rax, r12
lea r9, [rbp + 0x3d0]
cmovne rax, qword [rcx]
lea r8, str._sMicrosoftMedia_Player_s
mov edi, 0x208
mov qword [rsp + 0x20], rax
lea rcx, [rbp - 0x50]
mov edx, edi
call fcn.1400017b4
test eax, eax
js 0x14002c427
xor edx, edx
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov rcx, qword [rbx]
test rcx, rcx
jne 0x14002c1e9
mov rcx, rbx
call fcn.14002a0c0
mov rcx, rax
cmp qword [rcx], r13
lea r9, [rbp + 0x3d0]
mov rax, r12
mov qword [rsp + 0x28], r14
cmovne rax, qword [rcx]
lea r8, str._sMicrosoftMedia_Player_s_s
lea rcx, [rbp - 0x50]
mov qword [rsp + 0x20], rax
mov rdx, rdi
call fcn.1400017b4
test eax, eax
js 0x14002c427
xor edx, edx
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
or rdi, 0xffffffffffffffff
test eax, eax
jne 0x14002c2e9
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
lea eax, [rdi + 0x58]
test esi, esi
cmove esi, eax
cmp esi, 0xb7
je 0x14002c2e9
lea r8, [rbp - 0x50]
mov edx, 0x104
lea rcx, [rbp + 0x1c0]
call fcn.140001470
test eax, eax
js 0x14002c2cc
lea edx, [rdi + 0x5d]
lea rcx, [rbp + 0x1c0]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], r13w
jne 0x14002c279
test rax, rax
je 0x14002c2b6
cmp word [rbp + rax*2 + 0x1be], dx
jne 0x14002c2b6
lea rcx, [rbp + 0x1c0]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], r13w
jne 0x14002c29c
test rax, rax
je 0x14002c2b6
mov word [rbp + rax*2 + 0x1be], r13w
jmp 0x14002c26f
lea rcx, [rbp + 0x1c0]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x14002c2cc
test al, 0x10
jne 0x14002c2e9
mov r9d, esi
lea r8, [rbp - 0x50]
lea rdx, str.ERROR:_Catalog_download_failed_because__S_could_not_be_created.__Error_0x_x._r_n
mov ecx, 2
call fcn.1400168a8
jmp 0x14002c427
mov esi, 0x208
lea r8, str.catalog.wmdb.lz
mov edx, esi
lea rcx, [rbp - 0x50]
call fcn.14000165c
test eax, eax
js 0x14002c427
mov rax, qword [rbx]
test rax, rax
jne 0x14002c318
mov rcx, rbx
call fcn.14002a0c0
mov rdx, qword [rax + 0x50]
lea r8, [rbp - 0x50]
mov rcx, rbx
call fcn.14002ad48
mov r15d, eax
test eax, eax
js 0x14002c413
mov rax, qword [rbx]
test rax, rax
jne 0x14002c343
mov rcx, rbx
call fcn.14002a0c0
cmp qword [rax], r13
lea r8, str.SoftwareMicrosoftMediaPlayerPreferencesContentPartners_s
mov rdx, rsi
lea rcx, [rbp + 0x1c0]
cmovne r12, qword [rax]
mov r9, r12
call fcn.1400017b4
test eax, eax
js 0x14002c3f7
mov qword [rsp + 0x40], r13
lea rax, [rsp + 0x50]
mov qword [rsp + 0x38], rax
lea rdx, [rbp + 0x1c0]
mov qword [rsp + 0x30], r13
xor r9d, r9d
mov dword [rsp + 0x28], 2
xor r8d, r8d
mov rcx, 0xffffffff80000001
mov dword [rsp + 0x20], r13d
mov qword [rsp + 0x50], r13
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x14002c3f7
lea rax, [rbp - 0x50]
inc rdi
cmp word [rax + rdi*2], r13w
jne 0x14002c3b3
mov rcx, qword [rsp + 0x50]
lea eax, [rdi*2 + 2]
mov dword [rsp + 0x28], eax
lea rdx, str.CatalogPath
lea rax, [rbp - 0x50]
mov r9d, 1
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rax, qword [rbx]
test rax, rax
jne 0x14002c407
mov rcx, rbx
call fcn.14002a0c0
mov dword [rax + 0x130], 1
jmp 0x14002c427
mov r8d, eax
lea rdx, str.ERROR:_Catalog_download_failed:_0x_x._r_n
mov ecx, 2
call fcn.1400168a8
lea rcx, [rsp + 0x58]
call fcn.14003aa74
lea rax, [0x14003e128]
lea rcx, [rbp - 0x68]
mov qword [rsp + 0x70], rax
call fcn.14002c694
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x14002c45d
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x14003f118]
mov eax, r15d
mov rcx, qword [rbp + 0x5e0]
xor rcx, rsp
call fcn.14003c810
lea r11, [rsp + 0x6f0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret