Gurpartap/AESCrypt-ObjC — pull request #9 by unixmonkey (2014-04-06 04:48:53+00:00)
Title: Encrypt and decrypt directly to NSData

Hey, thanks for this project. It came in handy for me today.

I'm using it to encrypt/decrypt some binary data, rather than strings, so these extensions are exactly what I needed. I figure they may help others, too.

Usage:

NSData *plainData = [NSData dataWithContentsOfFile:someBinaryFile];
NSString *password = @"p4ssw0rd";
NSData *encryptedData = [AESCrypt encryptData:plainData password:password];
NSData *decryptedData = [AESCrypt decryptData:encryptedData password:password];

If there's anything I can do to make this better, please let me know!