diff options
author | Alex Klyubin <klyubin@google.com> | 2015-04-16 20:20:15 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-04-16 20:20:15 +0000 |
commit | b1aa7d0bc821614d943075c0d786cc3f5eeb8c73 (patch) | |
tree | 776ac8092fb497ee8092a20c53a51c80a566ea57 /keystore | |
parent | 186fe7b10f475fdccb3bcab19461bd2900347b71 (diff) | |
parent | 51884f0e066bcf1ba5e039cd8a24a87139b5a01c (diff) | |
download | frameworks_base-b1aa7d0bc821614d943075c0d786cc3f5eeb8c73.zip frameworks_base-b1aa7d0bc821614d943075c0d786cc3f5eeb8c73.tar.gz frameworks_base-b1aa7d0bc821614d943075c0d786cc3f5eeb8c73.tar.bz2 |
am 51884f0e: am 499126c4: Merge "Add Keymaster KM_ORIGIN_UNKNOWN constant."
* commit '51884f0e066bcf1ba5e039cd8a24a87139b5a01c':
Add Keymaster KM_ORIGIN_UNKNOWN constant.
Diffstat (limited to 'keystore')
-rw-r--r-- | keystore/java/android/security/KeyStoreKeyProperties.java | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/keystore/java/android/security/KeyStoreKeyProperties.java b/keystore/java/android/security/KeyStoreKeyProperties.java index d8ad1d3..1077af4 100644 --- a/keystore/java/android/security/KeyStoreKeyProperties.java +++ b/keystore/java/android/security/KeyStoreKeyProperties.java @@ -226,14 +226,24 @@ public abstract class KeyStoreKeyProperties { public static final int IMPORTED = 1 << 1; /** + * Origin of the key is unknown. This can occur only for keys backed by an old TEE + * implementation which does not record origin information. + * + * @hide + */ + public static final int UNKNOWN = 1 << 2; + + /** * @hide */ public static @OriginEnum int fromKeymaster(int origin) { switch (origin) { - case KeymasterDefs.KM_ORIGIN_HARDWARE: + case KeymasterDefs.KM_ORIGIN_GENERATED: return GENERATED; case KeymasterDefs.KM_ORIGIN_IMPORTED: return IMPORTED; + case KeymasterDefs.KM_ORIGIN_UNKNOWN: + return UNKNOWN; default: throw new IllegalArgumentException("Unknown origin: " + origin); } |