summaryrefslogtreecommitdiffstats
path: root/core/java/android/security
diff options
context:
space:
mode:
authorKenny Root <kroot@google.com>2013-03-29 11:14:17 -0700
committerKenny Root <kroot@google.com>2013-03-29 14:21:10 -0700
commit5cb5cec6a4a4d5432d4ce6468c12de9508db1633 (patch)
tree0778665976a92cdaf2943e551c72ef5fbb41f558 /core/java/android/security
parent2fb669e68f771f07517b8d5087ca875025b9bcfb (diff)
downloadframeworks_base-5cb5cec6a4a4d5432d4ce6468c12de9508db1633.zip
frameworks_base-5cb5cec6a4a4d5432d4ce6468c12de9508db1633.tar.gz
frameworks_base-5cb5cec6a4a4d5432d4ce6468c12de9508db1633.tar.bz2
KeyStore: add API to query storage type
Add an API to keystore daemon to query what kind of storage is currently in use. (cherry picked from commit a738e2a1aee26e0be3944c11820724aeca313f83) Change-Id: I52c84449a27b1cefc49372a6406b7132c2bbddee
Diffstat (limited to 'core/java/android/security')
-rw-r--r--core/java/android/security/IKeystoreService.java20
1 files changed, 20 insertions, 0 deletions
diff --git a/core/java/android/security/IKeystoreService.java b/core/java/android/security/IKeystoreService.java
index a890d9b..c365643 100644
--- a/core/java/android/security/IKeystoreService.java
+++ b/core/java/android/security/IKeystoreService.java
@@ -427,6 +427,23 @@ public interface IKeystoreService extends IInterface {
}
return _result;
}
+
+ @Override
+ public int is_hardware_backed() throws RemoteException {
+ Parcel _data = Parcel.obtain();
+ Parcel _reply = Parcel.obtain();
+ int _result;
+ try {
+ _data.writeInterfaceToken(DESCRIPTOR);
+ mRemote.transact(Stub.TRANSACTION_is_hardware_backed, _data, _reply, 0);
+ _reply.readException();
+ _result = _reply.readInt();
+ } finally {
+ _reply.recycle();
+ _data.recycle();
+ }
+ return _result;
+ }
}
private static final String DESCRIPTOR = "android.security.keystore";
@@ -452,6 +469,7 @@ public interface IKeystoreService extends IInterface {
static final int TRANSACTION_ungrant = IBinder.FIRST_CALL_TRANSACTION + 18;
static final int TRANSACTION_getmtime = IBinder.FIRST_CALL_TRANSACTION + 19;
static final int TRANSACTION_duplicate = IBinder.FIRST_CALL_TRANSACTION + 20;
+ static final int TRANSACTION_is_hardware_backed = IBinder.FIRST_CALL_TRANSACTION + 21;
/**
* Cast an IBinder object into an IKeystoreService interface, generating
@@ -539,4 +557,6 @@ public interface IKeystoreService extends IInterface {
public int duplicate(String srcKey, int srcUid, String destKey, int destUid)
throws RemoteException;
+
+ public int is_hardware_backed() throws RemoteException;
}