Function at 0x140031bd0
Capabilities:
Encode data using xor

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xd0
mov qword [rbp + 7], 0xfffffffffffffffe
mov qword [rsp + 0x118], rbx
mov rax, qword [0x140320c20]
xor rax, rsp
mov qword [rbp + 0x1f], rax
mov rdi, r8
mov r14, rdx
mov rsi, rcx
lea rbx, [rcx + 0x18]
mov qword [rbp + 0x17], rbx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
nop
mov r11, qword [rsi + 0x10]
test r11, r11
je 0x140031ec1
mov rax, qword [rdi + 8]
sub rax, qword [rdi]
sar rax, 3
cmp rax, 6
ja 0x140031ec1
mov rax, qword [rdi + 0x20]
sub rax, qword [rdi + 0x18]
sar rax, 5
cmp rax, 4
ja 0x140031ec1
movdqa xmm0, xmmword [0x14029faf0]
movdqa xmmword [rbp - 0x59], xmm0
movdqa xmm1, xmmword [0x14029fd50]
movdqa xmmword [rbp - 0x49], xmm1
movdqa xmm0, xmmword [0x14029fb80]
movdqa xmmword [rbp - 0x39], xmm0
movdqa xmm1, xmmword [0x14029fb30]
movdqa xmmword [rbp - 0x29], xmm1
movdqa xmm0, xmmword [0x14029fd90]
movdqa xmmword [rbp - 0x19], xmm0
mov dword [rbp - 9], 0x27003d84
mov dword [rbp - 5], 0xa8c44c77
mov dword [rbp - 1], 0xbb8c0
xor r15d, r15d
mov r10d, r15d
mov r9d, r15d
movabs r12, 0x2492492492492493
lea rsi, [0x140000000]
movabs r13, 0xcccccccccccccccd
nop dword [rax]
nop word [rax + rax]
lea r8, [rbp - 0x59]
add r8, r9
mov rax, r12
mul r9
mov rax, r9
sub rax, rdx
shr rax, 1
add rax, rdx
shr rax, 2
imul rax, rax, 7
mov rcx, r9
sub rcx, rax
mov rax, r13
mul r9
shr rdx, 2
lea rax, [rdx + rdx*4]
sub r9, rax
movzx eax, byte [rcx + rsi + 0x290058]
add al, byte [r9 + rsi + 0x290050]
add al, r10b
xor byte [r8], al
inc r10d
movsxd r9, r10d
cmp r9, 0x5b
jb 0x140031ce0
mov qword [rbp + 0xf], r15
mov qword [rsp + 0x30], r15
lea rax, [rbp + 0xf]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r15
mov r9d, 1
or r8d, 0xffffffff
lea rdx, [rbp - 0x59]
mov rcx, r11
call fcn.140090ca0
test eax, eax
jne 0x140031ec1
mov r8, r14
lea edx, [rax + 1]
mov rcx, qword [rbp + 0xf]
call fcn.14005d160
xor ecx, ecx
call fcn.140224720
mov r8, rax
mov edx, 2
mov rcx, qword [rbp + 0xf]
call fcn.14005d160
mov rsi, r15
mov qword [rbp - 0x69], 6
mov rcx, qword [rdi + 8]
sub rcx, qword [rdi]
sar rcx, 3
mov qword [rbp - 0x61], rcx
lea rax, [rbp - 0x69]
lea rdx, [rbp - 0x61]
cmp rcx, 6
cmovbe rax, rdx
cmp qword [rax], r15
jbe 0x140031e0a
mov qword [rbp - 0x69], 6
nop dword [rax]
mov r8, qword [rdi]
lea edx, [rsi + 3]
mov r8, qword [r8 + rsi*8]
mov rcx, qword [rbp + 0xf]
call fcn.14005d160
inc rsi
mov rcx, qword [rdi + 8]
sub rcx, qword [rdi]
sar rcx, 3
mov qword [rbp - 0x61], rcx
lea rax, [rbp - 0x69]
lea rdx, [rbp - 0x61]
cmp rcx, 6
cmovbe rax, rdx
cmp rsi, qword [rax]
jb 0x140031dd0
mov rsi, r15
mov qword [rbp - 0x61], 4
mov rcx, qword [rdi + 0x20]
sub rcx, qword [rdi + 0x18]
sar rcx, 5
mov qword [rbp - 0x69], rcx
lea rax, [rbp - 0x61]
lea rdx, [rbp - 0x69]
cmp rcx, 4
cmovbe rax, rdx
cmp qword [rax], r15
jbe 0x140031eaa
mov qword [rbp - 0x61], 4
mov r14, r15
nop word [rax + rax]
mov r8, qword [rdi + 0x18]
add r8, r14
mov rax, qword [r8 + 0x10]
cmp qword [r8 + 0x18], 0x10
jb 0x140031e65
mov r8, qword [r8]
lea edx, [rsi + 9]
mov byte [rsp + 0x28], 1
mov qword [rsp + 0x20], r15
mov r9d, eax
mov rcx, qword [rbp + 0xf]
call fcn.14005cf40
inc rsi
add r14, 0x20
mov rcx, qword [rdi + 0x20]
sub rcx, qword [rdi + 0x18]
sar rcx, 5
mov qword [rbp - 0x69], rcx
lea rax, [rbp - 0x61]
lea rdx, [rbp - 0x69]
cmp rcx, 4
cmovbe rax, rdx
cmp rsi, qword [rax]
jb 0x140031e50
mov rcx, qword [rbp + 0xf]
call fcn.14005b950
mov rcx, qword [rbp + 0xf]
call fcn.14005ab60
mov dil, 1
jmp 0x140031ec4
xor dil, dil
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
movzx eax, dil
mov rcx, qword [rbp + 0x1f]
xor rcx, rsp
call fcn.140215090
mov rbx, qword [rsp + 0x118]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret