optimization: autoreleasepool added to the for loop

If your code contains a tight loop that creates lots of temporary
objects, you can use the @autorelease directive to optimize for these
short-lived, locally-scoped objects by being more aggressive about how
they're deallocated.
rcencrypt changed to encryption