Note that there are some explanatory texts on larger screens.

plurals
  1. PODecrypt aes-file in iOS encrypted using a tool from AESCrypt.com
    primarykey
    data
    text
    <p>I'm working on an app that among other things plays sound files. My problem is the sound files are encrypted with a command line tool that can be found on <a href="https://www.aescrypt.com/download/" rel="nofollow">aescrypt.com</a> just providing the file and a password. I have used the java-code on aescrypt.com to successfully decrypt the files in the android app but I can't for the life of me not get it to work in iOS. </p> <p>I have tried to decrypt all the bytes of the file and the bytes that does not include the header of the file. I get a result set of bytes back but it won't play and the estimated length of the sound is about one fourth of the actual length. </p> <pre><code>NSRange range = NSMakeRange(0, self.length); unsigned char* encrypteddata = malloc(range.length); [self getBytes:encrypteddata range:range]; size_t outSize; unsigned char* result = malloc(range.length + 16); CCCryptorStatus status = CCCrypt(kCCEncrypt, kCCAlgorithmAES128, 0x00, decryptkey, sizeof(decryptkey), nil, encrypteddata, self.length, result, self.length + 16, &amp;outSize); NSData *returnData = nil; if (status == kCCSuccess) { returnData = [NSData dataWithBytesNoCopy:result length:outSize]; } </code></pre> <p>The decryptkey is just the bytes from the password used to encrypt the file.</p> <p>I have been working on a solution for at least a week now and not made any progress. There are so many things that can be done wrong and so many possible (and impossible) combinations.</p> <p><strong>Update:</strong> What I need is a tool that is simple enough for our customer to use to encrypt the sound files on their end and also is simple for the apps both on Android and iOS to decrypt on the other end. It does not need to be very secure, it only needs to prevent the common user on Android from just opening and play the file from disc. If aescrypt.com tools isn't optimal for this, I gladly welcome other suggestions.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload