| java.lang.Object | |
| ↳ | com.datalogic.device.KeychainManager |
The KeychainManager class provides access to the device keychain service,
allowing applications to manage certificates installed on the device.
Supported only on devices running Android 15 or later.
Obtain an instance by calling the constructor. The service connection is established
at construction time and a DeviceException is thrown if
the underlying service is unavailable.
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
This is the constructor of KeychainManager.
| |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Installs a CA certificate into the device's trusted certificate store.
| |||||||||||
Removes a CA certificate from the device's trusted certificate store.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
This is the constructor of KeychainManager.
| DeviceException | in case of error. |
|---|
Installs a CA certificate into the device's trusted certificate store.
The certificate must be DER-encoded. Once installed, the certificate is trusted system-wide for SSL/TLS connections and other certificate-chain validation on the device.
| certBuffer | the encoded CA certificate to install; must not be null. |
|---|
true if the certificate was installed successfully, or if it
was already installed, false otherwise.| DeviceException | if a communication error with the keychain service occurs. |
|---|
Removes a CA certificate from the device's trusted certificate store.
The certificate is identified by its encoded bytes, which are provided when the certificate is installed. Once removed, the certificate is no longer trusted system-wide for SSL/TLS connections and other certificate-chain validation on the device.
| certBuffer | the encoded CA certificate to remove; must not be null or empty. |
|---|
true if the certificate was removed successfully,
false otherwise.| DeviceException | if a communication error with the keychain service occurs. |
|---|