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

Disassembly:
mov edx, dword [esp + 8]
push ebx
mov ebx, dword [esp + 8]
push ebp
push esi
push edi
push 4
xor edi, edi
mov dword [ebx + 0x200], 0xa
mov esi, ebx
add edx, 2
pop ebp
movzx ecx, byte [edx - 2]
movzx eax, byte [edx - 1]
shl ecx, 8
or ecx, eax
movzx eax, byte [edx]
shl ecx, 8
or ecx, eax
movzx eax, byte [edx + 1]
shl ecx, 8
add edx, ebp
or ecx, eax
mov dword [ebx + edi*4], ecx
inc edi
cmp edi, ebp
jb 0x42ec58
xor edi, edi
mov edx, dword [esi + 0xc]
mov eax, edx
shr eax, 0x10
movzx eax, al
mov ecx, dword [eax*4 + str.cwko0]
mov eax, edx
shr eax, 8
shl ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + str.cwko0]
shl ecx, 8
movzx eax, dl
xor ecx, dword [eax*4 + str.cwko0]
mov eax, edx
shr eax, 0x18
shl ecx, 8
xor ecx, dword [eax*4 + str.cwko0]
xor ecx, dword [edi + 0x4d3b08]
add edi, ebp
xor ecx, dword [esi]
mov eax, dword [esi + 4]
xor eax, ecx
mov dword [esi + 0x10], ecx
mov ecx, dword [esi + 8]
xor ecx, eax
mov dword [esi + 0x14], eax
xor edx, ecx
mov dword [esi + 0x18], ecx
mov dword [esi + 0x1c], edx
add esi, 0x10
cmp edi, 0x28
jb 0x42ec82
cmp dword [0x4f2b34], 0
je 0x42ed42
xor edx, edx
mov ecx, dword [edx + str.cwko0]
mov eax, dword [ecx*4 + 0x4d2b08]
mov dword [edx + 0x51c640], eax
mov eax, dword [ecx*4 + 0x4d2f08]
mov dword [edx + 0x51ca40], eax
mov eax, dword [ecx*4 + 0x4d3308]
mov dword [edx + 0x51ce40], eax
mov eax, dword [ecx*4 + 0x4d3708]
mov dword [edx + 0x51d240], eax
add edx, ebp
cmp edx, 0x400
jb 0x42ecf7
and dword [0x4f2b34], 0
mov eax, dword [esi]
lea edi, [ebx + 0x100]
mov dword [edi], eax
add esi, ebp
add edi, ebp
mov eax, dword [esi]
add esi, ebp
mov dword [edi], eax
add edi, ebp
mov eax, dword [esi]
add esi, ebp
mov dword [edi], eax
add edi, ebp
mov eax, dword [esi]
add esi, ebp
mov dword [edi], eax
add edi, ebp
xor ebp, ebp
inc ebp
cmp dword [ebx + 0x200], ebp
jbe 0x42ee6d
mov edx, dword [esi - 0x20]
mov ecx, edx
shr ecx, 0x18
mov eax, edx
shr eax, 0x10
movzx eax, al
shr edx, 8
mov ecx, dword [ecx*4 + 0x51c640]
xor ecx, dword [eax*4 + 0x51ca40]
movzx eax, dl
xor ecx, dword [eax*4 + 0x51ce40]
movzx eax, byte [esi - 0x20]
xor ecx, dword [eax*4 + 0x51d240]
mov dword [edi], ecx
mov edx, dword [esi - 0x1c]
mov ecx, edx
shr ecx, 0x18
mov eax, edx
shr eax, 0x10
movzx eax, al
shr edx, 8
mov ecx, dword [ecx*4 + 0x51c640]
xor ecx, dword [eax*4 + 0x51ca40]
movzx eax, dl
xor ecx, dword [eax*4 + 0x51ce40]
movzx eax, byte [esi - 0x1c]
xor ecx, dword [eax*4 + 0x51d240]
mov dword [edi + 4], ecx
mov edx, dword [esi - 0x18]
mov ecx, edx
shr ecx, 0x18
mov eax, edx
shr eax, 0x10
movzx eax, al
shr edx, 8
mov ecx, dword [ecx*4 + 0x51c640]
xor ecx, dword [eax*4 + 0x51ca40]
movzx eax, dl
xor ecx, dword [eax*4 + 0x51ce40]
movzx eax, byte [esi - 0x18]
xor ecx, dword [eax*4 + 0x51d240]
mov dword [edi + 8], ecx
mov edx, dword [esi - 0x14]
mov ecx, edx
shr ecx, 0x18
mov eax, edx
shr eax, 0x10
movzx eax, al
shr edx, 8
mov ecx, dword [ecx*4 + 0x51c640]
xor ecx, dword [eax*4 + 0x51ca40]
movzx eax, dl
xor ecx, dword [eax*4 + 0x51ce40]
movzx eax, byte [esi - 0x14]
add esi, 0xfffffff0
xor ecx, dword [eax*4 + 0x51d240]
mov dword [edi + 0xc], ecx
add edi, 0x10
inc ebp
cmp ebp, dword [ebx + 0x200]
jb 0x42ed77
mov eax, dword [esi - 0x20]
mov dword [edi], eax
mov eax, dword [esi - 0x1c]
mov dword [edi + 4], eax
mov eax, dword [esi - 0x18]
mov dword [edi + 8], eax
mov eax, dword [esi - 0x14]
mov dword [edi + 0xc], eax
pop edi
pop esi
pop ebp
pop ebx
ret