commit | 8f75adc624c70dfd597b7fc3aab993a7d5815f4c | [log] [tgz] |
---|---|---|
author | Tucker Sylvestro <tuckeris@google.com> | Thu Oct 06 16:13:48 2016 +0000 |
committer | android-build-merger <android-build-merger@google.com> | Thu Oct 06 16:13:48 2016 +0000 |
tree | f0254eed5c074f872a47e2a3312596c92efb7c26 | |
parent | 67c1ee6ed40bd6ccf899db32e9977a636e040c65 [diff] | |
parent | b32aae2a46bc3678e11c7f0ca88e01a192829490 [diff] |
Add the onDeviceOffBody API method to KeyStore am: b32aae2a46 Change-Id: Idbf7f1d505b1d446a3d648dcf1b0f334a629110a
diff --git a/core/java/android/security/IKeystoreService.aidl b/core/java/android/security/IKeystoreService.aidl index 8689dce..641e1ad 100644 --- a/core/java/android/security/IKeystoreService.aidl +++ b/core/java/android/security/IKeystoreService.aidl
@@ -76,4 +76,5 @@ int onUserAdded(int userId, int parentId); int onUserRemoved(int userId); int attestKey(String alias, in KeymasterArguments params, out KeymasterCertificateChain chain); + int onDeviceOffBody(); }
diff --git a/keystore/java/android/security/KeyStore.java b/keystore/java/android/security/KeyStore.java index 70e4b6f..00d786a 100644 --- a/keystore/java/android/security/KeyStore.java +++ b/keystore/java/android/security/KeyStore.java
@@ -626,6 +626,16 @@ } } + /** + * Notify keystore that the device went off-body. + */ + public void onDeviceOffBody() { + try { + mBinder.onDeviceOffBody(); + } catch (RemoteException e) { + Log.w(TAG, "Cannot connect to keystore", e); + } + } /** * Returns a {@link KeyStoreException} corresponding to the provided keystore/keymaster error