I am looking for an example to encrypt and save a file with individual aes key ( derived from internal imx6 key something similar)
It will be helpful if someone can point to some Documentations or Examples.
Here is a short description of the tasks I'm trying to achieve:
1. Encrypt a file and generate a blob:
Eg: encrypt.sh -f fileToEncrypt -o Blobfile
2. Decrypt the blob to generate the file:
Eg: decrypt.sh -i Blob -o decryptedFile
encrypt.sh -i "TextToEncrypt" -o Blobfile
decrypt.sh -o Blobfile > decryptedFile
My goal is to create an encrypted file which cannot be decrypted on any other CPU.
Goal. It's schould not possible to decrypt the File on other CPU.
PS: I can't use OpenSSL and I don't want to encrypt the whole Image, only one file.