summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShawn Willden <swillden@google.com>2015-06-03 05:37:45 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-06-03 05:37:48 +0000
commitcbc5834cc742a66511a586e3001e57378ad361b0 (patch)
treeb32afdc36a635e9d637df4783ee8d5534f2c5bed
parentb248e7125b6068105242fa26e59be0ac2abdcbef (diff)
parent4144c64818fcb88905bc2632e3747be3681a1405 (diff)
downloadhardware_libhardware-cbc5834cc742a66511a586e3001e57378ad361b0.zip
hardware_libhardware-cbc5834cc742a66511a586e3001e57378ad361b0.tar.gz
hardware_libhardware-cbc5834cc742a66511a586e3001e57378ad361b0.tar.bz2
Merge "Remove KM_TAG_CHUNK_LENGTH and add KM_TAG_AEAD_TAG" into mnc-dev
-rw-r--r--include/hardware/keymaster_defs.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/include/hardware/keymaster_defs.h b/include/hardware/keymaster_defs.h
index 4e769d5..9eb0c0f 100644
--- a/include/hardware/keymaster_defs.h
+++ b/include/hardware/keymaster_defs.h
@@ -58,9 +58,7 @@ typedef enum {
KM_TAG_BLOCK_MODE = KM_ENUM_REP | 4, /* keymaster_block_mode_t. */
KM_TAG_DIGEST = KM_ENUM_REP | 5, /* keymaster_digest_t. */
KM_TAG_PADDING = KM_ENUM_REP | 6, /* keymaster_padding_t. */
- KM_TAG_RETURN_UNAUTHED = KM_BOOL | 7, /* Allow AEAD decryption to return plaintext before it has
- been authenticated. WARNING: Not recommended. */
- KM_TAG_CALLER_NONCE = KM_BOOL | 8, /* Allow caller to specify nonce or IV. */
+ KM_TAG_CALLER_NONCE = KM_BOOL | 7, /* Allow caller to specify nonce or IV. */
/* Algorithm-specific. */
KM_TAG_RSA_PUBLIC_EXPONENT = KM_LONG | 200, /* Defaults to 2^16+1 */
@@ -123,8 +121,9 @@ typedef enum {
/* Tags used only to provide data to or receive data from operations */
KM_TAG_ASSOCIATED_DATA = KM_BYTES | 1000, /* Used to provide associated data for AEAD modes. */
KM_TAG_NONCE = KM_BYTES | 1001, /* Nonce or Initialization Vector */
- KM_TAG_CHUNK_LENGTH = KM_INT | 1002, /* AEAD mode chunk size, in bytes. 0 means no limit,
- which requires KM_TAG_RETURN_UNAUTHED. */
+ KM_TAG_AEAD_TAG = KM_BYTES | 1002, /* AEAD tag data. Returned from finish() during AEAD
+ * encryption and provided to begin() during AEAD
+ * decryption.*/
KM_TAG_AUTH_TOKEN = KM_BYTES | 1003, /* Authentication token that proves secure user
authentication has been performed. Structure
defined in hw_auth_token_t in hw_auth_token.h. */
@@ -338,7 +337,7 @@ typedef enum {
KM_ERROR_UNSUPPORTED_EC_FIELD = -50,
KM_ERROR_MISSING_NONCE = -51,
KM_ERROR_INVALID_NONCE = -52,
- KM_ERROR_UNSUPPORTED_CHUNK_LENGTH = -53,
+ KM_ERROR_MISSING_MAC_LENGTH = -53,
KM_ERROR_CALLER_NONCE_PROHIBITED = -55,
KM_ERROR_UNIMPLEMENTED = -100,