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

Disassembly:
sub esp, 0x28
xor eax, eax
push ebx
push ebp
mov ebp, ecx
push esi
push edi
mov ebx, dword [ebp + 0x1c]
sub ebx, 6
cmp ebx, eax
jle 0x4c8c01
mov esi, dword [esp + 0x3c]
mov ecx, ebx
lea edi, [esp + 0x18]
rep movsd dword es:[edi], dword [esi]
xor ecx, ecx
cmp ebx, eax
mov dword [esp + 0x3c], eax
jle 0x4c8c5f
mov dword [esp + 0x10], 8
mov edx, dword [esp + 0x3c]
mov esi, dword [ebp + 0x1c]
cmp edx, esi
ja 0x4c8c5f
cmp ecx, ebx
jge 0x4c8c40
lea edx, [esp + ecx*4 + 0x18]
cmp eax, 4
jge 0x4c8c43
mov esi, dword [esp + 0x10]
mov edi, dword [edx]
add esi, eax
inc ecx
add edx, 4
inc eax
cmp ecx, ebx
mov dword [ebp + esi*4], edi
jl 0x4c8c26
cmp eax, 4
jne 0x4c8c5b
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x3c]
add eax, 4
inc edx
mov dword [esp + 0x10], eax
mov dword [esp + 0x3c], edx
xor eax, eax
cmp ecx, ebx
jl 0x4c8c13
mov ecx, dword [esp + 0x3c]
mov edx, dword [ebp + 0x1c]
cmp ecx, edx
ja 0x4c8dfe
mov esi, 0x58f3cc
jmp 0x4c8c79
mov esi, dword [esp + 0x14]
mov cl, byte [esp + 0x18]
xor edx, edx
mov dl, byte [esp + ebx*4 + 0x15]
add esi, 4
mov dword [esp + 0x14], esi
xor cl, byte [edx + str.cw]
xor edx, edx
mov byte [esp + 0x18], cl
mov dl, byte [esp + ebx*4 + 0x16]
mov dl, byte [edx + str.cw]
xor byte [esp + 0x19], dl
xor edx, edx
mov dl, byte [esp + ebx*4 + 0x17]
mov dl, byte [edx + str.cw]
xor byte [esp + 0x1a], dl
xor edx, edx
mov dl, byte [esp + ebx*4 + 0x14]
mov dl, byte [edx + str.cw]
xor byte [esp + 0x1b], dl
mov dl, byte [esi - 4]
xor cl, dl
cmp ebx, 8
mov byte [esp + 0x18], cl
je 0x4c8cf6
cmp ebx, 1
jle 0x4c8d8e
lea ecx, [esp + 0x1c]
lea edx, [ebx - 1]
mov esi, dword [ecx - 4]
mov edi, dword [ecx]
xor edi, esi
mov dword [ecx], edi
add ecx, 4
dec edx
jne 0x4c8ce2
jmp 0x4c8d8e
lea ecx, [esp + 0x1c]
mov edx, 3
mov esi, dword [ecx - 4]
mov edi, dword [ecx]
xor edi, esi
mov dword [ecx], edi
add ecx, 4
dec edx
jne 0x4c8cff
mov ecx, dword [esp + 0x24]
and ecx, 0xff
mov dl, byte [ecx + str.cw]
mov cl, byte [esp + 0x28]
xor cl, dl
mov byte [esp + 0x28], cl
mov ecx, dword [esp + 0x25]
and ecx, 0xff
mov dl, byte [ecx + str.cw]
mov cl, byte [esp + 0x29]
xor cl, dl
mov byte [esp + 0x29], cl
mov ecx, dword [esp + 0x26]
and ecx, 0xff
mov dl, byte [ecx + str.cw]
mov cl, byte [esp + 0x2a]
xor cl, dl
mov byte [esp + 0x2a], cl
mov ecx, dword [esp + 0x27]
and ecx, 0xff
mov dl, byte [ecx + str.cw]
mov cl, byte [esp + 0x2b]
xor cl, dl
mov edx, 3
mov byte [esp + 0x2b], cl
lea ecx, [esp + 0x2c]
mov esi, dword [ecx - 4]
mov edi, dword [ecx]
xor edi, esi
mov dword [ecx], edi
add ecx, 4
dec edx
jne 0x4c8d7f
xor ecx, ecx
test ebx, ebx
jle 0x4c8def
mov edx, dword [esp + 0x3c]
lea edx, [edx*4 + 8]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x3c]
mov esi, dword [ebp + 0x1c]
cmp edx, esi
ja 0x4c8def
cmp ecx, ebx
jge 0x4c8dd0
lea edx, [esp + ecx*4 + 0x18]
cmp eax, 4
jge 0x4c8dd3
mov esi, dword [esp + 0x10]
mov edi, dword [edx]
add esi, eax
inc ecx
add edx, 4
inc eax
cmp ecx, ebx
mov dword [ebp + esi*4], edi
jl 0x4c8db6
cmp eax, 4
jne 0x4c8deb
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x3c]
add eax, 4
inc edx
mov dword [esp + 0x10], eax
mov dword [esp + 0x3c], edx
xor eax, eax
cmp ecx, ebx
jl 0x4c8da3
mov ecx, dword [esp + 0x3c]
mov edx, dword [ebp + 0x1c]
cmp ecx, edx
jbe 0x4c8c75
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x28
ret 4