KeyStore KeyStore Class

Definition

KeyStore is responsible for maintaining cryptographic keys and their owners.

[Android.Runtime.Register("java/security/KeyStore", ApiSince=1, DoNotGenerateAcw=true)]
public class KeyStore : Java.Lang.Object
type KeyStore = class
    inherit Object
Inheritance
KeyStoreKeyStore
Derived
Attributes

Remarks

Android platform documentation

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Constructors

KeyStore(IntPtr, JniHandleOwnership) KeyStore(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

KeyStore(KeyStoreSpi, Provider, String) KeyStore(KeyStoreSpi, Provider, String)

Constructs a new instance of KeyStore with the given arguments.

Properties

Class Class

Returns the unique instance of Class that represents this object's class.

(Inherited from Object)
DefaultType DefaultType

Returns the default type for KeyStore instances.

Handle Handle

The handle to the underlying Android instance.

(Inherited from Object)
IJavaObjectEx.IsProxy IJavaObjectEx.IsProxy Inherited from Object
IJavaObjectEx.KeyHandle IJavaObjectEx.KeyHandle Inherited from Object
IJavaObjectEx.NeedsActivation IJavaObjectEx.NeedsActivation Inherited from Object
IJavaPeerable.JniManagedPeerState IJavaPeerable.JniManagedPeerState Inherited from Object
JniIdentityHashCode JniIdentityHashCode Inherited from Object
JniPeerMembers JniPeerMembers
PeerReference PeerReference Inherited from Object
Provider Provider

Returns the provider associated with this KeyStore.

ThresholdClass ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

ThresholdType ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Type Type

Returns the type of this KeyStore.

Methods

Aliases() Aliases()

Returns an Enumeration over all alias names stored in this KeyStore.

Clone() Clone()

Creates and returns a copy of this Object.

(Inherited from Object)
ContainsAlias(String) ContainsAlias(String)

Indicates whether the given alias is present in this KeyStore.

DeleteEntry(String) DeleteEntry(String)

Deletes the entry identified with the given alias from this KeyStore.

Dispose() Dispose() Inherited from Object
Dispose(Boolean) Dispose(Boolean) Inherited from Object
EntryInstanceOf(String, Class) EntryInstanceOf(String, Class)
Equals(Object) Equals(Object)

Compares this instance with the specified object and indicates if they are equal.

(Inherited from Object)
GetCertificate(String) GetCertificate(String)

Returns the trusted certificate for the entry with the given alias.

GetCertificateAlias(Certificate) GetCertificateAlias(Certificate)

Returns the alias associated with the first entry whose certificate matches the specified certificate.

GetCertificateChain(String) GetCertificateChain(String)

Returns the certificate chain for the entry with the given alias.

GetCreationDate(String) GetCreationDate(String)

Returns the creation date of the entry with the given alias.

GetEntry(String, KeyStore+IProtectionParameter) GetEntry(String, KeyStore+IProtectionParameter)

Returns the Entry with the given alias, using the specified ProtectionParameter.

GetHashCode() GetHashCode()

Returns an integer hash code for this object.

(Inherited from Object)
GetInstance(String) GetInstance(String)

Returns a new instance of KeyStore with the specified type.

GetInstance(String, Provider) GetInstance(String, Provider)

Returns a new instance of KeyStore from the specified provider with the given type.

GetInstance(String, String) GetInstance(String, String)

Returns a new instance of KeyStore from the specified provider with the given type.

GetKey(String, Char[]) GetKey(String, Char[])

Returns the key with the given alias, using the password to recover the key from the store.

IsCertificateEntry(String) IsCertificateEntry(String)

Indicates whether the specified alias is associated with a KeyStore.TrustedCertificateEntry.

IsKeyEntry(String) IsKeyEntry(String)

Indicates whether the specified alias is associated with either a KeyStore.PrivateKeyEntry or a KeyStore.SecretKeyEntry.

JavaFinalize() JavaFinalize()

Invoked when the garbage collector has detected that this instance is no longer reachable.

(Inherited from Object)
Load(KeyStore+ILoadStoreParameter) Load(KeyStore+ILoadStoreParameter)

Loads this KeyStore using the specified LoadStoreParameter.

Load(Stream, Char[]) Load(Stream, Char[])

Initializes this KeyStore from the provided InputStream.

Notify() Notify()

Causes a thread which is waiting on this object's monitor (by means of calling one of the wait() methods) to be woken up.

(Inherited from Object)
NotifyAll() NotifyAll()

Causes all threads which are waiting on this object's monitor (by means of calling one of the wait() methods) to be woken up.

(Inherited from Object)
SetCertificateEntry(String, Certificate) SetCertificateEntry(String, Certificate)

Associates the given alias with a certificate.

SetEntry(String, KeyStore+IEntry, KeyStore+IProtectionParameter) SetEntry(String, KeyStore+IEntry, KeyStore+IProtectionParameter)

Stores the given Entry in this KeyStore and associates the entry with the given alias.

SetHandle(IntPtr, JniHandleOwnership) SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetKeyEntry(String, Byte[], Certificate[]) SetKeyEntry(String, Byte[], Certificate[])

Associates the given alias with a key and a certificate chain.

SetKeyEntry(String, IKey, Char[], Certificate[]) SetKeyEntry(String, IKey, Char[], Certificate[])

Associates the given alias with the key, password and certificate chain.

Size() Size()

Returns the number of entries stored in this KeyStore.

Store(KeyStore+ILoadStoreParameter) Store(KeyStore+ILoadStoreParameter)

Stores this KeyStore using the specified LoadStoreParameter.

Store(Stream, Char[]) Store(Stream, Char[])

Writes this KeyStore to the specified OutputStream.

ToArray<T>() ToArray<T>() Inherited from Object
ToString() ToString()

Returns a string containing a concise, human-readable description of this object.

(Inherited from Object)
UnregisterFromRuntime() UnregisterFromRuntime() Inherited from Object
Wait() Wait()

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object.

(Inherited from Object)
Wait(Int64) Wait(Int64)

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the specified timeout expires.

(Inherited from Object)
Wait(Int64, Int32) Wait(Int64, Int32)

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the specified timeout expires.

(Inherited from Object)

Explicit Interface Implementations

IJavaObjectEx.ToLocalJniHandle() IJavaObjectEx.ToLocalJniHandle() Inherited from Object
IJavaPeerable.Disposed() IJavaPeerable.Disposed() Inherited from Object
IJavaPeerable.DisposeUnlessReferenced() IJavaPeerable.DisposeUnlessReferenced() Inherited from Object
IJavaPeerable.Finalized() IJavaPeerable.Finalized() Inherited from Object
IJavaPeerable.SetJniIdentityHashCode(Int32) IJavaPeerable.SetJniIdentityHashCode(Int32) Inherited from Object
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) Inherited from Object
IJavaPeerable.SetPeerReference(JniObjectReference) IJavaPeerable.SetPeerReference(JniObjectReference) Inherited from Object

Extension Methods

JavaCast<TResult>(IJavaObject) JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject) JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable) GetJniTypeName(IJavaPeerable)

Applies to