Function at 0x140521010
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x58
mov r14, r9
mov esi, r8d
mov rbx, rdx
mov rdi, rcx
mov edx, r8d
and edx, 0x1f
cmp edx, 9
jbe 0x1405210a5
cmp edx, 0x11
jae 0x1405210d3
cmp edx, 0xc
jbe 0x140521128
cmp edx, 0xe
jbe 0x14052121c
cmp edx, 0x10
jne case.0x140521191.3
nop
movzx eax, byte [0x14077a076]
cmp al, 0xd0
je 0x140521788
mov dl, 0x47
lea rcx, [rsp + 0x30]
lea r15, [rsp + 0x28]
mov al, 0xe7
lock cmpxchg byte [0x14077a076], dl
je 0x140521762
test sil, sil
js 0x1405216a4
cmp al, 0xd0
je 0x14052164a
test esi, 0x1000
je 0x140521077
jmp 0x1405217fb
cmp edx, 4
jbe 0x1405210fb
mov ecx, esi
cmp edx, 5
jne 0x1405211ce
nop
movzx eax, byte [0x14077a055]
cmp al, 0x65
mov esi, ecx
jne 0x1405213d6
lea rax, [0x14077a040]
jmp case.0x140521191.0
cmp edx, 0x14
jae 0x14052117b
cmp edx, 0x11
je 0x14052128d
cmp edx, 0x12
jne 0x1405212f4
call fcn.14059db40
movzx eax, al
jmp case.0x140521191.0
cmp edx, 2
jae 0x1405211a9
test edx, edx
je 0x1405213b7
nop
movzx eax, byte [0x14077a0a9]
cmp al, 0x5c
jne 0x140521894
lea rax, [0x14077a0a0]
jmp case.0x140521191.0
cmp edx, 0xa
je 0x14052125a
cmp edx, 0xc
jne 0x14052172d
lea rax, [0x1405e8c48]
mov qword [r14], rax
mov r15, qword [r14 + 0x60]
test r15, r15
je 0x1405216d3
nop
mov rcx, qword [r15 + 8]
test rcx, rcx
je 0x140521502
test sil, 0x40
jne 0x14052168e
mov al, 0x54
xchg byte [0x14077a122], al
lea rax, [rsp + 0x30]
jmp case.0x140521191.0
mov eax, 0xffffffff
add edx, 0xffffffec
lea rcx, [0x140612c4c]
movsxd rdx, dword [rcx + rdx*4]
add rdx, rcx
jmp rdx
test r14d, r14d
je 0x140521559
mov rcx, rbx
call fcn.1400954d0
jmp 0x140521730
je 0x1405212a9
cmp edx, 4
jne 0x140521309
mov r14d, ebx
mov edx, 5
mov ecx, 0xf35c4145
cmp edx, 5
je 0x1405210b5
cmp edx, 7
jbe 0x1405211eb
cmp edx, 9
jne 0x140521351
mov rcx, rdi
call fcn.14059bc90
mov eax, eax
jmp case.0x140521191.0
mov esi, 0x879fcac7
cmove esi, ecx
mov qword [rsp + 0x38], rbx
mov qword [rsp + 0x48], rdi
mov qword [rsp + 0x40], r14
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x28], rdi
cmp r14, rdi
jae 0x1405213c1
xor eax, eax
jmp 0x14052188b
cmp edx, 0xd
jne 0x140521498
test r14d, r14d
je 0x14052177a
test sil, 0x20
jne 0x1405217fb
mov rcx, rbx
call fcn.1400954d0
lea r8, [rsp + 0x38]
lea rax, [rsp + 0x28]
lea r10, [rsp + 0x20]
mov rdx, r10
mov r9, r8
jmp 0x140521383
nop
mov rax, qword [rdi + 8]
mov qword [rsp + 0x50], rax
movzx eax, byte [0x14077a122]
cmp al, 0x54
jne 0x1405214a4
mov rax, qword [rsp + 0x50]
test rax, rax
jne case.0x140521191.0
lea rax, [0x14077a110]
jmp case.0x140521191.0
test ebx, ebx
je 0x1405217fb
xor r15d, r15d
test esi, 0x100
je 0x1405216be
jmp 0x1405216cb
lea rax, [0x1405e9c88]
mov qword [rdi], rax
mov rcx, rdi
mov r8d, 0x21c486e5
call fcn.14051e420
lea rax, [0x1405e8c48]
mov qword [rdi], rax
mov r14, qword [rdi + 0x60]
test r14, r14
je 0x1405216fa
test sil, sil
js 0x14052177a
nop
mov rcx, qword [r14 + 8]
test rcx, rcx
jne 0x140521518
jmp 0x1405216f2
nop
movzx eax, byte [0x14077a095]
cmp al, 0x64
jne 0x140521849
jmp 0x14052177f
xor eax, eax
sub eax, dword [rdi - 4]
cdqe
lea rcx, [rdi + rax]
add rcx, 0xffffffffffffff68
mov r14, rcx
call fcn.1400c78a0
test ebx, ebx
je 0x1405214d9
test sil, 0x40
jne 0x14052177f
mov rcx, r14
call fcn.1400954d0
mov rax, r14
test esi, 0x200
je case.0x140521191.0
jmp 0x140521788
nop
mov rax, qword [r14 + 0x38]
mov r8, qword [rax]
test r8, r8
je 0x1405213b7
nop
mov rdx, qword [r14 + 0x50]
cmp dword [rdx], 0
jg 0x1405214cf
lea r9, [r14 + 0x38]
nop
mov r10, qword [r14 + 0x40]
mov r10, qword [r10]
test r10, r10
je 0x14052163e
mov esi, ecx
test sil, 0x40
je 0x14052177a
nop
test byte [r14 + 0x70], 4
jne 0x140521628
nop
mov rcx, qword [r14 + 0x68]
cmp rcx, r10
cmovb rcx, r10
cmp rcx, r8
jbe 0x140521671
add r14, 0x68
jmp 0x1405214c1
mov eax, 0xffffffff
jmp case.0x140521191.0
nop
mov qword [rsp + 0x20], rbx
test esi, 0x200
mov rax, rbx
jne 0x140521791
mov dl, 0x2a
lea rcx, [0x14077a040]
nop
mov al, 0xf6
lock cmpxchg byte [0x14077a055], dl
je 0x1405213f8
cmp al, 0x65
jne 0x1405213e0
mov rax, rcx
jmp case.0x140521191.0
test esi, 0x400
jne 0x1405216fa
mov ecx, 0x65106062
mov edx, 0x9aef9fb1
xor r8d, r8d
mov r9d, 0xcccccccd
lea r10, [0x14077a040]
lea r11, [0x140612b30]
nop word cs:[rax + rax]
mov ebx, edx
imul rbx, r9
shr rbx, 0x24
lea ebx, [rbx + rbx*4]
lea ebx, [rcx + rbx*4]
movzx ebx, byte [rbx + r11]
xor bl, 0x54
add byte [r8 + r10], bl
cmp r8, 0x14
je 0x14052154c
inc r8
dec ecx
inc edx
test sil, sil
jns 0x140521430
jmp 0x140521849
nop
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x48], rbx
mov qword [rsp + 0x40], r14
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], 0
test sil, sil
jns 0x140521755
jmp case.0x140521191.3
nop
lock inc dword [rdi + 8]
xor eax, eax
jmp case.0x140521191.0
test esi, 0x400
jne 0x1405214e1
lea rax, [rsp + 0x48]
lea rcx, [rsp + 0x20]
lea r9, [rsp + 0x40]
mov rdx, rax
mov r14, rax
nop
mov qword [r14], rcx
sub ecx, dword [rax]
mov dword [rdx], ecx
mov rax, qword [r9]
mov r8, qword [rax]
nop
movzx eax, byte [r8]
jmp case.0x140521191.0
mov rax, r14
jmp 0x140521868
mov dl, 0x81
mov al, 0xae
lock cmpxchg byte [0x14077a122], dl
je 0x140521568
test sil, 0x20
je 0x140521796
cmp al, 0x54
jne 0x1405214e3
jmp 0x140521273
test esi, 0x200
jne 0x1405216cb
lea r14, [rsp + 0x40]
lea rcx, [rsp + 0x28]
nop
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x140704440]
test rax, rax
je 0x1405216f2
nop
mov rcx, qword [rax]
mov r8, qword [rcx]
mov rcx, rax
mov edx, 1
mov rax, r8
call qword [0x140704440]
jmp 0x1405216f2
mov cl, 0x65
xchg byte [0x14077a055], cl
jmp 0x140521835
test sil, 0x40
jne 0x14052111c
jmp 0x14052177a
test esi, 0x800
jne 0x1405216d3
mov eax, 0xde7f89a7
mov edx, 0x2180766a
mov r8d, 1
mov r9d, 0xde7f89a8
mov r10d, 0x21807668
lea r11, [0x14077a110]
lea r15, [0x140612bd0]
mov r12d, edx
imul r12, r12, 0x38e38e39
shr r12, 0x22
lea r12d, [r12 + r12*8]
lea r12d, [rax + r12*2]
mov r13d, r10d
imul r13, r13, 0x38e38e39
shr r13, 0x22
lea r13d, [r13 + r13*8]
lea r13d, [r9 + r13*2]
movzx ebp, byte [r8 + r11 - 1]
movzx ecx, byte [r8 + r11]
xor bpl, byte [r13 + r15]
xor bpl, 0xcb
mov byte [r8 + r11 - 1], bpl
xor cl, byte [r12 + r15]
xor cl, 0xcb
mov byte [r8 + r11], cl
add eax, 0xfffffffe
add edx, 2
add r8, 2
add r9d, 0xfffffffe
add r10d, 2
cmp r8, 0x13
jne 0x14052159e
test sil, 0x40
mov rax, qword [rsp + 0x50]
jne 0x140521684
test rax, rax
mov cl, 0x54
xchg byte [0x14077a122], cl
jne case.0x140521191.0
jmp 0x140521281
mov eax, 0xffffffff
test sil, 0x20
jne case.0x140521191.0
xor eax, eax
jmp 0x1405217eb
xor edx, edx
mov eax, 0xffffffff
jmp 0x14052191c
test esi, 0x800
je 0x140521788
lea r9, [rsp + 0x30]
lea rax, [rsp + 0x48]
lea r8, [rsp + 0x48]
lea rdx, [rsp + 0x38]
mov ecx, esi
jmp 0x140521370
mov eax, 0xffffffff
test sil, sil
js 0x14052119c
jmp case.0x140521191.0
lea rcx, [rsp + 0x28]
lea r15, [rsp + 0x30]
nop
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x140704440]
mov rcx, rax
test rax, rax
je 0x1405216cb
nop
mov rax, qword [rcx]
mov rax, qword [rax]
mov edx, 1
call qword [0x140704440]
test esi, 0x100
jne 0x1405216cb
mov rcx, rdi
call fcn.1400954d0
jmp 0x1405217fb
mov rcx, r15
call fcn.1400954d0
test ebx, ebx
je 0x1405216e5
test sil, 0x20
jne 0x1405216ed
mov rcx, r14
call fcn.1400954d0
mov rax, r14
jmp case.0x140521191.0
lea r14, [rsp + 0x38]
mov rcx, r14
call fcn.1400954d0
test ebx, ebx
je 0x1405217fb
test esi, 0x100
jne 0x14052180c
mov rcx, rdi
call fcn.1400954d0
test esi, 0x800
mov rax, rdi
je case.0x140521191.0
nop
mov rax, qword [rsp + 0x20]
jmp 0x140521791
nop
ud2
test sil, 0x20
je 0x14052177a
nop
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x20]
movzx eax, byte [rax + rcx]
mov rdx, qword [rsp + 0x30]
mov byte [rdx + rcx], al
inc rcx
mov qword [rsp + 0x20], rcx
nop
mov rax, qword [rsp + 0x20]
cmp rax, qword [rsp + 0x38]
jb 0x140521730
xor edx, edx
mov ecx, esi
test esi, 0x400
je 0x140521928
nop
mov rax, qword [rsp + 0x40]
jmp case.0x140521191.0
mov rax, rbx
jmp case.0x140521191.0
lea rax, [0x14077a080]
jmp case.0x140521191.0
lea rax, [0x14077a060]
jmp case.0x140521191.0
test rax, rax
je 0x1405217be
nop
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x20]
movzx eax, byte [rax + rcx - 1]
mov rdx, qword [rsp + 0x30]
mov byte [rdx + rcx - 1], al
mov rax, qword [rsp + 0x20]
dec rax
mov qword [rsp + 0x20], rax
jmp 0x140521791
test sil, 0x40
jne 0x14052189d
jmp 0x140521755
xor eax, eax
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov cl, 0x78
mov al, 7
lock cmpxchg byte [0x14077a0a9], cl
je 0x140521800
cmp al, 0x5c
jne 0x1405217dd
test esi, 0x200
jne 0x14052111c
mov rax, rdi
jmp case.0x140521191.0
test esi, 0x800
je 0x140521908
movabs rax, 0x51a315b5a9f983f1
xor qword [0x14077a0a0], rax
lea rax, [0x14077a0a0]
xor byte [0x14077a0a8], 0x57
mov cl, 0x5c
xchg byte [0x14077a0a9], cl
jmp case.0x140521191.0
test esi, 0x1000
je 0x1405210c7
cmp al, 0x64
je 0x14052177f
mov cl, 0x9a
mov al, 0xe1
lock cmpxchg byte [0x14077a095], cl
jne 0x140521835
test esi, 0x200
je case.0x140521191.3
lea rax, [rsp + 0x20]
test sil, 0x20
jne case.0x140521191.0
xor ecx, ecx
jmp 0x1405218b0
nop
mov rcx, qword [rsp + 0x28]
movzx ecx, byte [rcx + rax]
mov rdx, qword [rsp + 0x30]
mov byte [rdx + rax], cl
inc rax
xor ecx, ecx
cmp rax, qword [rsp + 0x38]
jb 0x1405218a8
test sil, sil
jns 0x1405217dd
nop
mov rax, qword [rsp + 0x40]
jmp case.0x140521191.0
test esi, 0x100
je 0x140521876
lea edx, [rcx - 0x4c63482]
mov r8d, 0x86186187
imul r8, rdx
shr r8, 0x20
sub edx, r8d
shr edx, 1
add edx, r8d
shr edx, 4
lea r8d, [rdx + rdx*4]
lea edx, [rdx + r8*4]
neg edx
add edx, ecx
add edx, 0xfb39cb7e
movsxd rcx, ecx
lea r8, [0x14077a080]
lea r9, [0x140612b70]
sub r9, rdx
movzx edx, byte [r9 + 0x14]
xor dl, 0x37
add byte [rcx + r8], dl
inc ecx
cmp ecx, 0x15
jl 0x1405218a8
mov al, 0x64
xchg byte [0x14077a095], al
lea rax, [0x14077a080]
jmp case.0x140521191.0
test ecx, 0x100
je case.0x140521191.0
lea eax, [rdx + 0x164f76e]
mov r8d, 0xcccccccd
imul r8, rax
shr r8, 0x24
shl r8d, 2
lea eax, [r8 + r8*4]
neg eax
add eax, edx
add eax, 0x164f76e
movsxd rdx, edx
lea r8, [0x14077a060]
movzx r9d, byte [rdx + r8]
lea r10, [0x140612b50]
xor r9b, byte [rax + r10]
xor r9b, 0xd6
mov byte [rdx + r8], r9b
inc edx
xor eax, eax
cmp edx, 0x15
jle 0x14052191c
mov al, 0xd0
xchg byte [0x14077a076], al
jmp 0x140521788