|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Crypto
| Method Summary | |
|---|---|
byte[] |
getBytesFromCertificates(java.security.cert.X509Certificate[] certs)
Get a byte array given an array of X509 certificates. |
java.security.cert.CertificateFactory |
getCertificateFactory()
Get the CertificateFactory instance on this Crypto instance |
java.security.cert.X509Certificate[] |
getCertificatesFromBytes(byte[] data)
Construct an array of X509Certificate's from the byte array. |
java.lang.String |
getCryptoProvider()
Get the crypto provider associated with this implementation |
java.lang.String |
getDefaultX509Identifier()
Retrieves the identifier name of the default certificate. |
java.security.PrivateKey |
getPrivateKey(java.lang.String identifier,
java.lang.String password)
Gets the private key corresponding to the identifier. |
java.security.PrivateKey |
getPrivateKey(java.security.cert.X509Certificate certificate,
javax.security.auth.callback.CallbackHandler callbackHandler)
Gets the private key corresponding to the certificate. |
byte[] |
getSKIBytesFromCert(java.security.cert.X509Certificate cert)
Reads the SubjectKeyIdentifier information from the certificate. |
java.security.cert.X509Certificate[] |
getX509Certificates(CryptoType cryptoType)
Get an X509Certificate (chain) corresponding to the CryptoType argument. |
java.lang.String |
getX509Identifier(java.security.cert.X509Certificate cert)
Get the implementation-specific identifier corresponding to the cert parameter, e.g. |
java.security.cert.X509Certificate |
loadCertificate(java.io.InputStream in)
Load a X509Certificate from the input stream. |
void |
setCertificateFactory(java.lang.String provider,
java.security.cert.CertificateFactory certFactory)
Sets the CertificateFactory instance on this Crypto instance |
void |
setCryptoProvider(java.lang.String provider)
Set the crypto provider associated with this implementation |
void |
setDefaultX509Identifier(java.lang.String identifier)
Sets the identifier name of the default certificate. |
boolean |
verifyTrust(java.security.PublicKey publicKey)
Evaluate whether a given public key should be trusted. |
boolean |
verifyTrust(java.security.cert.X509Certificate[] certs)
Deprecated. |
boolean |
verifyTrust(java.security.cert.X509Certificate[] certs,
boolean enableRevocation)
Evaluate whether a given certificate chain should be trusted. |
| Method Detail |
|---|
java.lang.String getCryptoProvider()
void setCryptoProvider(java.lang.String provider)
provider - the crypto provider to set
java.lang.String getDefaultX509Identifier()
throws WSSecurityException
WSSecurityExceptionvoid setDefaultX509Identifier(java.lang.String identifier)
identifier - name of the default X509 certificate.
void setCertificateFactory(java.lang.String provider,
java.security.cert.CertificateFactory certFactory)
provider - the CertificateFactory provider namecertFactory - the CertificateFactory the CertificateFactory instance to set
java.security.cert.CertificateFactory getCertificateFactory()
throws WSSecurityException
CertificateFactory to construct
X509 certificates
WSSecurityException
java.security.cert.X509Certificate loadCertificate(java.io.InputStream in)
throws WSSecurityException
in - The InputStream containing the X509 data
WSSecurityException
byte[] getSKIBytesFromCert(java.security.cert.X509Certificate cert)
throws WSSecurityException
cert - The certificate to read SKI
WSSecurityException
byte[] getBytesFromCertificates(java.security.cert.X509Certificate[] certs)
throws WSSecurityException
certs - The certificates to convert
WSSecurityException
java.security.cert.X509Certificate[] getCertificatesFromBytes(byte[] data)
throws WSSecurityException
data - The byte array containing the X509 data
WSSecurityException
java.security.cert.X509Certificate[] getX509Certificates(CryptoType cryptoType)
throws WSSecurityException
WSSecurityException
java.lang.String getX509Identifier(java.security.cert.X509Certificate cert)
throws WSSecurityException
cert - The X509Certificate for which to search for an identifier
WSSecurityException
java.security.PrivateKey getPrivateKey(java.security.cert.X509Certificate certificate,
javax.security.auth.callback.CallbackHandler callbackHandler)
throws WSSecurityException
certificate - The X509Certificate corresponding to the private keycallbackHandler - The callbackHandler needed to get the password
WSSecurityException
java.security.PrivateKey getPrivateKey(java.lang.String identifier,
java.lang.String password)
throws WSSecurityException
identifier - The implementation-specific identifier corresponding to the keypassword - The password needed to get the key
WSSecurityException
@Deprecated
boolean verifyTrust(java.security.cert.X509Certificate[] certs)
throws WSSecurityException
certs - Certificate chain to validate
WSSecurityException
boolean verifyTrust(java.security.cert.X509Certificate[] certs,
boolean enableRevocation)
throws WSSecurityException
certs - Certificate chain to validateenableRevocation - whether to enable CRL verification or not
WSSecurityException
boolean verifyTrust(java.security.PublicKey publicKey)
throws WSSecurityException
publicKey - The PublicKey to be evaluated
WSSecurityException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||