Function at 0x1400a62b0
Capabilities:
Read file on windows
Set registry value

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0xfd0]
mov eax, 0x10d0
call fcn.1400f9a10
sub rsp, rax
mov qword [rsp + 0x70], 0xfffffffffffffffe
mov qword [rsp + 0x1110], rbx
mov rax, qword [0x1401a4010]
xor rax, rsp
mov qword [rbp + 0xfc0], rax
mov qword [rsp + 0x60], r9
mov qword [rsp + 0x58], r8
mov rdi, rdx
mov qword [rsp + 0x68], rdx
mov qword [rsp + 0x78], rdx
xor edx, edx
mov r8d, 0x1000
lea rcx, [rbp - 0x40]
call fcn.1400daa40
xor ecx, ecx
mov r12d, ecx
mov ebx, ecx
mov dword [rsp + 0x50], ecx
mov r15d, ecx
xor eax, eax
mov qword [rbp - 0x78], rax
mov qword [rbp - 0x70], rax
mov qword [rbp - 0x68], rax
mov dword [rbp - 0x60], eax
mov qword [rbp - 0x80], rcx
mov ecx, 0x8000
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__set_fmode]
lea r8, [0x1401577e8]
mov rdx, qword [rdi]
lea rcx, [rbp - 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__wfopen_s]
mov r9d, eax
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
test eax, eax
je 0x1400a6390
mov rax, qword [rdi]
mov qword [rsp + 0x20], rax
mov r8d, 0x1e2
lea rcx, str._s__d__tfopen_s_ret_d_FilePath_s
call fcn.140065460
nop
lea r14d, [r12 - 1]
jmp 0x1400a6685
mov r9, qword [rdi]
mov r8d, 0x1e6
lea rcx, str._s__d_DAT_s
call fcn.140065460
xor r8d, r8d
xor edx, edx
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_ftell]
mov esi, eax
mov dword [rsp + 0x54], eax
mov r9, qword [rbp - 0x80]
mov edx, 1
lea r8d, [rdx + 0x1b]
lea rcx, [rbp - 0x78]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
lea r13d, [rsi - 0x1c]
mov r14d, 0xffffffff
test rax, rax
je 0x1400a666d
nop
xor eax, eax
mov qword [rbp - 0x58], rax
lea rdx, [rbp - 0x78]
lea rcx, [rbp - 0x58]
call fcn.140053bf0
nop
mov eax, dword [rbp - 0x64]
mov esi, eax
shr esi, 0x1f
and eax, 0xfffff
mov dword [rbp - 0x64], eax
mov edi, dword [rbp - 0x60]
cmp edi, 0x1000000
jae 0x1400a6630
cmp edi, 0xfff
jb 0x1400a64bb
cmp ebx, edi
jae 0x1400a646e
test r12, r12
je 0x1400a6443
mov rcx, r12
call fcn.1400d37cc
mov edi, dword [rbp - 0x60]
mov dword [rsp + 0x50], edi
lea ecx, [rdi + 2]
call fcn.1400d3e08
mov r12, rax
mov r9d, edi
mov r8d, 0x20b
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
lea rcx, str._s__d_new_HeapBufSize_d
call fcn.140065460
mov rbx, r12
mov r8d, 0x210
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
lea rcx, [0x140119e10]
call fcn.140065460
mov r8d, dword [rsp + 0x50]
add r8d, 2
xor edx, edx
mov rcx, r12
call fcn.1400daa40
mov r8d, 0x214
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
lea rcx, [0x140119e10]
call fcn.140065460
mov edi, dword [rbp - 0x60]
jmp 0x1400a64d0
lea rbx, [rbp - 0x40]
xor edx, edx
mov r8d, 0x1000
lea rcx, [rbp - 0x40]
call fcn.1400daa40
mov r8d, edi
mov r9, qword [rbp - 0x80]
mov edx, 1
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov ecx, dword [rbp - 0x60]
sub r13d, ecx
mov eax, dword [rbp - 0x64]
cmp eax, 0x10001
jne 0x1400a6531
mov eax, dword [rbx]
mov dword [rsp + 0x28], 4
mov r9d, 4
xor r8d, r8d
mov rdx, qword [rbp - 0x58]
test esi, esi
je 0x1400a6523
mov dword [rbp - 0x50], eax
lea rax, [rbp - 0x50]
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x58]
jmp 0x1400a658b
mov dword [rbp - 0x48], eax
lea rax, [rbp - 0x48]
mov qword [rsp + 0x20], rax
jmp 0x1400a6586
cmp eax, 0x10000
jne 0x1400a6564
mov rax, rcx
xor ecx, ecx
mov word [rax + rbx], cx
mov r8, rbx
mov rdx, qword [rbp - 0x58]
test esi, esi
je 0x1400a6558
mov rcx, qword [rsp + 0x58]
call fcn.14002a040
jmp 0x1400a6594
mov rcx, qword [rsp + 0x60]
call fcn.14002a040
jmp 0x1400a6594
cmp eax, 1
jne 0x1400a6597
mov dword [rsp + 0x28], ecx
lea r9d, [rax + 2]
xor r8d, r8d
mov rdx, qword [rbp - 0x58]
mov qword [rsp + 0x20], rbx
test esi, esi
mov rax, qword [rsp + 0x58]
jne 0x1400a658b
mov rax, qword [rsp + 0x60]
mov rcx, qword [rax]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegSetValueExW]
mov r15d, eax
mov r9, qword [rbp - 0x80]
mov edx, 1
lea r8d, [rdx + 0x1b]
lea rcx, [rbp - 0x78]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov rbx, rax
test rax, rax
jne 0x1400a65ba
sub r13d, 0x1c
call fcn.140065270
test eax, eax
je 0x1400a6603
mov eax, dword [rsp + 0x54]
mov dword [rsp + 0x40], eax
mov dword [rsp + 0x38], r13d
mov dword [rsp + 0x30], r15d
mov eax, dword [rbp - 0x60]
mov dword [rsp + 0x28], eax
mov rax, qword [rbp - 0x58]
mov qword [rsp + 0x20], rax
mov r9d, dword [rbp - 0x64]
mov r8d, 0x23b
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
lea rcx, str._s__d_Type_x_Key_s_DataSize_d_RegRet_d_RemindFileSize_d_FileSize_d
call fcn.140065460
nop
mov rdx, qword [rbp - 0x58]
add rdx, 0xffffffffffffffe8
mov eax, r14d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400a6621
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
test rbx, rbx
mov ebx, dword [rsp + 0x50]
jne 0x1400a63f0
jmp 0x1400a6668
mov r8d, 0x1fc
lea rdx, str.CRtkBssGen4PresetLoader::LoadPresetFromDATFile2ServiceRegStore
lea rcx, str._s__d_over_buffer_size
call fcn.140065460
nop
mov rdx, qword [rbp - 0x58]
add rdx, 0xffffffffffffffe8
mov eax, r14d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400a6668
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rdi, qword [rsp + 0x68]
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
test r12, r12
je 0x1400a6685
mov rcx, r12
call fcn.1400d37cc
nop
mov rdx, qword [rdi]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], r14d
sub r14d, 1
jg 0x1400a66a1
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [rbp + 0xfc0]
xor rcx, rsp
call fcn.1400d37a0
mov rbx, qword [rsp + 0x1110]
add rsp, 0x10d0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret