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

Disassembly:
sub esp, 0x1c
push ebx
mov ebx, dword [esp + 0x28]
lea edx, [ecx + 0x18]
mov eax, ebx
mov dword [esp + 4], ecx
shr eax, 2
mov dword [esp + 0x28], eax
add eax, 6
push ebp
mov dword [ecx + 0x10], eax
mov ebp, dword [edx + 0x100]
push esi
mov esi, dword [edx + 0x104]
push edi
lea edi, [eax*4 + 4]
mov eax, edx
neg eax
mov dword [esp + 0x14], edi
and eax, 0xf
add eax, edx
mov dword [esp + 0x18], eax
cmp edi, 0x3c
ja 0x46a682
cmp esi, eax
jne 0x46a667
cmp ebp, edi
jbe 0x46a6a0
sub ebp, edi
lea edi, [esi + edi*4]
xor eax, eax
mov ecx, ebp
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
jmp 0x46a6a0
cmp byte [edx + 0xf9], 0
jne 0x46a682
mov eax, edx
mov byte [edx + 0xf9], 1
neg eax
and eax, 0xf
add eax, edx
jmp 0x46a69e
xor eax, eax
cmp esi, dword [esp + 0x18]
jne 0x46a69e
mov edi, esi
mov byte [edx + 0xf9], al
mov ecx, ebp
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
mov esi, eax
mov dword [edx + 0x100], edi
mov ebp, ebx
lea edi, [ecx + 0x11c]
mov dword [edx + 0x104], esi
mov esi, dword [edi]
and ebp, 0xfffffffc
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x18], 4
test ebx, ebx
je 0x46a731
test esi, esi
jne 0x46a6df
call fcn.0068bca3
mov dword [eax], 0x16
call fcn.00681d70
jmp 0x46a731
mov eax, dword [esp + 0x30]
mov dword [esp + 0x14], edi
test eax, eax
je 0x46a706
cmp ebp, ebx
jb 0x46a6fc
push ebx
push eax
push esi
call fcn.00678240
add esp, 0xc
jmp 0x46a731
lea eax, [ecx + 0x11c]
mov dword [esp + 0x14], eax
push ebp
push 0
push esi
call fcn.00678c60
add esp, 0xc
cmp dword [esp + 0x30], 0
je 0x46a6cd
cmp ebp, ebx
jae 0x46a731
call fcn.0068bca3
mov dword [eax], 0x22
call fcn.00681d70
mov edi, dword [esp + 0x14]
sub ebp, ebx
lea eax, [esi + ebx]
push ebp
push 0
push eax
call fcn.00678c60
lea edx, [esp + 0x24]
lea ecx, [esp + 0x28]
call fcn.0045d8d0
push eax
mov edx, esi
mov ecx, esi
call fcn.0045fe10
mov ebp, dword [esp + 0x44]
add esp, 0x10
mov dword [esp + 0x30], 0x7684bc
mov ecx, dword [esi + ebp*4 - 4]
mov eax, ecx
shr eax, 0x10
movzx eax, al
movzx edx, byte [eax + 0x7684e0]
mov eax, ecx
shr eax, 8
xor edx, 1
movzx eax, al
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
movzx eax, cl
shl edx, 8
shr ecx, 0x18
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
movzx eax, byte [ecx + 0x7684e0]
shl edx, 8
xor edx, eax
xor edx, dword [esi]
mov dword [esi + ebp*4], edx
mov eax, dword [esi + 4]
xor eax, edx
lea edx, [ebp*4 + 0xc]
mov dword [esi + ebp*4 + 4], eax
mov ecx, dword [esi + 8]
xor ecx, eax
mov dword [esp + 0x24], edx
lea eax, [ebp*4 + 8]
mov dword [eax + esi], ecx
mov dword [esp + 0x20], eax
mov eax, dword [esi + 0xc]
xor eax, ecx
mov dword [edx + esi], eax
mov eax, dword [esp + 0x34]
mov ebp, dword [edi]
mov dword [esp + 0x14], ebp
lea edx, [eax*4 + 0x10]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x28], edx
mov eax, dword [eax + 0x118]
lea ecx, [eax*4]
add ecx, ebp
lea eax, [edx + esi]
cmp eax, ecx
je 0x46a941
cmp ebx, 0x18
jne 0x46a82c
mov ecx, dword [esi + 0x24]
xor ecx, dword [esi + 0x10]
mov eax, dword [esi + 0x14]
xor eax, ecx
mov dword [esi + 0x28], ecx
mov dword [esi + 0x2c], eax
jmp 0x46a895
cmp ebx, 0x20
jne 0x46a895
mov ecx, dword [esi + 0x2c]
mov eax, ecx
shr eax, 0x18
movzx edx, byte [eax + 0x7684e0]
mov eax, ecx
shr eax, 0x10
movzx eax, al
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
mov eax, ecx
shr eax, 8
movzx eax, al
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
movzx eax, cl
mov ecx, dword [esi + 0x18]
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
mov eax, dword [esi + 0x14]
xor edx, dword [esi + 0x10]
xor eax, edx
mov dword [esi + 0x30], edx
xor ecx, eax
mov dword [esi + 0x34], eax
mov eax, dword [esi + 0x1c]
xor eax, ecx
mov dword [esi + 0x38], ecx
mov dword [esi + 0x3c], eax
mov eax, dword [esp + 0x34]
lea ebp, [eax*4]
add esi, ebp
mov ecx, dword [esi + ebp - 4]
mov eax, ecx
shr eax, 0x10
movzx eax, al
movzx edx, byte [eax + 0x7684e0]
mov eax, ecx
shr eax, 8
movzx eax, al
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
movzx eax, cl
shr ecx, 0x18
shl edx, 8
movzx eax, byte [eax + 0x7684e0]
xor edx, eax
movzx eax, byte [ecx + 0x7684e0]
shl edx, 8
xor edx, eax
mov eax, dword [esp + 0x30]
xor edx, dword [eax]
add eax, 4
xor edx, dword [esi]
mov dword [esp + 0x30], eax
mov dword [esi + ebp], edx
mov eax, dword [esi + 4]
xor eax, edx
mov dword [esi + ebp + 4], eax
mov ecx, dword [esi + 8]
xor ecx, eax
mov eax, dword [esp + 0x20]
mov dword [eax + esi], ecx
mov eax, dword [esi + 0xc]
xor eax, ecx
mov ecx, dword [esp + 0x24]
mov dword [ecx + esi], eax
mov eax, dword [esp + 0x10]
mov ebp, dword [edi]
mov dword [esp + 0x14], ebp
mov eax, dword [eax + 0x118]
lea ecx, [eax*4]
mov eax, dword [esp + 0x28]
add ecx, ebp
add eax, esi
cmp eax, ecx
jne 0x46a814
mov ebx, dword [esp + 0x10]
mov eax, dword [ebx + 4]
lea ecx, [ebx + 4]
mov eax, dword [eax + 0x1c]
call eax
test al, al
je 0x46a9e2
cmp byte [0x811d8a], 0
jne 0x46a9b9
xor edi, edi
movzx edx, byte [edi + 0x7684e0]
mov ecx, edx
mov esi, edx
shr ecx, 7
imul eax, ecx, 0x1b000000
shl esi, 0x19
imul ecx, ecx, 0x11b
xor esi, eax
mov eax, edx
shl eax, 8
or eax, edx
shl eax, 8
or esi, eax
lea eax, [edx + edx]
xor ecx, eax
xor eax, eax
xor ecx, edx
or eax, esi
or ecx, esi
mov dword [edi*8 + 0x811d98], eax
mov dword [edi*8 + 0x811d9c], ecx
inc edi
cmp edi, 0x100
jl 0x46a963
mov byte [0x811d8a], 1
push 0x10
mov edx, ebp
mov ecx, ebp
call fcn.0045fe10
mov ecx, dword [ebx + 0x10]
shl ecx, 4
add ecx, ebp
push 0x10
mov edx, ecx
call fcn.0045fe10
add esp, 8
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret 0xc
cmp byte [0x811d8b], 0
jne 0x46a9f0
call fcn.00469fa0
mov eax, dword [ebx + 0x10]
mov esi, 4
mov dword [esp + 0x30], esi
lea edi, [eax*4 - 4]
cmp edi, esi
jbe 0x46acf4
lea ebx, [edi*4 + 8]
lea eax, [ebp + 0x18]
add ebx, ebp
mov dword [esp + 0x34], eax
mov ebp, eax
nop dword [eax]
mov edx, dword [ebp - 8]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov esi, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebx - 8]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov dword [ebp - 8], ecx
mov dword [ebx - 8], esi
mov edx, dword [ebp - 4]
mov eax, edx
shr eax, 8
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov esi, dword [ecx*8 + 0x81259a]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x812599]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebx - 4]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 8
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov ecx, dword [ecx*8 + 0x81259a]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x812599]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov dword [ebp - 4], ecx
mov dword [ebx - 4], esi
mov edx, dword [ebp]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov esi, dword [ecx*8 + 0x812599]
lea ebp, [ebp + 0x10]
mov eax, edx
lea ebx, [ebx - 0x10]
shr eax, 8
sub edi, 4
movzx eax, al
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebx + 0x10]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov dword [ebp - 0x10], ecx
mov dword [ebx + 0x10], esi
mov edx, dword [ebp - 0xc]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov esi, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebx + 0x14]
movzx eax, byte [eax + 0x7684e0]
xor esi, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov dword [ebp - 0xc], ecx
mov dword [ebx + 0x14], esi
mov esi, dword [esp + 0x30]
add esi, 4
mov dword [esp + 0x30], esi
cmp esi, edi
jb 0x46aa20
mov ebp, dword [esp + 0x14]
mov ebx, dword [esp + 0x10]
mov edx, dword [ebp + esi*4]
mov eax, edx
shr eax, 0x10
movzx eax, al
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebp + esi*4 + 4]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 8
movzx eax, al
mov dword [ebp + esi*4], ecx
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov ecx, dword [ecx*8 + 0x81259a]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x812599]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebp + esi*4 + 8]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov dword [ebp + esi*4 + 4], ecx
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
mov edx, dword [ebp + esi*4 + 0xc]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov dword [ebp + esi*4 + 8], ecx
movzx ecx, byte [eax + 0x7684e0]
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*8 + 0x812599]
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259a]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259c]
movzx eax, dl
movzx eax, byte [eax + 0x7684e0]
xor ecx, dword [eax*8 + 0x81259b]
mov dword [ebp + esi*4 + 0xc], ecx
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp]
add eax, eax
bswap ecx
mov eax, dword [ebp + eax*8]
bswap eax
mov dword [ebp], eax
mov eax, dword [ebx + 0x10]
add eax, eax
pop edi
pop esi
mov dword [ebp + eax*8], ecx
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp + 4]
add eax, eax
bswap ecx
mov eax, dword [ebp + eax*8 + 4]
bswap eax
mov dword [ebp + 4], eax
mov eax, dword [ebx + 0x10]
add eax, eax
mov dword [ebp + eax*8 + 4], ecx
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp + 8]
add eax, eax
bswap ecx
mov eax, dword [ebp + eax*8 + 8]
bswap eax
mov dword [ebp + 8], eax
mov eax, dword [ebx + 0x10]
add eax, eax
mov dword [ebp + eax*8 + 8], ecx
mov eax, dword [ebx + 0x10]
mov ecx, dword [ebp + 0xc]
add eax, eax
bswap ecx
mov eax, dword [ebp + eax*8 + 0xc]
bswap eax
mov dword [ebp + 0xc], eax
mov eax, dword [ebx + 0x10]
add eax, eax
mov dword [ebp + eax*8 + 0xc], ecx
pop ebp
pop ebx
add esp, 0x1c
ret 0xc