Reputation: 11
I am trying to encrypt the file using RnCryptor in objective and decrypting it in mac using following command in terminal
Encryption code in objective c
NSData *encryptedData =[RNEncryptor encryptData:fileData withSettings:kRNCryptorAES256Settings password:aPassword error:&error];
Terminal command for mac
openssl enc -aes-256-cbc -d -in /Users/Desktop/Log.txt -out /Users/Desktop/Log1.txt
but end in error bad magic number.
Upvotes: 1
Views: 427
Reputation: 299345
RNCryptor and OpenSSL have different formats. There is a very simple command-line version of RNCryptor in the RNCryptor-objc repository. I don't believe anyone has written a full-featured command-line client.
Upvotes: 1