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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov eax, dword [0x602c60]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
mov edx, dword [ebx + 0x1c]
xor eax, eax
sub edx, 6
push esi
push edi
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], eax
cmp edx, eax
jle 0x4582f7
mov esi, dword [ebp + 0xc]
mov ecx, edx
lea edi, [ebp - 0x24]
rep movsd dword es:[edi], dword [esi]
test edx, edx
jle 0x458335
push 8
pop ecx
mov esi, dword [ebp - 0x2c]
cmp esi, dword [ebx + 0x1c]
ja 0x458335
jmp 0x45831d
mov esi, dword [ebp - 0x28]
cmp esi, 4
jge 0x458321
mov edi, dword [ebp + eax*4 - 0x24]
add esi, ecx
inc eax
inc dword [ebp - 0x28]
mov dword [ebx + esi*4], edi
cmp eax, edx
jl 0x458308
cmp dword [ebp - 0x28], 4
jne 0x458331
inc dword [ebp - 0x2c]
add ecx, 4
and dword [ebp - 0x28], 0
cmp eax, edx
jl 0x4582fe
mov esi, dword [ebp - 0x2c]
cmp esi, dword [ebx + 0x1c]
ja 0x458473
mov eax, edx
lea ecx, [ebp + eax*4 - 0x27]
mov dword [ebp - 0x34], ecx
lea ecx, [ebp + eax*4 - 0x26]
mov dword [ebp - 0x40], ecx
lea ecx, [ebp + eax*4 - 0x25]
lea eax, [ebp + eax*4 - 0x28]
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x30], 0x6016a8
mov eax, dword [ebp - 0x34]
movzx ecx, byte [eax]
mov al, byte [ebp - 0x24]
xor al, byte [ecx + str.cw]
mov ecx, dword [ebp - 0x40]
mov byte [ebp - 0x24], al
movzx ecx, byte [ecx]
mov cl, byte [ecx + str.cw]
xor byte [ebp - 0x23], cl
mov ecx, dword [ebp - 0x3c]
movzx ecx, byte [ecx]
mov cl, byte [ecx + str.cw]
xor byte [ebp - 0x22], cl
mov ecx, dword [ebp - 0x38]
movzx ecx, byte [ecx]
mov cl, byte [ecx + str.cw]
xor byte [ebp - 0x21], cl
mov ecx, dword [ebp - 0x30]
xor al, byte [ecx]
add dword [ebp - 0x30], 4
xor ecx, ecx
inc ecx
mov byte [ebp - 0x24], al
cmp edx, 8
je 0x4583ce
cmp edx, ecx
jle 0x458425
mov edi, dword [ebp + ecx*4 - 0x28]
lea eax, [ebp + ecx*4 - 0x24]
xor dword [eax], edi
inc ecx
cmp ecx, edx
jl 0x4583bd
jmp 0x458425
mov edi, dword [ebp + ecx*4 - 0x28]
lea eax, [ebp + ecx*4 - 0x24]
xor dword [eax], edi
inc ecx
cmp ecx, 4
jl 0x4583ce
movzx eax, byte [ebp - 0x18]
mov al, byte [eax + str.cw]
xor byte [ebp - 0x14], al
movzx eax, byte [ebp - 0x17]
mov al, byte [eax + str.cw]
xor byte [ebp - 0x13], al
movzx eax, byte [ebp - 0x16]
mov al, byte [eax + str.cw]
xor byte [ebp - 0x12], al
movzx eax, byte [ebp - 0x15]
mov al, byte [eax + str.cw]
xor byte [ebp - 0x11], al
push 5
pop ecx
mov edi, dword [ebp + ecx*4 - 0x28]
lea eax, [ebp + ecx*4 - 0x24]
xor dword [eax], edi
inc ecx
cmp ecx, 8
jl 0x458415
xor eax, eax
test edx, edx
jle 0x45846a
lea ecx, [esi*4 + 8]
cmp esi, dword [ebx + 0x1c]
ja 0x458473
jmp 0x45844e
mov esi, dword [ebp - 0x28]
cmp esi, 4
jge 0x458452
mov edi, dword [ebp + eax*4 - 0x24]
add esi, ecx
inc eax
inc dword [ebp - 0x28]
mov dword [ebx + esi*4], edi
cmp eax, edx
jl 0x458439
cmp dword [ebp - 0x28], 4
mov esi, dword [ebp - 0x2c]
jne 0x458466
inc esi
add ecx, 4
and dword [ebp - 0x28], 0
mov dword [ebp - 0x2c], esi
cmp eax, edx
jl 0x458432
cmp esi, dword [ebx + 0x1c]
jbe 0x458366
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004fb958
leave
ret