Function at 0x180017f30
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push rbp
push r13
push r14
sub rsp, 0x10
mov r14d, dword [rcx + 0xf0]
mov r13, r8
shr r14d, 1
mov rbp, rcx
lea eax, [r14 - 1]
cmp eax, 6
ja 0x1800184c2
mov eax, dword [rdx]
mov r10d, dword [rdx + 8]
mov r9d, dword [rdx + 4]
mov r11d, r9d
mov edx, dword [rdx + 0xc]
mov r8d, edx
mov qword [rsp + 0x30], rbx
mov ebx, eax
rol eax, 8
and eax, 0xff00ff
mov qword [rsp + 0x38], rsi
rol r9d, 8
and r9d, 0xff00ff
mov qword [rsp + 0x40], rdi
rol edx, 8
and edx, 0xff00ff
ror r11d, 8
ror r8d, 8
and r11d, 0xff00ff00
or r11d, r9d
ror ebx, 8
xor r11d, dword [rcx + 4]
mov r9d, r10d
ror r9d, 8
and r8d, 0xff00ff00
or r8d, edx
rol r10d, 8
xor r8d, dword [rcx + 0xc]
and ebx, 0xff00ff00
or ebx, eax
mov qword [rsp + 8], r12
xor ebx, dword [rcx]
and r9d, 0xff00ff00
mov qword [rsp], r15
and r10d, 0xff00ff
or r9d, r10d
mov eax, r8d
xor r9d, dword [rcx + 8]
lea r10, [0x180048d10]
shr eax, 0x10
movzx edx, al
mov eax, r9d
shr eax, 8
movzx ecx, al
mov eax, ebx
mov r15d, dword [r10 + rdx*4 + 0x400]
shr rax, 0x18
xor r15d, dword [r10 + rcx*4 + 0x800]
mov edx, r9d
shr rdx, 0x18
xor r15d, dword [r10 + rax*4]
movzx eax, r11b
mov esi, dword [r10 + rdx*4]
xor r15d, dword [r10 + rax*4 + 0xc00]
mov eax, r8d
xor r15d, dword [rbp + 0x10]
shr eax, 8
movzx ecx, al
mov eax, r11d
shr rax, 0x18
mov edi, dword [r10 + rcx*4 + 0x800]
xor edi, dword [r10 + rax*4]
mov eax, ebx
shr eax, 0x10
movzx ecx, al
movzx eax, r9b
xor edi, dword [r10 + rcx*4 + 0x400]
xor edi, dword [r10 + rax*4 + 0xc00]
mov eax, r11d
xor edi, dword [rbp + 0x14]
shr eax, 0x10
movzx ecx, al
mov eax, ebx
shr eax, 8
xor esi, dword [r10 + rcx*4 + 0x400]
movzx ecx, al
movzx eax, r8b
xor esi, dword [r10 + rcx*4 + 0x800]
xor esi, dword [r10 + rax*4 + 0xc00]
xor esi, dword [rbp + 0x18]
mov ecx, r8d
shr rcx, 0x18
shr r9d, 0x10
movzx eax, r9b
shr r11d, 8
mov r12d, dword [r10 + rcx*4]
xor r12d, dword [r10 + rax*4 + 0x400]
movzx eax, r11b
xor r12d, dword [r10 + rax*4 + 0x800]
movzx eax, bl
lea rbx, [0x180048d10]
xor r12d, dword [rbx + rax*4 + 0xc00]
xor r12d, dword [rbp + 0x1c]
add rbp, 0x20
add r14d, 0xffffffff
je 0x1800182e2
nop dword [rax]
mov eax, r12d
shr eax, 0x10
movzx edx, al
mov eax, esi
shr eax, 8
movzx ecx, al
mov eax, r15d
mov r11d, dword [rbx + rdx*4 + 0x400]
shr rax, 0x18
xor r11d, dword [rbx + rcx*4 + 0x800]
mov edx, esi
shr rdx, 0x18
xor r11d, dword [rbx + rax*4]
movzx eax, dil
mov r9d, dword [rbx + rdx*4]
xor r11d, dword [rbx + rax*4 + 0xc00]
mov eax, r12d
xor r11d, dword [rbp]
shr eax, 8
movzx ecx, al
mov eax, edi
shr rax, 0x18
mov r10d, dword [rbx + rcx*4 + 0x800]
xor r10d, dword [rbx + rax*4]
mov eax, r15d
shr eax, 0x10
movzx ecx, al
movzx eax, sil
shr esi, 0x10
xor r10d, dword [rbx + rcx*4 + 0x400]
xor r10d, dword [rbx + rax*4 + 0xc00]
mov eax, edi
xor r10d, dword [rbp + 4]
shr eax, 0x10
movzx ecx, al
mov eax, r15d
shr eax, 8
shr edi, 8
xor r9d, dword [rbx + rcx*4 + 0x400]
movzx ecx, al
movzx eax, r12b
xor r9d, dword [rbx + rcx*4 + 0x800]
xor r9d, dword [rbx + rax*4 + 0xc00]
xor r9d, dword [rbp + 8]
movzx eax, sil
mov ecx, r12d
shr rcx, 0x18
mov r8d, dword [rbx + rcx*4]
xor r8d, dword [rbx + rax*4 + 0x400]
movzx eax, dil
xor r8d, dword [rbx + rax*4 + 0x800]
movzx eax, r15b
xor r8d, dword [rbx + rax*4 + 0xc00]
xor r8d, dword [rbp + 0xc]
mov eax, r8d
shr eax, 0x10
movzx edx, al
mov eax, r9d
shr eax, 8
movzx ecx, al
mov eax, r11d
mov r15d, dword [rbx + rdx*4 + 0x400]
shr rax, 0x18
xor r15d, dword [rbx + rcx*4 + 0x800]
xor r15d, dword [rbx + rax*4]
movzx eax, r10b
xor r15d, dword [rbx + rax*4 + 0xc00]
mov eax, r8d
xor r15d, dword [rbp + 0x10]
shr eax, 8
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edi, dword [rbx + rcx*4 + 0x800]
xor edi, dword [rbx + rax*4]
mov eax, r11d
shr eax, 0x10
movzx ecx, al
movzx eax, r9b
xor edi, dword [rbx + rcx*4 + 0x400]
xor edi, dword [rbx + rax*4 + 0xc00]
xor edi, dword [rbp + 0x14]
mov eax, r10d
shr eax, 0x10
movzx ecx, al
mov eax, r11d
shr eax, 8
mov edx, r9d
shr rdx, 0x18
shr r9d, 0x10
shr r10d, 8
mov esi, dword [rbx + rdx*4]
xor esi, dword [rbx + rcx*4 + 0x400]
movzx ecx, al
movzx eax, r8b
xor esi, dword [rbx + rcx*4 + 0x800]
xor esi, dword [rbx + rax*4 + 0xc00]
xor esi, dword [rbp + 0x18]
movzx eax, r9b
mov ecx, r8d
shr rcx, 0x18
mov r12d, dword [rbx + rcx*4]
xor r12d, dword [rbx + rax*4 + 0x400]
movzx eax, r10b
xor r12d, dword [rbx + rax*4 + 0x800]
movzx eax, r11b
xor r12d, dword [rbx + rax*4 + 0xc00]
xor r12d, dword [rbp + 0x1c]
add rbp, 0x20
add r14d, 0xffffffff
jne 0x180018100
mov eax, r12d
shr eax, 0x10
movzx ecx, al
mov eax, esi
shr eax, 8
mov r10d, dword [rbx + rcx*4 + 0x1000]
movzx ecx, al
and r10d, 0xff0000
mov eax, dword [rbx + rcx*4 + 0x1000]
and eax, 0xff00
xor r10d, eax
mov eax, r15d
shr rax, 0x18
mov ecx, dword [rbx + rax*4 + 0x1000]
and ecx, 0xff000000
movzx eax, dil
xor r10d, ecx
movzx eax, byte [rbx + rax*4 + 0x1000]
xor r10d, eax
mov eax, r15d
shr eax, 0x10
movzx ecx, al
mov eax, r12d
shr eax, 8
xor r10d, dword [rbp]
mov r9d, dword [rbx + rcx*4 + 0x1000]
movzx ecx, al
and r9d, 0xff0000
mov eax, dword [rbx + rcx*4 + 0x1000]
and eax, 0xff00
xor r9d, eax
mov eax, edi
shr rax, 0x18
mov eax, dword [rbx + rax*4 + 0x1000]
and eax, 0xff000000
xor r9d, eax
movzx eax, sil
movzx eax, byte [rbx + rax*4 + 0x1000]
xor r9d, eax
mov eax, edi
xor r9d, dword [rbp + 4]
shr eax, 0x10
movzx ecx, al
mov eax, esi
shr rax, 0x18
shr esi, 0x10
mov r8d, dword [rbx + rcx*4 + 0x1000]
and r8d, 0xff0000
shr edi, 8
mov eax, dword [rbx + rax*4 + 0x1000]
and eax, 0xff000000
xor r8d, eax
mov eax, r15d
shr eax, 8
movzx ecx, al
mov eax, dword [rbx + rcx*4 + 0x1000]
and eax, 0xff00
xor r8d, eax
movzx eax, r12b
movzx eax, byte [rbx + rax*4 + 0x1000]
xor r8d, eax
movzx eax, sil
xor r8d, dword [rbp + 8]
mov edx, dword [rbx + rax*4 + 0x1000]
and edx, 0xff0000
mov eax, r12d
shr rax, 0x18
mov eax, dword [rbx + rax*4 + 0x1000]
and eax, 0xff000000
xor edx, eax
movzx eax, dil
mov ecx, dword [rbx + rax*4 + 0x1000]
and ecx, 0xff00
movzx eax, r15b
xor edx, ecx
movzx eax, byte [rbx + rax*4 + 0x1000]
xor edx, eax
mov eax, r10d
xor edx, dword [rbp + 0xc]
ror eax, 8
and eax, 0xff00ff00
mov r15, qword [rsp]
mov r12, qword [rsp + 8]
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
rol r10d, 8
and r10d, 0xff00ff
or eax, r10d
mov dword [r13], eax
mov eax, r9d
ror eax, 8
and eax, 0xff00ff00
rol r9d, 8
and r9d, 0xff00ff
or eax, r9d
mov dword [r13 + 4], eax
mov eax, r8d
ror eax, 8
and eax, 0xff00ff00
rol r8d, 8
and r8d, 0xff00ff
or eax, r8d
mov dword [r13 + 8], eax
mov eax, edx
ror eax, 8
rol edx, 8
and eax, 0xff00ff00
and edx, 0xff00ff
or eax, edx
mov dword [r13 + 0xc], eax
add rsp, 0x10
pop r14
pop r13
pop rbp
ret