Add ROLLBACK_RESISTANCE definition to for KM4
* Add ROLLBACK_RESISTANCE tag
* Add ROLLBACK_RESISTANCE_UNAVAILABLE error code
Test: m libkeymaster_messages
Change-Id: Ib69a0c0f179f894b488da8608e6005e68450453a
(cherry picked from commit df2f2301a30e236853a69d34ff4082f9e19ab7e2)
(cherry picked from commit 6f48a11a79e4bba7e86e3dbcc46205a607daef38)
diff --git a/include/hardware/keymaster_defs.h b/include/hardware/keymaster_defs.h
index eca484c..d92ce00 100644
--- a/include/hardware/keymaster_defs.h
+++ b/include/hardware/keymaster_defs.h
@@ -75,6 +75,8 @@
/* Other hardware-enforced. */
KM_TAG_BLOB_USAGE_REQUIREMENTS = KM_ENUM | 301, /* keymaster_key_blob_usage_requirements_t */
KM_TAG_BOOTLOADER_ONLY = KM_BOOL | 302, /* Usable only by bootloader */
+ KM_TAG_ROLLBACK_RESISTANCE = KM_BOOL | 303, /* Hardware enforced deletion with deleteKey
+ * or deleteAllKeys is supported */
/*
* Tags that should be semantically enforced by hardware if possible and will otherwise be
@@ -456,6 +458,7 @@
KM_ERROR_KEYMASTER_NOT_CONFIGURED = -64,
KM_ERROR_ATTESTATION_APPLICATION_ID_MISSING = -65,
KM_ERROR_CANNOT_ATTEST_IDS = -66,
+ KM_ERROR_ROLLBACK_RESISTANCE_UNAVAILABLE = -67,
KM_ERROR_NO_USER_CONFIRMATION = -71,
KM_ERROR_DEVICE_LOCKED = -72,