public class CertServiceImpl extends DefaultComponent implements CertService
Constructor and Description |
---|
CertServiceImpl() |
Modifier and Type | Method and Description |
---|---|
X509Certificate |
getCertificate(KeyStore ks,
String certificateAlias)
Retrieves an existing certificate from a keystore using keystore's
certificate alias.
|
String |
getCertificateEmail(X509Certificate certificate)
Extracts the email address from a certificate
|
KeyPair |
getKeyPair(KeyStore ks,
String keyAlias,
String certAlias,
String keyPassword)
Retrieves existing private and public key from a KeyStore.
|
KeyStore |
getKeyStore(InputStream keystoreIS,
String password)
Retrieves a KeyStore object from a supplied InputStream.
|
X509Certificate |
getRootCertificate()
Retrieves the root certificate.
|
KeyStore |
initializeUser(UserInfo userInfo,
String suppliedPassword)
Generates a private key and a public certificate for a user whose X.509
field information was enclosed in a UserInfo parameter.
|
void |
setRootService(RootService rootService)
Sets up a root service to be used for CA-related services like
certificate request signing and certificate revocation.
|
void |
storeCertificate(KeyStore keystore,
OutputStream os,
String keystorePassword)
Wraps a certificate object into an OutputStream object secured by a
keystore password
|
activate, applicationStarted, deactivate, getAdapter, getApplicationStartedOrder, getLastModified, registerContribution, registerExtension, setLastModified, unregisterContribution, unregisterExtension
public void setRootService(RootService rootService)
CertService
setRootService
in interface CertService
public X509Certificate getRootCertificate() throws CertException
CertService
getRootCertificate
in interface CertService
CertException
public KeyStore initializeUser(UserInfo userInfo, String suppliedPassword) throws CertException
CertService
initializeUser
in interface CertService
CertException
public KeyPair getKeyPair(KeyStore ks, String keyAlias, String certAlias, String keyPassword) throws CertException
CertService
getKeyPair
in interface CertService
CertException
public X509Certificate getCertificate(KeyStore ks, String certificateAlias) throws CertException
CertService
getCertificate
in interface CertService
CertException
public KeyStore getKeyStore(InputStream keystoreIS, String password) throws CertException
CertService
getKeyStore
in interface CertService
CertException
public String getCertificateEmail(X509Certificate certificate) throws CertException
CertService
getCertificateEmail
in interface CertService
CertException
public void storeCertificate(KeyStore keystore, OutputStream os, String keystorePassword) throws CertException
CertService
storeCertificate
in interface CertService
CertException
Copyright © 2013 Nuxeo SA. All Rights Reserved.