diff options
author | Maggie Benthall <mbenthall@google.com> | 2013-08-08 22:35:44 -0400 |
---|---|---|
committer | Maggie Benthall <mbenthall@google.com> | 2013-08-20 14:30:36 -0400 |
commit | da51e68e582ffa017543982297c831680d201a91 (patch) | |
tree | 569121a5f1c7d504a6f499f6249de09e016b7d8e /keystore | |
parent | 0a94b9ce277ef2ec79902e3c576a50ab438dca97 (diff) | |
download | frameworks_base-da51e68e582ffa017543982297c831680d201a91.zip frameworks_base-da51e68e582ffa017543982297c831680d201a91.tar.gz frameworks_base-da51e68e582ffa017543982297c831680d201a91.tar.bz2 |
Add methods for managing CAs to DevicePolicyManager(Service)
Guard install/uninstall by enforcing that the caller have the new system-only permission MANAGE_CA_CERTIFICATES.
Also include API methods for asking whether there are any User CA certs
installed, or if one by a particular name is installed in the keystore.
CA certs will be installed via KeyChain into the TrustedCertificateStore.
Bug: 8232670
Change-Id: I17b47a452e72eb4fe556dc6db823a46c6e854be8
Diffstat (limited to 'keystore')
-rw-r--r-- | keystore/java/android/security/KeyChain.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/keystore/java/android/security/KeyChain.java b/keystore/java/android/security/KeyChain.java index 328ac5d..9ea325a 100644 --- a/keystore/java/android/security/KeyChain.java +++ b/keystore/java/android/security/KeyChain.java @@ -443,7 +443,10 @@ public final class KeyChain { } @Override public void onServiceDisconnected(ComponentName name) {} }; - boolean isBound = context.bindService(new Intent(IKeyChainService.class.getName()), + Intent intent = new Intent(IKeyChainService.class.getName()); + ComponentName comp = intent.resolveSystemService(context.getPackageManager(), 0); + intent.setComponent(comp); + boolean isBound = context.bindService(intent, keyChainServiceConnection, Context.BIND_AUTO_CREATE); if (!isBound) { |