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

Disassembly:
sub rsp, 0x88
mov qword [rsp + 0x80], r8
mov qword [rsp + 0x78], rdx
mov qword [rsp + 0x70], rcx
mov rax, qword [rsp + 0x70]
mov qword [rsp + 0x38], rax
mov al, byte [rax + 8]
and al, 1
movzx ecx, al
xor eax, eax
cmp eax, ecx
jne 0x18000201a
jmp 0x1800024c9
mov rcx, qword [rsp + 0x38]
mov eax, 0x10
cmp eax, dword [rcx + 0x3d0]
jne 0x18000204c
mov rcx, qword [rsp + 0x38]
mov r8, qword [rsp + 0x80]
mov rdx, qword [rsp + 0x78]
call fcn.1800010e0
jmp 0x1800024c9
mov rax, qword [rsp + 0x38]
mov eax, dword [rax + 0x3d0]
mov ecx, 4
cdq
idiv ecx
mov dword [rsp + 0x6c], eax
cmp dword [rsp + 0x6c], 4
jne 0x180002079
xor eax, eax
mov dword [rsp + 0x34], eax
jmp 0x180002091
mov edx, dword [rsp + 0x6c]
mov eax, 2
mov ecx, 1
cmp edx, 6
cmove eax, ecx
mov dword [rsp + 0x34], eax
mov rax, qword [rsp + 0x38]
mov ecx, dword [rsp + 0x34]
mov dword [rsp + 0x68], ecx
movsxd rdx, dword [rsp + 0x68]
lea rcx, [0x18001d200]
shl rdx, 5
add rcx, rdx
mov ecx, dword [rcx + 8]
mov dword [rsp + 0x64], ecx
movsxd rdx, dword [rsp + 0x68]
lea rcx, [0x18001d200]
shl rdx, 5
add rcx, rdx
mov ecx, dword [rcx + 0x10]
mov dword [rsp + 0x60], ecx
movsxd rdx, dword [rsp + 0x68]
lea rcx, [0x18001d200]
shl rdx, 5
add rcx, rdx
mov ecx, dword [rcx + 0x18]
mov dword [rsp + 0x5c], ecx
add rax, 0x458
mov qword [rsp + 0x48], rax
mov dword [rsp + 0x58], 0
mov eax, dword [rsp + 0x58]
cmp eax, dword [rsp + 0x6c]
jge 0x1800021b6
mov rax, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x78]
mov rdx, rcx
add rdx, 1
mov qword [rsp + 0x78], rdx
movzx edx, byte [rcx]
shl edx, 0x18
mov rcx, qword [rsp + 0x48]
mov dword [rcx], edx
mov rcx, qword [rsp + 0x78]
mov rdx, rcx
add rdx, 1
mov qword [rsp + 0x78], rdx
movzx edx, byte [rcx]
shl edx, 0x10
mov rcx, qword [rsp + 0x48]
or edx, dword [rcx]
mov dword [rcx], edx
mov rcx, qword [rsp + 0x78]
mov rdx, rcx
add rdx, 1
mov qword [rsp + 0x78], rdx
movzx edx, byte [rcx]
shl edx, 8
mov rcx, qword [rsp + 0x48]
or edx, dword [rcx]
mov dword [rcx], edx
movsxd rcx, dword [rsp + 0x58]
mov ecx, dword [rax + rcx*4 + 0xc]
mov rax, qword [rsp + 0x78]
mov rdx, rax
add rdx, 1
mov qword [rsp + 0x78], rdx
movzx edx, byte [rax]
mov rax, qword [rsp + 0x48]
mov r8, rax
add r8, 4
mov qword [rsp + 0x48], r8
or edx, dword [rax]
mov dword [rax], edx
xor ecx, dword [rax]
mov dword [rax], ecx
mov eax, dword [rsp + 0x58]
add eax, 1
mov dword [rsp + 0x58], eax
jmp 0x1800020ff
mov dword [rsp + 0x44], 1
mov rcx, qword [rsp + 0x38]
mov eax, dword [rsp + 0x44]
cmp eax, dword [rcx + 0x3d4]
jge 0x180002321
mov dword [rsp + 0x58], 0
mov eax, dword [rsp + 0x58]
cmp eax, dword [rsp + 0x6c]
jge 0x1800022ec
mov rcx, qword [rsp + 0x38]
movsxd rax, dword [rsp + 0x58]
mov eax, dword [rcx + rax*4 + 0x458]
sar eax, 0x18
and eax, 0xff
movsxd rdx, eax
lea rax, section..rdata
mov eax, dword [rax + rdx*4]
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x64]
cdq
idiv dword [rsp + 0x6c]
mov eax, dword [rsp + 0x28]
movsxd rdx, edx
mov edx, dword [rcx + rdx*4 + 0x458]
sar edx, 0x10
and edx, 0xff
movsxd r8, edx
lea rdx, [0x18001b400]
xor eax, dword [rdx + r8*4]
mov dword [rsp + 0x2c], eax
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x60]
cdq
idiv dword [rsp + 0x6c]
mov eax, dword [rsp + 0x2c]
movsxd rdx, edx
mov ecx, dword [rcx + rdx*4 + 0x458]
sar ecx, 8
and ecx, 0xff
movsxd rdx, ecx
lea rcx, [0x18001b800]
xor eax, dword [rcx + rdx*4]
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x5c]
cdq
idiv dword [rsp + 0x6c]
mov rax, qword [rsp + 0x38]
mov ecx, edx
mov edx, dword [rsp + 0x30]
movsxd rcx, ecx
mov ecx, dword [rax + rcx*4 + 0x458]
and ecx, 0xff
movsxd r8, ecx
lea rcx, [0x18001bc00]
xor edx, dword [rcx + r8*4]
mov rcx, rax
add rcx, 0xc
movsxd r8, dword [rsp + 0x44]
shl r8, 5
add rcx, r8
movsxd r8, dword [rsp + 0x58]
xor edx, dword [rcx + r8*4]
movsxd rcx, dword [rsp + 0x58]
mov dword [rax + rcx*4 + 0x438], edx
mov eax, dword [rsp + 0x58]
add eax, 1
mov dword [rsp + 0x58], eax
jmp 0x1800021db
mov rdx, qword [rsp + 0x38]
mov rcx, rdx
add rcx, 0x458
add rdx, 0x438
mov eax, dword [rsp + 0x6c]
shl eax, 2
movsxd r8, eax
call fcn.180019860
mov eax, dword [rsp + 0x44]
add eax, 1
mov dword [rsp + 0x44], eax
jmp 0x1800021be
mov dword [rsp + 0x58], 0
mov dword [rsp + 0x40], 0
mov eax, dword [rsp + 0x58]
cmp eax, dword [rsp + 0x6c]
jge 0x1800024c9
mov rax, qword [rsp + 0x38]
mov rcx, rax
add rcx, 0xc
movsxd rdx, dword [rax + 0x3d4]
shl rdx, 5
add rcx, rdx
movsxd rdx, dword [rsp + 0x58]
mov ecx, dword [rcx + rdx*4]
mov dword [rsp + 0x54], ecx
movsxd rcx, dword [rsp + 0x58]
mov eax, dword [rax + rcx*4 + 0x458]
sar eax, 0x18
and eax, 0xff
movsxd rcx, eax
lea rax, str.cw
movsx eax, byte [rax + rcx]
mov ecx, dword [rsp + 0x54]
sar ecx, 0x18
xor eax, ecx
mov dl, al
mov rax, qword [rsp + 0x80]
mov ecx, dword [rsp + 0x40]
mov r8d, ecx
add r8d, 1
mov dword [rsp + 0x40], r8d
movsxd rcx, ecx
mov byte [rax + rcx], dl
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x64]
cdq
idiv dword [rsp + 0x6c]
mov rax, qword [rsp + 0x38]
movsxd rcx, edx
mov eax, dword [rax + rcx*4 + 0x458]
sar eax, 0x10
and eax, 0xff
movsxd rcx, eax
lea rax, str.cw
movsx eax, byte [rax + rcx]
mov ecx, dword [rsp + 0x54]
sar ecx, 0x10
xor eax, ecx
mov dl, al
mov rax, qword [rsp + 0x80]
mov ecx, dword [rsp + 0x40]
mov r8d, ecx
add r8d, 1
mov dword [rsp + 0x40], r8d
movsxd rcx, ecx
mov byte [rax + rcx], dl
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x60]
cdq
idiv dword [rsp + 0x6c]
mov rax, qword [rsp + 0x38]
movsxd rcx, edx
mov eax, dword [rax + rcx*4 + 0x458]
sar eax, 8
and eax, 0xff
movsxd rcx, eax
lea rax, str.cw
movsx eax, byte [rax + rcx]
mov ecx, dword [rsp + 0x54]
sar ecx, 8
xor eax, ecx
mov dl, al
mov rax, qword [rsp + 0x80]
mov ecx, dword [rsp + 0x40]
mov r8d, ecx
add r8d, 1
mov dword [rsp + 0x40], r8d
movsxd rcx, ecx
mov byte [rax + rcx], dl
mov eax, dword [rsp + 0x58]
add eax, dword [rsp + 0x5c]
cdq
idiv dword [rsp + 0x6c]
mov rax, qword [rsp + 0x38]
movsxd rcx, edx
mov eax, dword [rax + rcx*4 + 0x458]
and eax, 0xff
movsxd rcx, eax
lea rax, str.cw
movsx eax, byte [rax + rcx]
xor eax, dword [rsp + 0x54]
mov dl, al
mov rax, qword [rsp + 0x80]
mov ecx, dword [rsp + 0x40]
mov r8d, ecx
add r8d, 1
mov dword [rsp + 0x40], r8d
movsxd rcx, ecx
mov byte [rax + rcx], dl
mov eax, dword [rsp + 0x58]
add eax, 1
mov dword [rsp + 0x58], eax
jmp 0x180002331
add rsp, 0x88
ret