open fun encryptBytes(plain: ByteArray): ByteArray (source)
Encrypts data using the managed key.
The output of this method includes the input factors (i.e., initialization vector), ciphertext, and authentication tag as a single byte string; this output can be passed directly to decryptBytes.
plain - The "plaintext" data to encrypt
GeneralSecurityException - If the data could not be encrypted
Return
The encrypted data to be stored