Function at 0x140061a90
Capabilities:
Check if file exists
Get file attributes
Read file on windows
Set file attributes

Disassembly:
mov r11, rsp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x7d0
mov qword [rsp + 0x70], 0xfffffffffffffffe
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rbp
mov qword [r11 + 0x20], rsi
mov rax, qword [0x14042d950]
xor rax, rsp
mov qword [rsp + Ordinal_1986], rax
mov rdi, rcx
mov qword [rsp + 0x68], rcx
xor r13d, r13d
mov r12d, r13d
mov word [r11 - 0x348], r12w
xor edx, edx
mov r8d, 0xfe
lea rcx, [r11 - 0x346]
call sub.ntdll.dll_memset
mov word [rsp + 0x5b0], r12w
xor edx, edx
mov r8d, 0x206
lea rcx, [rsp + 0x5b2]
call sub.ntdll.dll_memset
call fcn.140049400
mov r15, rax
call fcn.1400494c0
cmp dword [0x140424488], r13d
jne 0x140061b3f
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x20]
test eax, eax
jne 0x140061b3f
mov rcx, rdi
call fcn.140060c60
jmp 0x140061b46
mov dword [0x140424488], r13d
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
mov r14, rax
test rax, rax
je 0x14006240b
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
mov rdx, rax
test rax, rax
je 0x14006240b
test r12d, r12d
jne 0x140061f4f
mov rax, qword [rdx]
mov rcx, rdx
call qword [rax + 0x78]
mov rbp, rax
test rax, rax
je 0x140061f31
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x30]
mov rdi, rax
test rax, rax
je 0x140061f31
test r12d, r12d
jne 0x140061f31
mov rdx, qword [rdi]
mov rcx, rdi
call qword [rdx + 0x48]
cmp eax, 2
je 0x140061bf5
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
cmp eax, 3
je 0x140061bf5
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
test eax, eax
je 0x140061bf5
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
cmp eax, 1
je 0x140061bf5
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
cmp eax, 4
jne 0x140061f1b
xor edx, edx
mov r8d, 0x100
lea rcx, [rsp + 0x4b0]
call sub.ntdll.dll_memset
mov rdx, qword [rdi]
mov rcx, rdi
call qword [rdx + 0x30]
mov rbx, rax
mov rsi, qword [r15]
mov rdx, qword [rdi]
mov rcx, rdi
call qword [rdx + 0x38]
mov rdi, rax
mov rdx, qword [rbx]
mov rcx, rbx
call qword [rdx + 0x50]
mov r9d, eax
mov qword [rsp + 0x20], rdi
mov r8d, 0x80
lea rdx, [rsp + 0x4b0]
mov rcx, r15
call qword [rsi + 0x58]
test eax, eax
je 0x140061f1b
xor edx, edx
mov r8d, 0x208
lea rcx, [rsp + 0x5b0]
call sub.ntdll.dll_memset
lea r9, str.AMTAG.BIN
lea r8, [rsp + 0x4b0]
lea rdx, [0x1402e2ad0]
lea rcx, [rsp + 0x5b0]
call qword [sym.imp.MSVCR80.dll__swprintf]
mov edx, 0x80
lea rcx, [rsp + 0x5b0]
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea rcx, [rsp + 0x5b0]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x140061f08
xor edx, edx
lea r12d, [rdx + 1]
mov r8d, 0x400
lea rcx, [rsp + 0x90]
call sub.ntdll.dll_memset
mov qword [rsp + 0x30], r13
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [r12 + 2]
lea rcx, [rsp + 0x5b0]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x140061ddf
call fcn.140049470
mov rbx, rax
xor edx, edx
lea r8d, [r12 + 0x7f]
lea rcx, [0x140433bd0]
call sub.ntdll.dll_memset
lea edx, [rsi + 0x5d]
lea rcx, str...manager.cpp
call qword [sym.imp.ntdll.dll_strrchr]
mov rdi, rax
test rax, rax
jne 0x140061d46
mov r8, r13
jmp 0x140061dcf
mov byte [rsp + Ordinal_1189], r13b
xor eax, eax
mov qword [rsp + Ordinal_1189], rax
mov word [rsp + reloc.MFC80U.DLL_Ordinal_1193], ax
mov byte [rsp + reloc.MFC80U.DLL_Ordinal_1195], al
mov r8d, Ordinal_355
lea rdx, [0x1402dfd08]
lea rcx, [rsp + 0x4a0]
call qword [sym.imp.ntdll.dll_sprintf]
lea rdx, [rdi + 1]
lea r8, [0x140433bd0]
mov rcx, r8
sub rcx, rdx
movzx eax, byte [rdx]
mov byte [rdx + rcx], al
add rdx, r12
test al, al
jne 0x140061d93
mov rdi, r8
xor eax, eax
or rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
lea rdx, [rsp + 0x4a0]
xor ecx, ecx
nop
nop
nop
movzx eax, byte [rdx + rcx]
mov byte [rdi + rcx - 1], al
add rcx, r12
test al, al
jne 0x140061dc0
mov rax, qword [rbx]
lea rdx, str._s:_Open_config_file_failed.
mov rcx, rbx
call qword [rax + 0x10]
mov dword [rsp + 0x40], r13d
cmp rsi, 0xffffffffffffffff
je 0x140061e19
mov qword [rsp + 0x20], r13
lea r9, [rsp + 0x40]
mov r8d, 0x400
lea rdx, [rsp + 0x90]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [rsp + 0x40], 0x400
je 0x140061eff
call fcn.140049470
mov rbx, rax
xor edx, edx
mov r8d, 0x80
lea rcx, [0x140433bd0]
call sub.ntdll.dll_memset
mov edx, 0x5c
lea rcx, str...manager.cpp
call qword [sym.imp.ntdll.dll_strrchr]
mov rdi, rax
test rax, rax
jne 0x140061e57
mov r8, r13
jmp 0x140061eef
mov byte [rsp + Ordinal_1173], r13b
xor eax, eax
mov qword [rsp + Ordinal_1173], rax
mov word [rsp + 0x499], ax
mov byte [rsp + 0x49b], al
mov r8d, Ordinal_362
lea rdx, [0x1402dfd08]
lea rcx, [rsp + 0x490]
call qword [sym.imp.ntdll.dll_sprintf]
lea rdx, [rdi + 1]
lea r8, [0x140433bd0]
mov rcx, r8
sub rcx, rdx
nop
nop
nop
movzx eax, byte [rdx]
mov byte [rdx + rcx], al
add rdx, r12
test al, al
jne 0x140061eb0
mov rdi, r8
xor eax, eax
or rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
lea rdx, [rsp + 0x490]
xor ecx, ecx
nop
nop
nop
nop
movzx eax, byte [rdx + rcx]
mov byte [rdi + rcx - 1], al
add rcx, r12
test al, al
jne 0x140061ee0
mov rax, qword [rbx]
lea rdx, str._s:_The_config_file_dirty.
mov rcx, rbx
call qword [rax + 0x10]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, 2
lea rcx, [rsp + 0x5b0]
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov rax, qword [rbp]
mov rcx, rbp
call qword [rax + 0x38]
mov rdi, rax
test rax, rax
jne 0x140061ba3
mov rax, qword [r14]
mov rcx, r14
call qword [rax + 0x20]
mov rdx, rax
test rax, rax
jne 0x140061b70
test r12d, r12d
je 0x14006240b
mov qword [rsp + 0x50], r13
mov qword [rsp + 0x58], r13
mov qword [rsp + 0x60], r13
mov r12, r13
mov rbp, r13
mov rdi, qword [rsp + 0x68]
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
mov r14, rax
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
test rax, rax
je 0x140062109
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x78]
mov rsi, rax
test rax, rax
je 0x1400620f2
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x30]
mov rbx, rax
mov qword [rsp + 0x40], rax
test rax, rax
je 0x1400620f2
nop
nop
nop
mov rdx, qword [rbx]
mov rcx, rbx
call qword [rdx + 0xc8]
test eax, eax
jne 0x140061fe4
mov rdx, qword [rbx]
mov rcx, rbx
call qword [rdx + 0xd0]
test eax, eax
je 0x1400620d8
mov rdx, qword [rsp + 0x58]
mov rdi, qword [rsp + 0x50]
test rdi, rdi
je 0x14006201f
mov rcx, rdx
sub rcx, rdi
sar rcx, 3
mov rax, qword [rsp + 0x60]
sub rax, rdi
sar rax, 3
cmp rcx, rax
jae 0x14006201f
mov qword [rdx], rbx
lea rax, [rdx + 8]
mov qword [rsp + 0x58], rax
jmp 0x1400620d8
mov rbx, rdx
cmp rdi, rdx
jbe 0x140062037
call qword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
mov rdx, qword [rsp + 0x58]
mov rdi, qword [rsp + 0x50]
lea rax, [rsp + 0x48]
mov qword [rsp + Ordinal_1173], rax
mov qword [rsp + 0x498], rbx
test rdi, rdi
je 0x140062071
mov rax, rdx
sub rax, rdi
sar rax, 3
je 0x140062071
cmp rdi, rdx
jbe 0x140062068
call qword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
sub rbx, rdi
sar rbx, 3
jmp 0x140062074
mov rbx, r13
movaps xmm0, xmmword [rsp + 0x490]
movdqa xmmword [rsp + 0x80], xmm0
lea r9, [rsp + 0x40]
mov r8d, 1
lea rdx, [rsp + 0x80]
lea rcx, [rsp + 0x48]
call fcn.140007440
mov rdx, qword [rsp + 0x50]
mov rdi, rdx
mov rax, qword [rsp + 0x58]
cmp rdx, rax
jbe 0x1400620c4
call qword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
mov rax, qword [rsp + 0x58]
mov rdx, qword [rsp + 0x50]
lea rcx, [rdi + rbx*8]
cmp rcx, rax
ja 0x1400620d2
cmp rcx, rdx
jae 0x1400620d8
call qword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
mov rax, qword [rsi]
mov rcx, rsi
call qword [rax + 0x38]
mov rbx, rax
mov qword [rsp + 0x40], rax
test rax, rax
jne 0x140061fc0
mov rax, qword [r14]
mov rcx, r14
call qword [rax + 0x20]
test rax, rax
jne 0x140061f87
mov rdi, qword [rsp + 0x68]
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
mov rsi, rax
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
test rax, rax
je 0x1400623f2
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x78]
mov rbx, rax
test rax, rax
je 0x140062324
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x30]
mov rdi, rax
test rax, rax
je 0x140062324
mov rax, qword [rdi]
xor edx, edx
mov rcx, rdi
call qword [rax + 0x180]
mov rax, qword [rdi]
xor edx, edx
mov rcx, rdi
call qword [rax + reloc.MFC80U.DLL_Ordinal_376]
mov rdx, qword [rdi]
mov rcx, rdi
call qword [rdx + 0x48]
cmp eax, 0xb
je 0x14006230f
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
cmp eax, 5
je 0x14006230f
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x48]
cmp eax, 0xc
je 0x14006230f
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x30]
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x60]
movzx edx, byte [rsp + 0x90]
cmp edx, eax
jne 0x140062259
test dl, dl
jne 0x14006220d
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x30]
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x28]
cmp dword [rsp + 0x91], eax
jne 0x140062259
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x38]
cmp qword [rsp + 0x95], rax
jne 0x140062259
mov rax, qword [rdi]
mov edx, 1
mov rcx, rdi
call qword [rax + reloc.MFC80U.DLL_Ordinal_376]
mov rbp, rdi
jmp 0x140062259
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0xb0]
lea rcx, [rsp + 0x91]
mov rdx, qword [rax + 0x78]
cmp rdx, qword [rcx]
jne 0x14006223c
mov rdx, qword [rax + 0x80]
cmp rdx, qword [rcx + 8]
jne 0x14006223c
mov eax, r13d
jmp 0x140062241
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x140062259
mov rax, qword [rdi]
mov edx, 1
mov rcx, rdi
call qword [rax + reloc.MFC80U.DLL_Ordinal_376]
mov rbp, rdi
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x30]
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x60]
movzx edx, byte [rsp + 0x290]
cmp edx, eax
jne 0x14006230f
test dl, dl
jne 0x1400622c3
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x30]
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x28]
cmp dword [rsp + 0x291], eax
jne 0x14006230f
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x38]
cmp qword [rsp + 0x295], rax
jne 0x14006230f
mov rax, qword [rdi]
mov edx, 1
mov rcx, rdi
call qword [rax + 0x180]
mov r12, rdi
jmp 0x14006230f
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0xb0]
lea rcx, [rsp + 0x291]
mov rdx, qword [rax + 0x78]
cmp rdx, qword [rcx]
jne 0x1400622f2
mov rdx, qword [rax + 0x80]
cmp rdx, qword [rcx + 8]
jne 0x1400622f2
mov eax, r13d
jmp 0x1400622f7
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x14006230f
mov rax, qword [rdi]
mov edx, 1
mov rcx, rdi
call qword [rax + 0x180]
mov r12, rdi
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 0x38]
mov rdi, rax
test rax, rax
jne 0x140062151
mov rax, qword [rsi]
mov rcx, rsi
call qword [rax + 0x20]
test rax, rax
jne 0x140062127
test rbp, rbp
je 0x1400623f2
test r12, r12
je 0x1400623f2
mov esi, r13d
mov rbx, r13
nop
mov rdx, qword [rsp + 0x58]
mov rdi, qword [rsp + 0x50]
test rdi, rdi
jne 0x140062364
mov rcx, r13
jmp 0x14006236e
mov rcx, rdx
sub rcx, rdi
sar rcx, 3
movsxd rax, esi
cmp rax, rcx
jae 0x1400623bb
test rdi, rdi
je 0x140062387
sub rdx, rdi
sar rdx, 3
cmp rbx, rdx
jb 0x140062392
call qword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
mov rdi, qword [rsp + 0x50]
mov rdi, qword [rdi + rbx*8]
mov rax, qword [rdi]
xor edx, edx
mov rcx, rdi
call qword [rax + reloc.MFC80U.DLL_Ordinal_376]
mov rax, qword [rdi]
xor edx, edx
mov rcx, rdi
call qword [rax + 0x180]
add esi, 1
add rbx, 1
jmp 0x140062350
mov rax, qword [rbp]
mov edx, 1
mov rcx, rbp
call qword [rax + Ordinal_403]
mov rax, qword [rbp]
mov edx, 1
mov rcx, rbp
call qword [rax + reloc.MFC80U.DLL_Ordinal_376]
mov rax, qword [r12]
mov edx, 1
mov rcx, r12
call qword [rax + 0x180]
nop
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x140062401
call sub.MFC80U.DLL_Ordinal_776
mov eax, 1
jmp 0x1400624ec
call fcn.140049470
mov rbx, rax
xor edx, edx
mov r8d, 0x80
lea rcx, [0x140433bd0]
call sub.ntdll.dll_memset
mov edx, 0x5c
lea rcx, str...manager.cpp
call qword [sym.imp.ntdll.dll_strrchr]
mov rdi, rax
test rax, rax
je 0x1400624d7
mov byte [rsp + Ordinal_1173], r13b
xor eax, eax
mov qword [rsp + Ordinal_1173], rax
mov word [rsp + 0x499], ax
mov byte [rsp + 0x49b], al
mov r8d, 0x172
lea rdx, [0x1402dfd08]
lea rcx, [rsp + 0x490]
call qword [sym.imp.ntdll.dll_sprintf]
lea rdx, [rdi + 1]
lea rcx, [0x140433bd0]
sub rcx, rdx
nop
movzx eax, byte [rdx]
mov byte [rdx + rcx], al
add rdx, 1
test al, al
jne 0x140062490
lea rdi, [0x140433bd0]
xor eax, eax
or rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
lea rdx, [rsp + 0x490]
xor ecx, ecx
nop
nop
nop
movzx eax, byte [rdx + rcx]
mov byte [rdi + rcx - 1], al
add rcx, 1
test al, al
jne 0x1400624c0
lea r13, [0x140433bd0]
mov rax, qword [rbx]
mov r8, r13
lea rdx, str._s:_Not_find_tag_file.
mov rcx, rbx
call qword [rax + 0x10]
xor eax, eax
mov rcx, qword [rsp + 0x7c0]
xor rcx, rsp
call fcn.140161080
lea r11, [rsp + 0x7d0]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret