issrg.security
Class PKCRepository

java.lang.Object
  extended by issrg.security.PKCRepository

public class PKCRepository
extends java.lang.Object

This class is the interface to a repository of X.509 PKCs. It wraps an AttributeRepository to do the actual certificate retrieval.


Field Summary
static java.lang.String CA_PKC_ATTRIBUTE
          This is the name of the caCertificate attribute, compatible with LDAPv3 naming convention ("caCertificate").
static java.lang.String USER_PKC_ATTRIBUTE
          This is the name of the userCertificate attribute, compatible with LDAPv3 naming convention ("userCertificate").
 
Constructor Summary
protected PKCRepository()
           
  PKCRepository(AttributeRepository ar)
          This constructor builds a PKCRepository given the AttributeRepository to retrieve the certificates from.
 
Method Summary
 javax.naming.directory.Attribute getCACertificate(TokenLocator subject)
          This method returns the CA Certificates given the TokenLocator, pointing to the entry of the principal in question.
 javax.naming.directory.Attribute getUserCertificate(TokenLocator subject)
          This method returns the User Certificates given the TokenLocator, pointing to the entry of the principal in question.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

USER_PKC_ATTRIBUTE

public static java.lang.String USER_PKC_ATTRIBUTE
This is the name of the userCertificate attribute, compatible with LDAPv3 naming convention ("userCertificate"). Assign a different name, if your repository does not support LDAPv3 naming.


CA_PKC_ATTRIBUTE

public static java.lang.String CA_PKC_ATTRIBUTE
This is the name of the caCertificate attribute, compatible with LDAPv3 naming convention ("caCertificate"). Assign a different name, if your repository does not support LDAPv3 naming.

Constructor Detail

PKCRepository

protected PKCRepository()

PKCRepository

public PKCRepository(AttributeRepository ar)
This constructor builds a PKCRepository given the AttributeRepository to retrieve the certificates from.

Parameters:
ar - - the AttributeRepository to retrieve the certificates from
Method Detail

getUserCertificate

public javax.naming.directory.Attribute getUserCertificate(TokenLocator subject)
                                                    throws RepositoryException
This method returns the User Certificates given the TokenLocator, pointing to the entry of the principal in question. Note that unlike Principal, TokenLocator is a chain of primary and alternative locations, each applicable to a specific repository or the default repository. All locations in the chain are treated equally.

Parameters:
subject - - the TokenLocator indicating the entry with the certificates
Throws:
RepositoryException

getCACertificate

public javax.naming.directory.Attribute getCACertificate(TokenLocator subject)
                                                  throws RepositoryException
This method returns the CA Certificates given the TokenLocator, pointing to the entry of the principal in question. Note that unlike Principal, TokenLocator is a chain of primary and alternative locations, each applicable to a specific repository or the default repository. All locations in the chain are treated equally.

Parameters:
subject - - the TokenLocator indicating the entry with the certificates
Throws:
RepositoryException