Function at 0x402ee0
Capabilities:
Encode data using add xor sub operations
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
sub esp, 0x24
push ebx
push ebp
push esi
push edi
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x40]
mov edx, dword [eax + 0x10]
xor edx, dword [ecx]
mov ebx, dword [eax + 0x14]
xor ebx, dword [ecx + 4]
mov dword [esp + 0x10], edx
mov dword [esp + 0x24], edx
mov edx, dword [eax + 0x18]
xor edx, dword [ecx + 8]
mov dword [esp + 0x40], edx
mov dword [esp + 0x2c], edx
mov edx, dword [eax + 0x1c]
xor edx, dword [ecx + 0xc]
mov ecx, dword [esp + 0x10]
mov ebp, dword [eax]
add eax, 0x20
mov dword [esp + 0x1c], edx
mov dword [esp + 0x30], edx
shr edx, 0x18
movzx ecx, cl
mov dword [esp + 0x28], ebx
mov edx, dword [edx*4 + 0x46b7c0]
xor edx, dword [ecx*4 + 0x46abc0]
movzx ecx, bh
xor edx, dword [ecx*4 + 0x46afc0]
movzx ecx, byte [esp + 0x2e]
xor edx, dword [ecx*4 + 0x46b3c0]
xor edx, dword [eax]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0x10]
shr edx, 0x18
movzx ecx, bl
shr ebx, 0x18
mov edx, dword [edx*4 + 0x46b7c0]
xor edx, dword [ecx*4 + 0x46abc0]
mov ebx, dword [ebx*4 + 0x46b7c0]
mov dword [esp + 0x38], edx
mov edx, dword [esp + 0x40]
mov esi, dword [esp + 0x38]
movzx ecx, dh
xor esi, dword [ecx*4 + 0x46afc0]
movzx ecx, byte [esp + 0x32]
xor esi, dword [ecx*4 + 0x46b3c0]
mov ecx, esi
mov dword [esp + 0x38], esi
xor ecx, dword [eax + 4]
mov dword [esp + 0x38], ecx
movzx ecx, dl
shr edx, 0x18
xor ebx, dword [ecx*4 + 0x46abc0]
mov edx, dword [edx*4 + 0x46b7c0]
mov dword [esp + 0x40], ebx
mov ebx, dword [esp + 0x1c]
mov edi, dword [esp + 0x40]
movzx ecx, bh
xor edi, dword [ecx*4 + 0x46afc0]
movzx ecx, byte [esp + 0x26]
xor edi, dword [ecx*4 + 0x46b3c0]
mov ecx, edi
mov dword [esp + 0x40], edi
xor ecx, dword [eax + 8]
mov dword [esp + 0x40], ecx
mov ecx, dword [esp + 0x10]
movzx ecx, ch
xor edx, dword [ecx*4 + 0x46afc0]
movzx ecx, byte [esp + 0x2a]
xor edx, dword [ecx*4 + 0x46b3c0]
movzx ecx, bl
xor edx, dword [ecx*4 + 0x46abc0]
xor edx, dword [eax + 0xc]
mov dword [esp + 0x10], edx
sub ebp, 1
je 0x403254
mov ecx, dword [esp + 0x40]
shr ecx, 0x10
movzx edx, cl
mov ecx, dword [esp + 0x38]
shr ecx, 8
movzx ecx, cl
mov edx, dword [edx*4 + 0x46b3c0]
mov esi, dword [esp + 0x10]
mov ebx, dword [esp + 0x20]
xor edx, dword [ecx*4 + 0x46afc0]
mov ecx, esi
shr ecx, 0x18
xor edx, dword [ecx*4 + 0x46b7c0]
movzx ecx, bl
xor edx, dword [ecx*4 + 0x46abc0]
mov ecx, esi
xor edx, dword [eax + 0x10]
shr ecx, 0x10
mov dword [esp + 0x18], edx
movzx edx, cl
mov ecx, dword [esp + 0x40]
shr ecx, 8
movzx ecx, cl
mov edx, dword [edx*4 + 0x46b3c0]
xor edx, dword [ecx*4 + 0x46afc0]
mov ecx, ebx
shr ecx, 0x18
xor edx, dword [ecx*4 + 0x46b7c0]
mov ecx, dword [esp + 0x38]
movzx ecx, cl
xor edx, dword [ecx*4 + 0x46abc0]
mov ecx, esi
xor edx, dword [eax + 0x14]
shr ecx, 8
mov dword [esp + 0x14], edx
movzx edx, cl
mov ecx, ebx
shr ecx, 0x10
movzx ecx, cl
shr ebx, 8
mov edx, dword [edx*4 + 0x46afc0]
xor edx, dword [ecx*4 + 0x46b3c0]
mov ecx, dword [esp + 0x38]
shr ecx, 0x18
xor edx, dword [ecx*4 + 0x46b7c0]
mov ecx, dword [esp + 0x40]
movzx ecx, cl
xor edx, dword [ecx*4 + 0x46abc0]
xor edx, dword [eax + 0x18]
mov ecx, dword [esp + 0x38]
shr ecx, 0x10
mov dword [esp + 0x1c], edx
movzx edx, cl
movzx ecx, bl
mov ebx, dword [edx*4 + 0x46b3c0]
xor ebx, dword [ecx*4 + 0x46afc0]
mov ecx, dword [esp + 0x40]
shr ecx, 0x18
xor ebx, dword [ecx*4 + 0x46b7c0]
mov ecx, esi
movzx ecx, cl
xor ebx, dword [ecx*4 + 0x46abc0]
mov ecx, dword [esp + 0x1c]
xor ebx, dword [eax + 0x1c]
add eax, 0x20
sar ecx, 0x10
movzx edx, cl
mov ecx, dword [esp + 0x14]
sar ecx, 8
movzx ecx, cl
mov edx, dword [edx*4 + 0x46b3c0]
xor edx, dword [ecx*4 + 0x46afc0]
mov ecx, ebx
shr ecx, 0x18
xor edx, dword [ecx*4 + 0x46b7c0]
mov ecx, dword [esp + 0x18]
movzx ecx, cl
xor edx, dword [ecx*4 + 0x46abc0]
xor edx, dword [eax]
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x20], edx
sar ecx, 8
movzx edx, cl
mov ecx, ebx
shr ecx, 0x10
movzx ecx, cl
mov edx, dword [edx*4 + 0x46afc0]
xor edx, dword [ecx*4 + 0x46b3c0]
mov ecx, dword [esp + 0x18]
mov esi, edx
shr ecx, 0x18
mov dword [esp + 0x38], edx
xor esi, dword [ecx*4 + 0x46b7c0]
mov ecx, dword [esp + 0x14]
movzx ecx, cl
xor esi, dword [ecx*4 + 0x46abc0]
mov ecx, esi
mov dword [esp + 0x38], esi
xor ecx, dword [eax + 4]
mov dword [esp + 0x38], ecx
mov ecx, dword [esp + 0x18]
sar ecx, 0x10
movzx edx, cl
mov ecx, ebx
shr ecx, 8
movzx ecx, cl
mov edx, dword [edx*4 + 0x46b3c0]
xor edx, dword [ecx*4 + 0x46afc0]
mov dword [esp + 0x40], edx
mov edx, dword [esp + 0x14]
mov ecx, edx
mov edi, dword [esp + 0x40]
shr ecx, 0x18
sar edx, 0x10
movzx edx, dl
xor edi, dword [ecx*4 + 0x46b7c0]
mov ecx, dword [esp + 0x1c]
mov edx, dword [edx*4 + 0x46b3c0]
movzx ecx, cl
xor edi, dword [ecx*4 + 0x46abc0]
mov ecx, edi
mov dword [esp + 0x40], edi
xor ecx, dword [eax + 8]
mov dword [esp + 0x40], ecx
mov ecx, dword [esp + 0x18]
sar ecx, 8
movzx ecx, cl
xor edx, dword [ecx*4 + 0x46afc0]
mov ecx, dword [esp + 0x1c]
shr ecx, 0x18
xor edx, dword [ecx*4 + 0x46b7c0]
movzx ecx, bl
xor edx, dword [ecx*4 + 0x46abc0]
xor edx, dword [eax + 0xc]
mov dword [esp + 0x10], edx
sub ebp, 1
jne 0x403023
mov ecx, edx
mov ebx, dword [esp + 0x20]
shr ecx, 0x18
mov esi, dword [esp + 0x3c]
movzx edx, byte [ecx + str.cw]
mov ecx, dword [esp + 0x40]
shr ecx, 0x10
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x38]
shr ecx, 8
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
movzx ecx, bl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x10]
xor edx, dword [eax + 0x10]
shr ecx, 0x10
movzx ecx, cl
mov dword [esi], edx
movzx edx, byte [ecx + str.cw]
mov ecx, ebx
shr ecx, 0x18
movzx ecx, byte [ecx + str.cw]
shl ecx, 8
or edx, ecx
mov ecx, dword [esp + 0x40]
shr ecx, 8
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x38]
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x38]
xor edx, dword [eax + 0x14]
shr ecx, 0x18
mov dword [esi + 4], edx
movzx edx, byte [ecx + str.cw]
mov ecx, ebx
shr ecx, 0x10
movzx ecx, cl
shl edx, 8
shr ebx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x10]
shr ecx, 8
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x40]
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x40]
xor edx, dword [eax + 0x18]
shr ecx, 0x18
mov dword [esi + 8], edx
movzx edx, byte [ecx + str.cw]
mov ecx, dword [esp + 0x38]
shr ecx, 0x10
movzx ecx, cl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
movzx ecx, bl
shl edx, 8
movzx ecx, byte [ecx + str.cw]
or edx, ecx
mov ecx, dword [esp + 0x10]
movzx ecx, cl
shl edx, 8
pop edi
movzx ecx, byte [ecx + str.cw]
or edx, ecx
xor edx, dword [eax + 0x1c]
mov dword [esi + 0xc], edx
pop esi
pop ebp
pop ebx
add esp, 0x24
ret 0xc