Merge "Keystore 2.0 SPI: Silence warning about blocking calls to Keystore."
This commit is contained in:
@ -19,6 +19,7 @@ package android.security;
|
||||
import android.annotation.NonNull;
|
||||
import android.compat.annotation.ChangeId;
|
||||
import android.compat.annotation.Disabled;
|
||||
import android.os.Binder;
|
||||
import android.os.RemoteException;
|
||||
import android.os.ServiceManager;
|
||||
import android.os.ServiceSpecificException;
|
||||
@ -140,6 +141,7 @@ public class KeyStore2 {
|
||||
if (mBinder == null || retryLookup) {
|
||||
mBinder = IKeystoreService.Stub.asInterface(ServiceManager
|
||||
.getService(KEYSTORE2_SERVICE_NAME));
|
||||
Binder.allowBlocking(mBinder.asBinder());
|
||||
}
|
||||
return mBinder;
|
||||
}
|
||||
|
@ -18,6 +18,7 @@ package android.security;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.hardware.security.keymint.KeyParameter;
|
||||
import android.os.Binder;
|
||||
import android.os.RemoteException;
|
||||
import android.os.ServiceSpecificException;
|
||||
import android.security.keymaster.KeymasterDefs;
|
||||
@ -39,6 +40,7 @@ public class KeyStoreOperation {
|
||||
Long challenge,
|
||||
KeyParameter[] parameters
|
||||
) {
|
||||
Binder.allowBlocking(operation.asBinder());
|
||||
this.mOperation = operation;
|
||||
this.mChallenge = challenge;
|
||||
this.mParameters = parameters;
|
||||
|
@ -19,6 +19,7 @@ package android.security;
|
||||
import android.annotation.NonNull;
|
||||
import android.app.compat.CompatChanges;
|
||||
import android.hardware.security.keymint.KeyParameter;
|
||||
import android.os.Binder;
|
||||
import android.os.RemoteException;
|
||||
import android.os.ServiceSpecificException;
|
||||
import android.security.keystore.BackendBusyException;
|
||||
@ -45,6 +46,7 @@ public class KeyStoreSecurityLevel {
|
||||
private final IKeystoreSecurityLevel mSecurityLevel;
|
||||
|
||||
public KeyStoreSecurityLevel(IKeystoreSecurityLevel securityLevel) {
|
||||
Binder.allowBlocking(securityLevel.asBinder());
|
||||
this.mSecurityLevel = securityLevel;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user