There is old request for file encryption and decryption. But nowadays, we sometimes need to send some secret string but not in plain text. Example, we can use public MQTT service or HTTP server, post some secret command, but in encrypted format. I think we should have the implementation of java crypto for various encryption type, built-in into the script action. Something like encrypt(text_to_encrypt, "AES", "CBC", "secretkey").
The example of the AES crypto java implementation is at here :
https://www.programcreek.com/java-api-e ... rypto.java
Android documentation for the java crypto is here (it is very extensive) :
https://developer.android.com/guide/top ... yptography
Please support all various mode of the encryption for backward compatibility. Example, although ECB is not recommended, but some old application may use and we may need to decrypt from there. The hash and hmac can be included too for completeness.
Provide default configuration for the recommended encryption mode from google, or security best practices from
https://proandroiddev.com/security-best ... 16beaaade9
Since the concept is the same, please provide the action for file based encryption/decryption too, using the same implementation. The difference is we don't init the file anymore to encrypt it inside script. Since init file text only support max 1 MB, but the files we need to encrypt can be more than that.
Post your feature requets for new triggers, conditions, actions and other improvements.
2 posts • Page 1 of 1
Index of Automagic useful thread List of my other useful posts (and others')
Excellent topic. Great information here. Thank you for such a great share!