Function at 0x180001610
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x20
cmp byte [rcx + 8], 0
je 0x18000130b
mov qword [rsp + 0x10], r8
mov r15d, dword [rdx]
mov ebp, dword [rdx + 4]
bswap r15d
xor r15d, dword [rcx + 0xc]
bswap ebp
xor ebp, dword [rcx + 0x10]
mov esi, dword [rdx + 8]
bswap esi
xor esi, dword [rcx + 0x14]
mov r8d, esi
mov ebx, dword [rdx + 0xc]
bswap ebx
xor ebx, dword [rcx + 0x18]
mov eax, dword [rcx + 0x3d4]
cmp eax, 2
mov qword [rsp + 8], rcx
mov qword [rsp], rax
jl 0x1800011ae
lea rdi, [rcx + 0x38]
add rax, 0xffffffffffffffff
mov qword [rsp + 0x18], rax
nop dword [rax]
mov eax, r15d
shr eax, 0x18
mov ecx, ebp
mov edx, ebp
mov r12d, ebp
shr ebp, 0x10
movzx ebp, bpl
lea rsi, [0x18002a400]
mov r9d, dword [rsi + rbp*4]
mov r10, rsi
lea r13, section..rdata
xor r9d, dword [r13 + rax*4]
mov ecx, r8d
movzx eax, ch
lea rsi, [0x18002a800]
xor r9d, dword [rsi + rax*4]
mov rbp, rsi
movzx eax, bl
lea rsi, [0x18002ac00]
xor r9d, dword [rsi + rax*4]
shr edx, 0x18
mov eax, r8d
shr eax, 0x10
movzx eax, al
mov r11d, dword [r10 + rax*4]
mov r8, r10
xor r11d, dword [r13 + rdx*4]
mov eax, r12d
movzx r13d, al
movzx edx, bh
xor r11d, dword [rbp + rdx*4]
movzx ebp, ah
mov r10d, ecx
movzx edx, r15b
mov r12, rsi
xor r11d, dword [rsi + rdx*4]
movzx r14d, cl
shr r10d, 0x18
mov edx, ebx
shr edx, 0x10
movzx edx, dl
mov edx, dword [r8 + rdx*4]
lea rsi, section..rdata
xor edx, dword [rsi + r10*4]
mov eax, r15d
movzx ecx, ah
lea r10, [0x18002a800]
xor edx, dword [r10 + rcx*4]
xor r9d, dword [rdi - 0xc]
xor r11d, dword [rdi - 8]
xor edx, dword [r12 + r13*4]
xor edx, dword [rdi - 4]
shr ebx, 0x18
shr eax, 0x10
movzx eax, al
mov eax, dword [r8 + rax*4]
xor eax, dword [rsi + rbx*4]
xor eax, dword [r10 + rbp*4]
xor eax, dword [r12 + r14*4]
xor eax, dword [rdi]
add rdi, 0x20
mov r15d, r9d
mov ebp, r11d
mov r8d, edx
mov ebx, eax
add qword [rsp + 0x18], 0xffffffffffffffff
jne 0x1800010b0
jmp 0x1800011b9
mov eax, ebx
mov edx, r8d
mov r11d, ebp
mov r9d, r15d
movsxd r10, dword [rsp]
shl r10, 5
mov rcx, qword [rsp + 8]
mov r15d, dword [rcx + r10 + 0xc]
mov esi, r9d
movzx r14d, sil
mov rbx, rsi
shr rbx, 0x18
lea r8, str.cw
mov ebp, r15d
shr ebp, 0x18
xor bpl, byte [rbx + r8]
mov ebx, r11d
shr ebx, 0x10
movzx ebx, bl
mov edi, r15d
shr edi, 0x10
xor dil, byte [rbx + r8]
mov rsi, qword [rsp + 0x10]
mov byte [rsi], bpl
mov byte [rsi + 1], dil
mov edi, edx
shr edi, 8
movzx edi, dil
mov ebx, r15d
shr ebx, 8
xor bl, byte [rdi + r8]
mov byte [rsi + 2], bl
mov r12d, eax
movzx edi, r12b
xor r15b, byte [rdi + r8]
mov byte [rsi + 3], r15b
mov ebx, dword [rcx + r10 + 0x10]
mov edi, r11d
movzx r15d, dil
shr rdi, 0x18
mov ebp, ebx
shr ebp, 0x18
xor bpl, byte [rdi + r8]
mov byte [rsi + 4], bpl
mov edi, edx
shr edi, 0x10
movzx edi, dil
mov ebp, ebx
shr ebp, 0x10
xor bpl, byte [rdi + r8]
mov byte [rsi + 5], bpl
mov edi, eax
shr edi, 8
movzx edi, dil
mov ebp, ebx
shr ebp, 8
xor bpl, byte [rdi + r8]
mov byte [rsi + 6], bpl
xor bl, byte [r14 + r8]
mov byte [rsi + 7], bl
mov ebp, dword [rcx + r10 + 0x14]
mov edx, edx
movzx edi, dl
shr rdx, 0x18
mov ebx, ebp
shr ebx, 0x18
xor bl, byte [rdx + r8]
shr eax, 0x10
movzx eax, al
mov edx, ebp
shr edx, 0x10
xor dl, byte [rax + r8]
mov byte [rsi + 8], bl
mov byte [rsi + 9], dl
mov eax, r9d
shr eax, 8
movzx eax, al
mov edx, ebp
shr edx, 8
xor dl, byte [rax + r8]
mov byte [rsi + 0xa], dl
xor bpl, byte [r15 + r8]
mov byte [rsi + 0xb], bpl
mov eax, dword [rcx + r10 + 0x18]
shr r12, 0x18
mov ecx, eax
shr ecx, 0x18
xor cl, byte [r12 + r8]
mov byte [rsi + 0xc], cl
shr r9d, 0x10
movzx ecx, r9b
mov edx, eax
shr edx, 0x10
xor dl, byte [rcx + r8]
mov byte [rsi + 0xd], dl
shr r11d, 8
movzx ecx, r11b
mov edx, eax
shr edx, 8
xor dl, byte [rcx + r8]
mov byte [rsi + 0xe], dl
xor al, byte [rdi + r8]
mov byte [rsi + 0xf], al
add rsp, 0x20
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x68
cmp byte [rcx + 8], 0
je 0x180001904
mov rdi, rcx
mov esi, dword [rcx + 0x3d0]
cmp esi, 0x10
jne 0x180001650
mov rcx, rdi
add rsp, 0x68
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
jmp 0x180001040
mov qword [rsp + 0x30], r8
lea ebx, [rsi + 3]
test esi, esi
cmovns ebx, esi
sar ebx, 2
mov eax, esi
and eax, 0xfffffffc
xor ecx, ecx
cmp eax, 0x18
sete cl
mov ebp, 2
sub rbp, rcx
xor ecx, ecx
cmp eax, 0x10
cmovne rcx, rbp
shl rcx, 5
lea rax, [0x18002c200]
mov r10d, dword [rcx + rax + 8]
mov r11d, dword [rcx + rax + 0x10]
mov r8d, dword [rcx + rax + 0x18]
cmp esi, 4
jl 0x1800016eb
xor eax, eax
nop
movzx ecx, byte [rdx + rax*4]
shl ecx, 0x18
mov dword [rdi + rax*4 + 0x458], ecx
movzx ebp, byte [rdx + rax*4 + 1]
shl ebp, 0x10
or ebp, ecx
mov dword [rdi + rax*4 + 0x458], ebp
movzx ecx, byte [rdx + rax*4 + 2]
shl ecx, 8
or ecx, ebp
mov dword [rdi + rax*4 + 0x458], ecx
movzx ebp, byte [rdx + rax*4 + 3]
or ebp, ecx
xor ebp, dword [rdi + rax*4 + 0xc]
mov dword [rdi + rax*4 + 0x458], ebp
add rax, 1
cmp rbx, rax
jne 0x1800016a0
mov qword [rsp + 0x28], r8
mov ecx, dword [rdi + 0x3d4]
cmp ecx, 2
jl 0x18000184b
lea rax, [rdi + 0x458]
mov qword [rsp + 0x48], rax
lea rax, [rdi + 0x438]
mov qword [rsp + 0x40], rax
lea eax, [rbx*4]
cdqe
mov qword [rsp + 0x38], rax
lea r12, [rdi + 0x2c]
mov eax, 1
lea r9, section..rdata
lea r13, [0x18002a400]
lea r14, [0x18002a800]
lea r15, [0x18002ac00]
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x50], rcx
jmp 0x1800017b9
mov rcx, qword [rsp + 0x48]
mov rdx, qword [rsp + 0x40]
mov r8, qword [rsp + 0x38]
mov rsi, r10
mov rbp, r11
mov r15, r14
mov r14, r13
mov r13, r9
call fcn.18000a420
mov r9, r13
mov r13, r14
mov r14, r15
lea r15, [0x18002ac00]
mov r11, rbp
mov r10, rsi
mov rax, qword [rsp + 0x60]
add rax, 1
add r12, 0x20
mov rcx, qword [rsp + 0x50]
cmp rax, rcx
mov rsi, qword [rsp + 0x58]
je 0x18000184b
mov qword [rsp + 0x60], rax
cmp esi, 4
mov r8, qword [rsp + 0x28]
jl 0x180001760
xor ecx, ecx
nop word [rax + rax]
mov ebp, dword [rdi + rcx*4 + 0x458]
shr rbp, 0x16
and ebp, 0x3fc
lea eax, [r10 + rcx]
cdq
idiv ebx
movsxd rax, edx
mov eax, dword [rdi + rax*4 + 0x458]
shr rax, 0xe
and eax, 0x3fc
mov esi, dword [rax + r13]
xor esi, dword [rbp + r9]
lea eax, [r11 + rcx]
cdq
idiv ebx
movsxd rax, edx
mov eax, dword [rdi + rax*4 + 0x458]
movzx eax, ah
xor esi, dword [r14 + rax*4]
lea eax, [r8 + rcx]
cdq
idiv ebx
movsxd rax, edx
movzx eax, byte [rdi + rax*4 + 0x458]
xor esi, dword [r15 + rax*4]
xor esi, dword [r12 + rcx*4]
mov dword [rdi + rcx*4 + 0x438], esi
add rcx, 1
cmp rbx, rcx
jne 0x1800017d0
jmp 0x180001760
cmp esi, 4
mov rsi, qword [rsp + 0x30]
jl 0x180001904
mov r8d, 1
sub r8, rbx
xor ebp, ebp
lea r9, str.cw
nop dword [rax + rax]
movsxd rax, ecx
shl rax, 5
add rax, rdi
mov ecx, dword [rax + rbp*4 + 0xc]
movzx eax, byte [rdi + rbp*4 + 0x45b]
mov edx, ecx
shr edx, 0x18
xor dl, byte [rax + r9]
mov byte [rsi + rbp*4], dl
lea eax, [r10 + rbp]
cdq
idiv ebx
movsxd rax, edx
movzx eax, byte [rdi + rax*4 + 0x45a]
mov edx, ecx
shr edx, 0x10
xor dl, byte [rax + r9]
mov byte [rsi + rbp*4 + 1], dl
lea eax, [r11 + rbp]
cdq
idiv ebx
movsxd rax, edx
movzx eax, byte [rdi + rax*4 + 0x459]
mov edx, ecx
shr edx, 8
xor dl, byte [rax + r9]
mov byte [rsi + rbp*4 + 2], dl
mov rax, qword [rsp + 0x28]
add eax, ebp
cdq
idiv ebx
movsxd rax, edx
movzx eax, byte [rdi + rax*4 + 0x458]
xor cl, byte [rax + r9]
mov byte [rsi + rbp*4 + 3], cl
mov rax, r8
add rax, rbp
je 0x180001904
add rbp, 1
mov ecx, dword [rdi + 0x3d4]
jmp 0x180001870
add rsp, 0x68
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret