com.adobe.truststore.client
Class CredentialServiceClient

java.lang.Object
  extended by com.adobe.truststore.client.CredentialServiceClient

public class CredentialServiceClient
extends Object

Enables you to programmatically interact with the LiveCycle ES Credential Service. A credential contains your private key information needed for signing or identifying documents. A certificate is public key information that you configure for trust. LiveCycle ES2 uses certificates and credentials for several purposes:

For information about programmatically interacting with the LiveCycle ES Credential Service, see the Working with Credentials section in Programming with LiveCycle ES3.


Constructor Summary
CredentialServiceClient(ServiceClientFactory serviceClientFactory)
           
 
Method Summary
 void addCredential(CredentialBO credential)
          Adds a credential to LiveCycle ES2.
 void clearAllHSMConnections()
          For internal use only.
 void deleteCredential(String alias)
          Deletes a credential from LiveCyle ES2.
 void deregisterCacheInvalidationHandler(String serviceName, String operationName)
          For internal use only.
 Document exportCredential(String alias, String keyPassword)
          Exports a credential from LiveCyle ES2.
 List fetchAllCredentialsInfo()
          For internal use only.
 CredentialBO findCredentialByAlias(String alias, String keyPassword)
          Finds a credential by using an alias value.
 CredentialBO findCredentialBySubjectDN(String subjectDN)
          Finds a credential by using the subjectDN value.
 List findCredentials(com.adobe.truststore.businessobject.CredentialSearchFilter searchFilter)
          Finds a given credential.
 List getCredentialsOnToken(String pkcs11Lib, Integer slotListIndex, String pwd, String hsmDev)
          For internal use only.
 com.adobe.truststore.businessobject.CredentialType[] getCredentialTypes(String locale)
          Gets a list of supported credential types.
 void importCredential(String alias, Document p12Credential, String keyPassword, String[] types)
          Imports a credential into LiveCyle ES2.
 HSMDeviceInfo listSlots(String pkcs11Lib)
          For internal use only.
 void registerCacheInvalidationHandler(String serviceName, String operationName)
          For internal use only.
 void resetCredentialCache()
          Resets the credential cache.
 void setCredentialTypes(String alias, String[] credentialTypes)
          For internal use only.
 void updateCredential(String alias, CredentialBO credential)
          Updates a given credential.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CredentialServiceClient

public CredentialServiceClient(ServiceClientFactory serviceClientFactory)
Method Detail

getCredentialTypes

public com.adobe.truststore.businessobject.CredentialType[] getCredentialTypes(String locale)
                                                                        throws Exception
Gets a list of supported credential types.

Parameters:
locale - The locale value of credential.
Returns:
An array of CredentialType objects that represent the supported types.
Throws:
Exception

addCredential

public void addCredential(CredentialBO credential)
                   throws Exception
Adds a credential to LiveCycle ES2.

Parameters:
credential - A CredentialBO object that represents the credential to add.
Throws:
Exception

importCredential

public void importCredential(String alias,
                             Document p12Credential,
                             String keyPassword,
                             String[] types)
                      throws Exception
Imports a credential into LiveCyle ES2. Once imported, a credential can be used to perform an operation such as digitially signing a PDF document. To see this method used in a code example, see the Importing credentials using the Java API quick start in Programming with LiveCycle ES3.

Parameters:
alias - A string value that represents the alias that corresponds to the credential. When using the credential, you reference it using this alias value.
p12Credential - A com.adobe.ipd.Document instance that represents the credential to import.
keyPassword - A string value that represents the password that corresponds to the credential.
types - A string array that represents the credential type. For example, specify truststore.usage.type.sign to import a credential used to sign a PDF document.
Throws:
Exception

exportCredential

public Document exportCredential(String alias,
                                 String keyPassword)
                          throws Exception
Exports a credential from LiveCyle ES2. If you specify an alias value that does not exist, an exception is thrown.

Parameters:
alias - A string value that represents the alias that corresponds to the credential.
keyPassword - A string value that represents the password that corresponds to the credential.
Returns:
A com.adobe.ipd.Document instance that represents the exported credential.
Throws:
Exception

deleteCredential

public void deleteCredential(String alias)
                      throws Exception
Deletes a credential from LiveCyle ES2. If you specify an alias value that does not exist, an exception is thrown. To see this method used in a code example, see the Deleting credentials using the Java API quick start in Programming with LiveCycle ES3.

Parameters:
alias - A string value that represents the alias that corresponds to the credential.
Throws:
Exception

setCredentialTypes

public void setCredentialTypes(String alias,
                               String[] credentialTypes)
                        throws Exception
For internal use only.

Throws:
Exception

updateCredential

public void updateCredential(String alias,
                             CredentialBO credential)
                      throws Exception
Updates a given credential.

Parameters:
alias - A string value that represents the alias that corresponds to the credential.
A - CredentialBO object that represents the updated credential.
Throws:
Exception

findCredentials

public List findCredentials(com.adobe.truststore.businessobject.CredentialSearchFilter searchFilter)
                     throws Exception
Finds a given credential.

Parameters:
searchFilter - A CredentialSearchFilter object that represents a search filter.
Returns:
A java.util.List instance where each element is a credential that satisfies the search filter.
Throws:
Exception

findCredentialByAlias

public CredentialBO findCredentialByAlias(String alias,
                                          String keyPassword)
                                   throws Exception
Finds a credential by using an alias value.

Parameters:
alias - A string value that represents the alias that corresponds to the credential. When using the credential, you reference it using this alias value.
keyPassword - A string value that represents the password that corresponds to the credential.
Returns:
A CredentialBO instance that represents the credential that corresponds to the alias.
Throws:
Exception

findCredentialBySubjectDN

public CredentialBO findCredentialBySubjectDN(String subjectDN)
                                       throws Exception
Finds a credential by using the subjectDN value.

Parameters:
subjectDN - A string value that represents the subjectDN value.
Returns:
A CredentialBO instance that represents the credential that corresponds to the subjectDN value.
Throws:
Exception

registerCacheInvalidationHandler

public void registerCacheInvalidationHandler(String serviceName,
                                             String operationName)
                                      throws Exception
For internal use only.

Throws:
Exception

deregisterCacheInvalidationHandler

public void deregisterCacheInvalidationHandler(String serviceName,
                                               String operationName)
                                        throws Exception
For internal use only.

Throws:
Exception

resetCredentialCache

public void resetCredentialCache()
                          throws Exception
Resets the credential cache.

Throws:
Exception

getCredentialsOnToken

public List getCredentialsOnToken(String pkcs11Lib,
                                  Integer slotListIndex,
                                  String pwd,
                                  String hsmDev)
                           throws Exception
For internal use only.

Throws:
Exception

listSlots

public HSMDeviceInfo listSlots(String pkcs11Lib)
                        throws Exception
For internal use only.

Throws:
Exception

fetchAllCredentialsInfo

public List fetchAllCredentialsInfo()
                             throws Exception
For internal use only.

Throws:
Exception

clearAllHSMConnections

public void clearAllHSMConnections()
                            throws Exception
For internal use only.

Throws:
Exception


[an error occurred while processing this directive] [an error occurred while processing this directive]