Function at 0x18018a610
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x60]
sub rsp, 0x160
mov rax, qword [0x1803c1370]
xor rax, rsp
mov qword [rbp + 0x50], rax
mov r8, qword [rcx + 0x80]
xor edi, edi
mov esi, edx
mov rax, qword [r8 + 0x3b0]
mov r15, qword [r8 + 0x3f0]
mov r12, qword [r8 + 0x3f8]
mov eax, dword [rax + 0x18]
mov dword [rsp + 0x40], edx
mov r14, rcx
and eax, 2
mov qword [rsp + 0x58], r15
mov dword [rsp + 0x48], eax
test dl, 1
je 0x18018a6e5
cmp qword [rcx + 0xc8], rdi
je 0x18018a685
mov edi, 1
jmp 0x18018a6af
mov r8d, 0x113
lea rdx, str.D:_tinderboxwin_4.2_srclibsopenssl_0.9.8y_ssl_t1_enc.c
lea ecx, [r8 - 0x73]
call sym.VBoxRT.dll_CRYPTO_malloc
mov qword [r14 + 0xc8], rax
test rax, rax
je 0x18018a718
mov rcx, rax
call sym.VBoxRT.dll_EVP_CIPHER_CTX_init
cmp dword [r14], 0xfeff
mov rcx, qword [r14 + 0xc8]
mov qword [r14 + 0xd0], r12
mov qword [rsp + 0x68], rcx
je 0x18018a6d8
mov rax, qword [r14 + 0x80]
xor edx, edx
mov qword [rax + 8], rdx
mov rbx, qword [r14 + 0x80]
add rbx, 0x10
jmp 0x18018a763
cmp qword [rcx + 0xe0], rdi
je 0x18018a6f5
mov edi, 1
jmp 0x18018a72f
lea rdx, str.D:_tinderboxwin_4.2_srclibsopenssl_0.9.8y_ssl_t1_enc.c
mov r8d, 0x138
mov ecx, 0xa0
call sym.VBoxRT.dll_CRYPTO_malloc
mov qword [r14 + 0xe0], rax
test rax, rax
jne 0x18018a727
mov dword [rsp + 0x20], edi
mov r8d, 0x41
jmp 0x18018a894
mov rcx, rax
call sym.VBoxRT.dll_EVP_CIPHER_CTX_init
cmp dword [r14], 0xfeff
mov rcx, qword [r14 + 0xe0]
mov qword [r14 + 0xe8], r12
mov qword [rsp + 0x68], rcx
je 0x18018a758
mov rax, qword [r14 + 0x80]
xor edx, edx
mov qword [rax + 0x50], rdx
mov rbx, qword [r14 + 0x80]
add rbx, 0x58
test edi, edi
je 0x18018a76c
call sym.VBoxRT.dll_EVP_CIPHER_CTX_cleanup
mov rax, qword [r14 + 0x80]
mov rcx, r12
mov rdi, qword [rax + 0x3e8]
call sym.VBoxRT.dll_EVP_MD_size
mov rcx, r15
movsxd r13, eax
call sym.VBoxRT.dll_EVP_CIPHER_key_length
cmp dword [rsp + 0x48], 0
mov r15d, eax
je 0x18018a7f5
mov rax, qword [r14 + 0x80]
mov r8, qword [rax + 0x3b0]
mov edx, dword [r8 + 0x18]
and edx, 8
je 0x18018a7b5
mov ecx, 5
jmp 0x18018a7cb
mov eax, dword [r8 + 0x14]
xor ecx, ecx
and eax, 0x1c3f8000
cmp eax, 0x8000
sete cl
add ecx, 7
cmp r15d, ecx
jl 0x18018a7f5
test edx, edx
je 0x18018a7dc
mov r15d, 5
jmp 0x18018a7f5
mov eax, dword [r8 + 0x14]
xor r15d, r15d
and eax, 0x1c3f8000
cmp eax, 0x8000
sete r15b
add r15d, 7
mov rcx, qword [rsp + 0x58]
call sym.VBoxRT.dll_EVP_CIPHER_iv_length
mov r8d, eax
mov dword [rsp + 0x4c], eax
cmp esi, 0x12
je 0x18018a842
cmp esi, 0x21
je 0x18018a842
lea ecx, [r15 + r13*2]
add eax, r15d
lea r9, [rdi + r13]
movsxd r12, ecx
add ecx, eax
mov dword [rsp + 0x44], 0
movsxd rdx, ecx
add r12, rdi
add rdx, rdi
add ecx, r8d
lea rdi, str.server_write_key
mov qword [rsp + 0x50], rdx
jmp 0x18018a872
lea eax, [r13 + r13]
mov r9, rdi
mov dword [rsp + 0x44], 1
lea ecx, [rax + r15*2]
movsxd r12, eax
movsxd rax, ecx
add r12, rdi
lea ecx, [rcx + r8*2]
add rax, rdi
lea rdi, str.client_write_key
mov qword [rsp + 0x50], rax
mov rax, qword [r14 + 0x80]
mov qword [rsp + 0x60], r12
cmp ecx, dword [rax + 0x3e4]
jle 0x18018a8ac
mov dword [rsp + 0x20], 0
mov r8d, 0x44
xor r9d, r9d
mov edx, 0xd1
lea ecx, [r9 + 0x14]
call sym.VBoxRT.dll_ERR_put_error
xor eax, eax
jmp 0x18018ab60
mov r8, r13
mov rdx, r9
mov rcx, rbx
call sub.MSVCR100.dll_memcpy
cmp dword [rsp + 0x48], 0
je 0x18018aaef
mov rax, qword [rdi]
mov rcx, qword [rsp + 0x58]
lea rsi, [rbp - 0x60]
mov qword [rsp + 0x70], rax
mov rax, qword [rdi + 8]
mov qword [rsp + 0x78], rax
mov rax, qword [r14 + 0x80]
movups xmm0, xmmword [rax + 0xb8]
movaps xmmword [rbp - 0x80], xmm0
movups xmm1, xmmword [rax + 0xc8]
movaps xmmword [rbp - 0x70], xmm1
movups xmm0, xmmword [rax + 0x98]
movaps xmmword [rbp - 0x60], xmm0
movups xmm1, xmmword [rax + 0xa8]
movaps xmmword [rbp - 0x50], xmm1
call sym.VBoxRT.dll_EVP_CIPHER_key_length
mov rcx, qword [r14 + 0x158]
mov r12, qword [rcx + 0xe8]
mov rcx, qword [rcx + 0xe0]
movsxd r13, eax
lea rax, [rsp + 0x70]
mov dword [rsp + 0x30], r13d
lea r9, [rsp + 0x70]
sub esi, eax
mov eax, r15d
and r15d, 1
cdq
add esi, 0x20
sub eax, edx
mov rdx, qword [rsp + 0x60]
sar eax, 1
movsxd rbx, eax
lea rax, [rbp - 0x10]
lea rdi, [rdx + rbx]
mov qword [rsp + 0x28], rax
add ebx, r15d
mov r8d, ebx
mov dword [rsp + 0x20], esi
call fcn.18018a180
lea rax, [rbp + 0x30]
mov dword [rsp + 0x30], r13d
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x70]
mov r8d, ebx
mov rdx, rdi
mov rcx, r12
mov dword [rsp + 0x20], esi
call fcn.18018a180
xor r11d, r11d
test r13d, r13d
jle 0x18018a9b3
movzx eax, byte [rbp + r11 + 0x30]
inc r11
xor byte [rbp + r11 - 0x11], al
cmp r11, r13
jl 0x18018a9a0
movsxd r13, dword [rsp + 0x4c]
lea r12, [rbp - 0x10]
test r13d, r13d
jle 0x18018aaeb
mov rdx, qword [r14 + 0x80]
mov rcx, qword [r14 + 0x158]
movabs rax, 0x6b636f6c62205649
mov qword [rsp + 0x70], rax
mov rax, qword [rdx + 0xb8]
lea rbx, [rbp - 0x68]
mov qword [rsp + 0x78], rax
mov rax, qword [rdx + 0xc0]
lea esi, [r13 + r13]
mov qword [rbp - 0x80], rax
mov rax, qword [rdx + 0xc8]
mov dword [rsp + 0x30], esi
mov qword [rbp - 0x78], rax
mov rax, qword [rdx + 0xd0]
lea r9, [rsp + 0x70]
mov qword [rbp - 0x70], rax
mov rax, qword [rdx + 0x98]
xor r8d, r8d
mov qword [rbp - 0x68], rax
mov rax, qword [rdx + 0xa0]
mov qword [rbp - 0x60], rax
mov rax, qword [rdx + 0xa8]
mov qword [rbp - 0x58], rax
mov rax, qword [rdx + 0xb0]
lea rdx, [0x18032fffa]
mov qword [rbp - 0x50], rax
mov rdi, qword [rcx + 0xe8]
mov rcx, qword [rcx + 0xe0]
lea rax, [rsp + 0x70]
sub ebx, eax
lea rax, [rbp - 0x30]
mov qword [rsp + 0x28], rax
add ebx, 0x20
mov dword [rsp + 0x20], ebx
call fcn.18018a180
lea rax, [rbp + 0x10]
mov dword [rsp + 0x30], esi
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x70]
lea rdx, [0x18032fffa]
xor r8d, r8d
mov rcx, rdi
mov dword [rsp + 0x20], ebx
call fcn.18018a180
xor r11d, r11d
movsxd rcx, esi
test esi, esi
jle 0x18018aad3
nop word [rax + rax]
movzx eax, byte [rbp + r11 + 0x10]
inc r11
xor byte [rbp + r11 - 0x31], al
cmp r11, rcx
jl 0x18018aac0
cmp dword [rsp + 0x44], 0
mov esi, dword [rsp + 0x40]
je 0x18018aae4
lea rcx, [rbp - 0x30]
jmp 0x18018aaf4
lea rcx, [rbp + r13 - 0x30]
jmp 0x18018aaf4
mov esi, dword [rsp + 0x40]
mov rcx, qword [rsp + 0x50]
mov rax, qword [r14 + 0x128]
mov rdx, qword [rsp + 0x58]
and esi, 2
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x20], rcx
mov rcx, qword [rsp + 0x68]
mov r9, r12
xor r8d, r8d
mov dword [rax + 4], 0
call sym.VBoxRT.dll_EVP_CipherInit_ex
lea rcx, [rbp - 0x10]
mov edx, 0x20
call sym.VBoxRT.dll_OPENSSL_cleanse
lea rcx, [rbp + 0x30]
mov edx, 0x20
call sym.VBoxRT.dll_OPENSSL_cleanse
lea rcx, [rbp - 0x30]
mov edx, 0x20
call sym.VBoxRT.dll_OPENSSL_cleanse
lea rcx, [rbp + 0x10]
mov edx, 0x20
call sym.VBoxRT.dll_OPENSSL_cleanse
mov eax, 1
mov rcx, qword [rbp + 0x50]
xor rcx, rsp
call fcn.180227610
mov rbx, qword [rsp + 0x1b0]
add rsp, 0x160
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret