Function at 0x140058f50
Capabilities:
Encode data using xor

Disassembly:
push rbp
push rbx
push rdi
lea rbp, [rsp - 0xf70]
mov eax, 0x1070
call fcn.1400810b0
sub rsp, rax
mov rax, qword [0x1400a0040]
xor rax, rsp
mov qword [rbp + 0xf60], rax
mov rdi, r9
mov rbx, r8
test r8, r8
je 0x14005916b
mov r9d, 0x1000
lea rdx, [rsp + 0x60]
call fcn.1400557a0
xor edx, edx
test al, al
jne 0x140059054
mov dword [rsp + 0x20], 0xd729d758
mov r8d, 0x28fd
mov dword [rsp + 0x24], 0xd726d758
mov dword [rsp + 0x28], 0xd769d744
mov dword [rsp + 0x2c], 0xd72dd767
mov dword [rsp + 0x30], 0xd72cd77f
mov dword [rsp + 0x34], 0xd76bd77f
mov dword [rsp + 0x38], 0xd774d76e
mov dword [rsp + 0x3c], 0xd77fd731
mov dword [rsp + 0x40], 0xd770d77c
mov dword [rsp + 0x44], 0xd77ad760
mov dword [rsp + 0x48], 0xd738d772
mov dword [rsp + 0x4c], 0xd77fd771
mov dword [rsp + 0x50], 0xd778d77a
mov dword [rsp + 0x54], 0xd76cd778
mov dword [rsp + 0x58], 0xd76c
mov byte [rsp + 0x5c], 1
nop word [rax + rax]
movzx eax, dx
sub ax, r8w
xor word [rsp + rdx*2 + 0x20], ax
inc rdx
cmp rdx, 0x1d
jb 0x140059030
mov byte [rsp + 0x5c], 0
lea rdx, [rsp + 0x20]
jmp 0x14005914f
movsxd rax, dword [rbp - 0x64]
lea rcx, [rsp + 0x60]
add rcx, rax
mov r9d, edx
movzx eax, word [rcx + 0x14]
lea r11, [rcx + 0x18]
movzx r10d, word [rcx + 6]
add r11, rax
test r10d, r10d
je 0x1400590bb
nop dword [rax + rax]
mov eax, r9d
lea rcx, [rax + rax*4]
cmp dword [r11 + rcx*8], 0x45474150
lea r8, [r11 + rcx*8]
jne 0x1400590b3
mov rax, 0xffffffffffffffff
nop dword [rax]
inc rax
cmp byte [r8 + rax], dl
jne 0x1400590a0
cmp rax, 4
je 0x140059187
inc r9d
cmp r9d, r10d
jb 0x140059080
mov dword [rsp + 0x20], 0xd729d758
mov r8d, 0x28fd
mov dword [rsp + 0x24], 0xd726d758
mov dword [rsp + 0x28], 0xd769d744
mov dword [rsp + 0x2c], 0xd72dd767
mov dword [rsp + 0x30], 0xd72cd77f
mov dword [rsp + 0x34], 0xd767d76b
mov dword [rsp + 0x38], 0xd774d761
mov dword [rsp + 0x3c], 0xd761d731
mov dword [rsp + 0x40], 0xd777d776
mov dword [rsp + 0x44], 0xd77fd761
mov dword [rsp + 0x48], 0xd776d778
mov word [rsp + 0x4c], dx
mov byte [rsp + 0x4e], 1
nop dword [rax]
nop word [rax + rax]
movzx eax, dx
sub ax, r8w
xor word [rsp + rdx*2 + 0x20], ax
inc rdx
cmp rdx, 0x16
jb 0x140059130
mov byte [rsp + 0x4e], 0
lea rdx, [rsp + 0x20]
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.14005d060
lea rdx, [0x14005d240]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
xor eax, eax
mov rcx, qword [rbp + 0xf60]
xor rcx, rsp
call fcn.14007fe60
add rsp, 0x1070
pop rdi
pop rbx
pop rbp
ret
mov eax, dword [r8 + 0xc]
test eax, eax
je 0x1400590bb
mov ecx, dword [r8 + 8]
lea rax, [rsp + rax + 0x60]
test rax, rax
je 0x1400590bb
test ecx, ecx
je 0x1400590bb
test rdi, rdi
je 0x1400591b4
mov dword [rdi], ecx
lea rcx, [rsp + 0x60]
sub rax, rcx
add rax, rbx
jmp 0x14005916d