org.idoox.security.jaas
Class PrivateKeyCertsCredential

java.lang.Object
  extended byorg.idoox.security.jaas.PrivateKeyCertsCredential

public class PrivateKeyCertsCredential
extends java.lang.Object

Contains asymetric cyptographic material in a form of private key and certificate. When this credential is not further needed, user SHOULD clean it.

Component:
Security-Core

Constructor Summary
PrivateKeyCertsCredential(java.security.PrivateKey key, java.security.cert.X509Certificate[] certs)
          Constructor sets private key and X509 certificate (chain) to the given values.
 
Method Summary
 void clean()
          Cleans all properties of this credential.
 java.security.cert.X509Certificate[] getCertChain()
          return certificate chain.
 java.security.cert.X509Certificate getCertificate()
          Returns user's certificate.
 java.security.PrivateKey getPrivateKey()
          Returns private key.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrivateKeyCertsCredential

public PrivateKeyCertsCredential(java.security.PrivateKey key,
                                 java.security.cert.X509Certificate[] certs)
Constructor sets private key and X509 certificate (chain) to the given values.

Parameters:
key - private key of the user
certs - certificate chain.
Method Detail

getPrivateKey

public java.security.PrivateKey getPrivateKey()
Returns private key.

Returns:
private key

getCertChain

public java.security.cert.X509Certificate[] getCertChain()
return certificate chain.

Returns:
certificate chain

getCertificate

public java.security.cert.X509Certificate getCertificate()
Returns user's certificate.

Returns:
user's certificate

clean

public void clean()
Cleans all properties of this credential.