com.netscape.certsrv.apps
Class CMS

java.lang.Object
  extended by com.netscape.certsrv.apps.CMS

public final class CMS
extends java.lang.Object

This represents the CMS server. Plugins can access other public objects such as subsystems via this inteface. This object also include a set of utility functions. This object does not include the actual implementation. It acts as a public interface for plugins, and the actual implementation is in the CMS engine (com.netscape.cmscore.apps.CMSEngine) that implements ICMSEngine interface.

Version:
$Revision: 1470 $, $Date: 2010-11-03 17:57:08 -0700 (Wed, 03 Nov 2010) $

Field Summary
static int DEBUG_INFORM
           
static int DEBUG_OBNOXIOUS
           
static int DEBUG_VERBOSE
           
static int PRE_OP_MODE
           
static int RUNNING_MODE
           
static java.lang.String SUBSYSTEM_AUTH
           
static java.lang.String SUBSYSTEM_AUTHZ
           
static java.lang.String SUBSYSTEM_CA
           
static java.lang.String SUBSYSTEM_CRYPTO
           
static java.lang.String SUBSYSTEM_DBS
           
static java.lang.String SUBSYSTEM_JOBS
           
static java.lang.String SUBSYSTEM_KRA
           
static java.lang.String SUBSYSTEM_LOG
           
static java.lang.String SUBSYSTEM_OCSP
           
static java.lang.String SUBSYSTEM_PROFILE
           
static java.lang.String SUBSYSTEM_RA
           
static java.lang.String SUBSYSTEM_REGISTRY
           
static java.lang.String SUBSYSTEM_SELFTESTS
           
static java.lang.String SUBSYSTEM_TKS
           
static java.lang.String SUBSYSTEM_UG
           
 
Method Summary
static boolean areRequestsDisabled()
          Checks to ensure that all new incoming requests have been blocked.
static byte[] AtoB(java.lang.String data)
          Converts a MIME-64 encoded string into a BER-encoded byte array.
static java.lang.String BtoA(byte[] data)
          Converts a BER-encoded byte array into a MIME-64 encoded string.
static netscape.security.util.ObjectIdentifier checkOID(java.lang.String attrName, java.lang.String value)
          Checks if the given OID is valid.
static IArgBlock createArgBlock()
           
static IArgBlock createArgBlock(java.util.Hashtable httpReq)
           
static IArgBlock createArgBlock(java.lang.String realm, java.util.Hashtable httpReq)
           
static ICRLIssuingPointRecord createCRLIssuingPointRecord(java.lang.String id, java.math.BigInteger crlNumber, java.lang.Long crlSize, java.util.Date thisUpdate, java.util.Date nextUpdate)
          Creates an issuing poing record.
static IConfigStore createFileConfigStore(java.lang.String path)
           
static IGeneralNameAsConstraintsConfig createGeneralNameAsConstraintsConfig(java.lang.String name, IConfigStore config, boolean isValueConfigured, boolean isPolicyEnabled)
          Created general name constraints configuration.
static IGeneralNamesAsConstraintsConfig createGeneralNamesAsConstraintsConfig(java.lang.String name, IConfigStore config, boolean isValueConfigured, boolean isPolicyEnabled)
          Created general name constraints configuration.
static IGeneralNamesConfig createGeneralNamesConfig(java.lang.String name, IConfigStore config, boolean isValueConfigured, boolean isPolicyEnabled)
          Created general names configuration.
static IRepositoryRecord createRepositoryRecord()
          Creates a repository record in the internal database.
static ISubjAltNameConfig createSubjAltNameConfig(java.lang.String name, IConfigStore config, boolean isValueConfigured)
          Creates subject alt name configuration.
static void debug(byte[] data)
          Puts data of an byte array into the debug file.
static void debug(int level, java.lang.String msg)
          Puts a message into the debug file.
static void debug(java.lang.String msg)
          Puts a message into the debug file.
static void debug(java.lang.Throwable e)
          Puts an exception into the debug file.
static boolean debugOn()
          Checks if the debug mode is on or not.
static void debugStackTrace()
          Puts the current stack trace in the debug file.
static void disableRequests()
          Blocks all new incoming requests.
static void forceShutdown()
          Shuts down subsystems in backwards order exceptions are ignored.
static netscape.security.x509.GeneralName form_GeneralName(java.lang.String generalNameChoice, java.lang.String value)
          Creates a general name.
static netscape.security.x509.GeneralName form_GeneralNameAsConstraints(java.lang.String generalNameChoice, java.lang.String value)
          Creates a general name constraints.
static java.lang.String getAdminHost()
          Retrieves the host name of the server's administration service.
static java.lang.String getAdminIP()
          Retrieves the IP address of the server's administration service.
static java.lang.String getAdminPort()
          Retrieves the port number of the server's administration service.
static java.lang.String getAgentHost()
          Retrieves the host name of the server's agent service.
static java.lang.String getAgentIP()
          Retrieves the IP address of the server's agent service.
static java.lang.String getAgentPort()
          Retrieves the port number of the server's agent service.
static netscape.ldap.LDAPConnection getBoundConnection(java.lang.String host, int port, int version, netscape.ldap.LDAPSSLSocketFactoryExt fac, java.lang.String bindDN, java.lang.String bindPW)
           
static org.mozilla.jss.CryptoManager.CertificateUsage getCertificateUsage(java.lang.String certusage)
          get the CertificateUsage as defined in JSS CryptoManager
static ICertPrettyPrint getCertPrettyPrint(java.security.cert.X509Certificate cert)
          Retrieves the certificate pretty print handler.
static ICommandQueue getCommandQueue()
          Retrieves command queue
static java.lang.String getConfigSDSessionId()
           
static IConfigStore getConfigStore()
          Returns the main config store.
static ICRLPrettyPrint getCRLCachePrettyPrint(ICRLIssuingPoint ip)
          Retrieves the CRL cache pretty print handler.
static java.lang.String getCRLIssuingPointRecordName()
          Retrieves the default CRL issuing point record name.
static ICRLPrettyPrint getCRLPrettyPrint(java.security.cert.X509CRL crl)
          Retrieves the CRL pretty print handler.
static int getCSState()
           
static java.util.Date getCurrentDate()
          Returns a server wide system time.
static netscape.security.x509.X509CertInfo getDefaultX509CertInfo()
          Retrieves the default X.509 certificate template.
static java.lang.String getEEClientAuthSSLPort()
          Retrieves the host name of the server's secure end entity service.
static java.lang.String getEEHost()
          Retrieves the host name of the server's secure end entity service.
static java.lang.String getEENonSSLHost()
          Retrieves the host name of the server's non-secure end entity service.
static java.lang.String getEENonSSLIP()
          Retrieves the IP address of the server's non-secure end entity service.
static java.lang.String getEENonSSLPort()
          Retrieves the port number of the server's non-secure end entity service.
static java.lang.String getEESSLHost()
          Retrieves the host name of the server's secure end entity service.
static java.lang.String getEESSLIP()
          Retrieves the IP address of the server's secure end entity service.
static java.lang.String getEESSLPort()
          Retrieves the port number of the server's secure end entity service.
static IEmailFormProcessor getEmailFormProcessor()
          Retrieves the email form processor.
static IEmailResolverKeys getEmailResolverKeys()
          Retrieves the email key resolver.
static IEmailTemplate getEmailTemplate(java.lang.String path)
          Retrieves the email form template.
static java.lang.String getEncodedCert(java.security.cert.X509Certificate cert)
          Retrieves the certifcate in MIME-64 encoded format with header and footer.
static IExtPrettyPrint getExtPrettyPrint(netscape.security.x509.Extension e, int indent)
          Retrieves the extension pretty print handler.
static java.lang.String getFingerPrint(java.security.cert.Certificate cert)
          Returns the finger print of the given certificate.
static java.lang.String getFingerPrints(byte[] certDer)
          Returns the finger print of the given certificate.
static java.lang.String getFingerPrints(java.security.cert.Certificate cert)
          Returns the finger print of the given certificate.
static void getGeneralNameConfigDefaultParams(java.lang.String name, boolean isValueConfigured, java.util.Vector params)
          Retrieves default general name configuration.
static void getGeneralNameConfigExtendedPluginInfo(java.lang.String name, boolean isValueConfigured, java.util.Vector info)
          Retrieves extended plugin info for general name configuration.
static void getGeneralNamesConfigDefaultParams(java.lang.String name, boolean isValueConfigured, java.util.Vector params)
          Retrieves default general names configuration.
static void getGeneralNamesConfigExtendedPluginInfo(java.lang.String name, boolean isValueConfigured, java.util.Vector info)
          Retrieves extended plugin info for general name configuration.
static IHttpConnection getHttpConnection(IRemoteAuthority authority, com.netscape.cmsutil.net.ISocketFactory factory)
          Retrieves the HTTP Connection for use with connector.
static IHttpConnection getHttpConnection(IRemoteAuthority authority, com.netscape.cmsutil.net.ISocketFactory factory, int timeout)
          Retrieves the HTTP Connection for use with connector.
static IPKIMessage getHttpPKIMessage()
          Creates a HTTP PKI Message that can be sent to a remote authority.
static IRequestEncoder getHttpRequestEncoder()
          Creates a request encoder.
static java.lang.String getId()
          Gets this ID .
static java.lang.String getInstanceDir()
          Retrieves the instance roort path of this server.
static ILdapConnFactory getLdapAnonConnFactory()
          Retrieves the LDAP connection factory.
static ILdapAuthInfo getLdapAuthInfo()
          Creates a LDAP Auth Info object.
static ILdapConnFactory getLdapBoundConnFactory()
          Retrieves the LDAP connection factory.
static ILdapConnInfo getLdapConnInfo(IConfigStore config)
          Retrieves the ldap connection information from the configuration store.
static netscape.ldap.LDAPSSLSocketFactoryExt getLdapJssSSLSocketFactory()
          Creates a LDAP SSL socket.
static netscape.ldap.LDAPSSLSocketFactoryExt getLdapJssSSLSocketFactory(java.lang.String certNickname)
          Creates a LDAP SSL socket with the given nickname.
static ILogger getLogger()
          Returns the logger of the current server.
static java.lang.String getLogMessage(java.lang.String msgID)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String[] p)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4, java.lang.String p5)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4, java.lang.String p5, java.lang.String p6)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4, java.lang.String p5, java.lang.String p6, java.lang.String p7)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4, java.lang.String p5, java.lang.String p6, java.lang.String p7, java.lang.String p8)
          Retrieves the centralized log message from LogMessages.properties.
static java.lang.String getLogMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3, java.lang.String p4, java.lang.String p5, java.lang.String p6, java.lang.String p7, java.lang.String p8, java.lang.String p9)
          Retrieves the centralized log message from LogMessages.properties.
static IMailNotification getMailNotification()
          Retrieves the email notification handler.
static org.mozilla.jss.util.PasswordCallback getPasswordCallback()
          Retrieves the password callback.
static IPasswordCheck getPasswordChecker()
          Retrieves the password check.
static com.netscape.cmsutil.password.IPasswordStore getPasswordStore()
           
static int getpid()
          Retrieves the process id of this server.
static byte[] getPKCS7(java.util.Locale locale, IRequest req)
           
static IPrettyPrintFormat getPrettyPrintFormat(java.lang.String delimiter)
          Retrieves the certificate pretty print handler.
static IEmailResolver getReqCertSANameEmailResolver()
          Retrieves the email resolver that checks for subjectAlternateName.
static IResender getResender(IAuthority authority, java.lang.String nickname, IRemoteAuthority remote, int interval)
          Retrieves the request sender for use with connector.
static ISecurityDomainSessionTable getSecurityDomainSessionTable()
           
static java.lang.String getServerCertNickname()
          Retrieves the nickname of the server's server certificate.
static ILogger getSignedAuditLogger()
          Returns the signed audit logger of the current server.
static long getStartupTime()
          Retrieves time server started up.
static void getSubjAltNameConfigDefaultParams(java.lang.String name, java.util.Vector params)
          Get default parameters for subject alt name configuration.
static void getSubjAltNameConfigExtendedPluginInfo(java.lang.String name, java.util.Vector params)
          Get extended plugin info for subject alt name configuration.
static ISubsystem getSubsystem(java.lang.String name)
          Retrieves the registered subsytem with the given name.
static java.util.Enumeration getSubsystemNames()
          Returns the names of all the registered subsystems.
static java.util.Enumeration getSubsystems()
          Returns all the registered subsystems.
static java.lang.String getUserMessage(java.util.Locale locale, java.lang.String msgID)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.util.Locale locale, java.lang.String msgID, java.lang.String p1)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.util.Locale locale, java.lang.String msgID, java.lang.String[] p)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.util.Locale locale, java.lang.String msgID, java.lang.String p1, java.lang.String p2)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.util.Locale locale, java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.lang.String msgID)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.lang.String msgID, java.lang.String p1)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.lang.String msgID, java.lang.String[] p)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2)
          Retrieves the localized user message from UserMessages.properties.
static java.lang.String getUserMessage(java.lang.String msgID, java.lang.String p1, java.lang.String p2, java.lang.String p3)
          Retrieves the localized user message from UserMessages.properties.
static void init(ISubsystem owner, IConfigStore config)
          Initialize all static, dynamic and final static subsystems.
static boolean isEncryptionCert(java.security.cert.X509Certificate cert)
          Checks if the given certificate is an encryption certificate.
static boolean isInRunningState()
          Is the server in running state.
static boolean isPreOpMode()
           
static boolean isRevoked(java.security.cert.X509Certificate[] certificates)
           
static boolean isRunningMode()
           
static boolean isSigningCert(java.security.cert.X509Certificate cert)
          Checks if the given certificate is a signing certificate.
static void main(java.lang.String[] args)
          Main driver to start CMS.
static IACL parseACL(java.lang.String resACLs)
          Parse ACL resource attributes
static void putPasswordCache(java.lang.String tag, java.lang.String pw)
          Puts a password entry into the single-sign on cache.
static void reinit(java.lang.String id)
           
static void setCMSEngine(ICMSEngine engine)
          This method is used for unit tests.
static void setConfigSDSessionId(java.lang.String val)
           
static void setCSState(int mode)
          mode = 0 (pre-operational) mode = 1 (running)
static void setId(java.lang.String id)
          Sets the identifier of this subsystem.
static void setListOfVerifiedCerts(int size, long interval, long unknownStateInterval)
           
static void setServerCertNickname(java.lang.String newName)
          Sets the nickname of the server's server certificate.
static void setServerCertNickname(java.lang.String tokenName, java.lang.String nickName)
          Sets the nickname of the server's server certificate.
static void shutdown()
          Shuts down subsystems in backwards order exceptions are ignored.
static void start(java.lang.String path)
          Loads the configuration file and starts CMS's core implementation.
static void startup()
          Starts up all subsystems.
static void terminateRequests()
          Terminates all requests that are currently in process.
static void traceHashKey(java.lang.String type, java.lang.String key)
           
static void traceHashKey(java.lang.String type, java.lang.String key, java.lang.String val)
           
static void traceHashKey(java.lang.String type, java.lang.String key, java.lang.String val, java.lang.String def)
           
static boolean verifySystemCertByNickname(java.lang.String nickname, java.lang.String certificateUsage)
          Verify a system cert by certificate nickname
static boolean verifySystemCertByTag(java.lang.String tag)
          Verify a system cert by tag name with tags defined in .cert.list
static boolean verifySystemCerts()
          Verifies all system certs with tags defined in .cert.list
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEBUG_OBNOXIOUS

public static final int DEBUG_OBNOXIOUS
See Also:
Constant Field Values

DEBUG_VERBOSE

public static final int DEBUG_VERBOSE
See Also:
Constant Field Values

DEBUG_INFORM

public static final int DEBUG_INFORM
See Also:
Constant Field Values

SUBSYSTEM_LOG

public static final java.lang.String SUBSYSTEM_LOG
See Also:
Constant Field Values

SUBSYSTEM_CRYPTO

public static final java.lang.String SUBSYSTEM_CRYPTO
See Also:
Constant Field Values

SUBSYSTEM_DBS

public static final java.lang.String SUBSYSTEM_DBS
See Also:
Constant Field Values

SUBSYSTEM_CA

public static final java.lang.String SUBSYSTEM_CA
See Also:
Constant Field Values

SUBSYSTEM_RA

public static final java.lang.String SUBSYSTEM_RA
See Also:
Constant Field Values

SUBSYSTEM_KRA

public static final java.lang.String SUBSYSTEM_KRA
See Also:
Constant Field Values

SUBSYSTEM_OCSP

public static final java.lang.String SUBSYSTEM_OCSP
See Also:
Constant Field Values

SUBSYSTEM_TKS

public static final java.lang.String SUBSYSTEM_TKS
See Also:
Constant Field Values

SUBSYSTEM_UG

public static final java.lang.String SUBSYSTEM_UG
See Also:
Constant Field Values

SUBSYSTEM_AUTH

public static final java.lang.String SUBSYSTEM_AUTH
See Also:
Constant Field Values

SUBSYSTEM_AUTHZ

public static final java.lang.String SUBSYSTEM_AUTHZ
See Also:
Constant Field Values

SUBSYSTEM_REGISTRY

public static final java.lang.String SUBSYSTEM_REGISTRY
See Also:
Constant Field Values

SUBSYSTEM_PROFILE

public static final java.lang.String SUBSYSTEM_PROFILE
See Also:
Constant Field Values

SUBSYSTEM_JOBS

public static final java.lang.String SUBSYSTEM_JOBS
See Also:
Constant Field Values

SUBSYSTEM_SELFTESTS

public static final java.lang.String SUBSYSTEM_SELFTESTS
See Also:
Constant Field Values

PRE_OP_MODE

public static final int PRE_OP_MODE
See Also:
Constant Field Values

RUNNING_MODE

public static final int RUNNING_MODE
See Also:
Constant Field Values
Method Detail

setCMSEngine

public static void setCMSEngine(ICMSEngine engine)
This method is used for unit tests. It allows the underlying _engine to be stubbed out.

Parameters:
engine - The stub engine to set, for testing.

getId

public static java.lang.String getId()
Gets this ID .

Returns:
CMS engine identifier

setId

public static void setId(java.lang.String id)
                  throws EBaseException
Sets the identifier of this subsystem. Should never be called. Returns error.

Parameters:
id - CMS engine identifier
Throws:
EBaseException

init

public static void init(ISubsystem owner,
                        IConfigStore config)
                 throws EBaseException
Initialize all static, dynamic and final static subsystems.

Parameters:
owner - null
config - main config store.
Throws:
EBaseException - if any error occur in subsystems during initialization.

reinit

public static void reinit(java.lang.String id)
                   throws EBaseException
Throws:
EBaseException

startup

public static void startup()
                    throws EBaseException
Starts up all subsystems. subsystems must be initialized.

Throws:
EBaseException - if any subsystem fails to startup.

disableRequests

public static void disableRequests()
Blocks all new incoming requests.


terminateRequests

public static void terminateRequests()
Terminates all requests that are currently in process.


areRequestsDisabled

public static boolean areRequestsDisabled()
Checks to ensure that all new incoming requests have been blocked. This method is used for reentrancy protection.

Returns:
true or false

shutdown

public static void shutdown()
Shuts down subsystems in backwards order exceptions are ignored. process exists at end to force exit.


forceShutdown

public static void forceShutdown()
Shuts down subsystems in backwards order exceptions are ignored. process exists at end to force exit.


setCSState

public static void setCSState(int mode)
mode = 0 (pre-operational) mode = 1 (running)


getCSState

public static int getCSState()

isPreOpMode

public static boolean isPreOpMode()

isRunningMode

public static boolean isRunningMode()

isInRunningState

public static boolean isInRunningState()
Is the server in running state. After server startup, the server will be initialization state first. After the initialization state, the server will be in the running state.

Returns:
true if the server is in the running state

getLogger

public static ILogger getLogger()
Returns the logger of the current server. The logger can be used to log critical informational or critical error messages.

Returns:
logger

getSignedAuditLogger

public static ILogger getSignedAuditLogger()
Returns the signed audit logger of the current server. This logger can be used to log critical informational or critical error messages.

Returns:
signed audit logger

createRepositoryRecord

public static IRepositoryRecord createRepositoryRecord()
Creates a repository record in the internal database.

Returns:
repository record

parseACL

public static IACL parseACL(java.lang.String resACLs)
                     throws EACLsException
Parse ACL resource attributes

Parameters:
resACLs - same format as the resourceACLs attribute:
     ::
      () 
 
Returns:
an ACL instance built from the parsed resACLs
Throws:
EACLsException - ACL related parsing errors for resACLs

createCRLIssuingPointRecord

public static ICRLIssuingPointRecord createCRLIssuingPointRecord(java.lang.String id,
                                                                 java.math.BigInteger crlNumber,
                                                                 java.lang.Long crlSize,
                                                                 java.util.Date thisUpdate,
                                                                 java.util.Date nextUpdate)
Creates an issuing poing record.

Returns:
issuing record

getCRLIssuingPointRecordName

public static java.lang.String getCRLIssuingPointRecordName()
Retrieves the default CRL issuing point record name.

Returns:
CRL issuing point record name

getpid

public static int getpid()
Retrieves the process id of this server.

Returns:
process id of the server

getInstanceDir

public static java.lang.String getInstanceDir()
Retrieves the instance roort path of this server.

Returns:
instance directory path name

getCurrentDate

public static java.util.Date getCurrentDate()
Returns a server wide system time. Plugins should call this method to retrieve system time.

Returns:
current time

debug

public static void debug(byte[] data)
Puts data of an byte array into the debug file.

Parameters:
data - byte array to be recorded in the debug file

debug

public static void debug(java.lang.String msg)
Puts a message into the debug file.

Parameters:
msg - debugging message

debug

public static void debug(int level,
                         java.lang.String msg)
Puts a message into the debug file.

Parameters:
level - 0-10 (0 is less detail, 10 is more detail)
msg - debugging message

debug

public static void debug(java.lang.Throwable e)
Puts an exception into the debug file.

Parameters:
e - exception

debugOn

public static boolean debugOn()
Checks if the debug mode is on or not.

Returns:
true if debug mode is on

debugStackTrace

public static void debugStackTrace()
Puts the current stack trace in the debug file.


traceHashKey

public static void traceHashKey(java.lang.String type,
                                java.lang.String key)

traceHashKey

public static void traceHashKey(java.lang.String type,
                                java.lang.String key,
                                java.lang.String val)

traceHashKey

public static void traceHashKey(java.lang.String type,
                                java.lang.String key,
                                java.lang.String val,
                                java.lang.String def)

getSubsystemNames

public static java.util.Enumeration getSubsystemNames()
Returns the names of all the registered subsystems.

Returns:
a list of string-based subsystem names

getPKCS7

public static byte[] getPKCS7(java.util.Locale locale,
                              IRequest req)

getSubsystems

public static java.util.Enumeration getSubsystems()
Returns all the registered subsystems.

Returns:
a list of ISubsystem-based subsystems

getSubsystem

public static ISubsystem getSubsystem(java.lang.String name)
Retrieves the registered subsytem with the given name.

Parameters:
name - subsystem name
Returns:
subsystem of the given name

getUserMessage

public static java.lang.String getUserMessage(java.lang.String msgID)
Retrieves the localized user message from UserMessages.properties.

Parameters:
msgID - message id defined in UserMessages.properties
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.util.Locale locale,
                                              java.lang.String msgID)
Retrieves the localized user message from UserMessages.properties.

Parameters:
locale - end-user locale
msgID - message id defined in UserMessages.properties
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.lang.String msgID,
                                              java.lang.String p1)
Retrieves the localized user message from UserMessages.properties.

Parameters:
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.util.Locale locale,
                                              java.lang.String msgID,
                                              java.lang.String p1)
Retrieves the localized user message from UserMessages.properties.

Parameters:
locale - end-user locale
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.lang.String msgID,
                                              java.lang.String p1,
                                              java.lang.String p2)
Retrieves the localized user message from UserMessages.properties.

Parameters:
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.util.Locale locale,
                                              java.lang.String msgID,
                                              java.lang.String p1,
                                              java.lang.String p2)
Retrieves the localized user message from UserMessages.properties.

Parameters:
locale - end-user locale
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.lang.String msgID,
                                              java.lang.String p1,
                                              java.lang.String p2,
                                              java.lang.String p3)
Retrieves the localized user message from UserMessages.properties.

Parameters:
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
Returns:
localized user message

getBoundConnection

public static netscape.ldap.LDAPConnection getBoundConnection(java.lang.String host,
                                                              int port,
                                                              int version,
                                                              netscape.ldap.LDAPSSLSocketFactoryExt fac,
                                                              java.lang.String bindDN,
                                                              java.lang.String bindPW)
                                                       throws netscape.ldap.LDAPException
Throws:
netscape.ldap.LDAPException

getUserMessage

public static java.lang.String getUserMessage(java.util.Locale locale,
                                              java.lang.String msgID,
                                              java.lang.String p1,
                                              java.lang.String p2,
                                              java.lang.String p3)
Retrieves the localized user message from UserMessages.properties.

Parameters:
locale - end-user locale
msgID - message id defined in UserMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.lang.String msgID,
                                              java.lang.String[] p)
Retrieves the localized user message from UserMessages.properties.

Parameters:
msgID - message id defined in UserMessages.properties
p - an array of parameters
Returns:
localized user message

getUserMessage

public static java.lang.String getUserMessage(java.util.Locale locale,
                                              java.lang.String msgID,
                                              java.lang.String[] p)
Retrieves the localized user message from UserMessages.properties.

Parameters:
locale - end-user locale
msgID - message id defined in UserMessages.properties
p - an array of parameters
Returns:
localized user message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String[] p)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p - an array of parameters
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4,
                                             java.lang.String p5)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
p5 - 5th parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4,
                                             java.lang.String p5,
                                             java.lang.String p6)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
p5 - 5th parameter
p6 - 6th parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4,
                                             java.lang.String p5,
                                             java.lang.String p6,
                                             java.lang.String p7)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
p5 - 5th parameter
p6 - 6th parameter
p7 - 7th parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4,
                                             java.lang.String p5,
                                             java.lang.String p6,
                                             java.lang.String p7,
                                             java.lang.String p8)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
p5 - 5th parameter
p6 - 6th parameter
p7 - 7th parameter
p8 - 8th parameter
Returns:
localized log message

getLogMessage

public static java.lang.String getLogMessage(java.lang.String msgID,
                                             java.lang.String p1,
                                             java.lang.String p2,
                                             java.lang.String p3,
                                             java.lang.String p4,
                                             java.lang.String p5,
                                             java.lang.String p6,
                                             java.lang.String p7,
                                             java.lang.String p8,
                                             java.lang.String p9)
Retrieves the centralized log message from LogMessages.properties.

Parameters:
msgID - message id defined in LogMessages.properties
p1 - 1st parameter
p2 - 2nd parameter
p3 - 3rd parameter
p4 - 4th parameter
p5 - 5th parameter
p6 - 6th parameter
p7 - 7th parameter
p8 - 8th parameter
p9 - 9th parameter
Returns:
localized log message

getConfigStore

public static IConfigStore getConfigStore()
Returns the main config store. It is a handle to CMS.cfg.

Returns:
configuration store

getStartupTime

public static long getStartupTime()
Retrieves time server started up.

Returns:
last startup time

getHttpConnection

public static IHttpConnection getHttpConnection(IRemoteAuthority authority,
                                                com.netscape.cmsutil.net.ISocketFactory factory)
Retrieves the HTTP Connection for use with connector.

Parameters:
authority - remote authority
factory - socket factory
Returns:
http connection to the remote authority

getHttpConnection

public static IHttpConnection getHttpConnection(IRemoteAuthority authority,
                                                com.netscape.cmsutil.net.ISocketFactory factory,
                                                int timeout)
Retrieves the HTTP Connection for use with connector.

Parameters:
authority - remote authority
factory - socket factory
timeout - return error if connection cannot be established within the timeout period
Returns:
http connection to the remote authority

getResender

public static IResender getResender(IAuthority authority,
                                    java.lang.String nickname,
                                    IRemoteAuthority remote,
                                    int interval)
Retrieves the request sender for use with connector.

Parameters:
authority - local authority
nickname - nickname of the client certificate
remote - remote authority
interval - timeout interval
Returns:
resender

getServerCertNickname

public static java.lang.String getServerCertNickname()
Retrieves the nickname of the server's server certificate.

Returns:
nickname of the server certificate

setServerCertNickname

public static void setServerCertNickname(java.lang.String tokenName,
                                         java.lang.String nickName)
Sets the nickname of the server's server certificate.

Parameters:
tokenName - name of token where the certificate is located
nickName - name of server certificate

setServerCertNickname

public static void setServerCertNickname(java.lang.String newName)
Sets the nickname of the server's server certificate.

Parameters:
newName - new nickname of server certificate

getEEHost

public static java.lang.String getEEHost()
Retrieves the host name of the server's secure end entity service.

Returns:
host name of end-entity service

getEENonSSLHost

public static java.lang.String getEENonSSLHost()
Retrieves the host name of the server's non-secure end entity service.

Returns:
host name of end-entity non-secure service

getEENonSSLIP

public static java.lang.String getEENonSSLIP()
Retrieves the IP address of the server's non-secure end entity service.

Returns:
ip address of end-entity non-secure service

getEENonSSLPort

public static java.lang.String getEENonSSLPort()
Retrieves the port number of the server's non-secure end entity service.

Returns:
port of end-entity non-secure service

getEESSLHost

public static java.lang.String getEESSLHost()
Retrieves the host name of the server's secure end entity service.

Returns:
port of end-entity secure service

getEEClientAuthSSLPort

public static java.lang.String getEEClientAuthSSLPort()
Retrieves the host name of the server's secure end entity service.

Returns:
port of end-entity secure service

getEESSLIP

public static java.lang.String getEESSLIP()
Retrieves the IP address of the server's secure end entity service.

Returns:
ip address of end-entity secure service

getEESSLPort

public static java.lang.String getEESSLPort()
Retrieves the port number of the server's secure end entity service.

Returns:
port of end-entity secure service

getAgentHost

public static java.lang.String getAgentHost()
Retrieves the host name of the server's agent service.

Returns:
host name of agent service

getAgentIP

public static java.lang.String getAgentIP()
Retrieves the IP address of the server's agent service.

Returns:
ip address of agent service

getAgentPort

public static java.lang.String getAgentPort()
Retrieves the port number of the server's agent service.

Returns:
port of agent service

getAdminHost

public static java.lang.String getAdminHost()
Retrieves the host name of the server's administration service.

Returns:
host name of administration service

getAdminIP

public static java.lang.String getAdminIP()
Retrieves the IP address of the server's administration service.

Returns:
ip address of administration service

getAdminPort

public static java.lang.String getAdminPort()
Retrieves the port number of the server's administration service.

Returns:
port of administration service

form_GeneralNameAsConstraints

public static netscape.security.x509.GeneralName form_GeneralNameAsConstraints(java.lang.String generalNameChoice,
                                                                               java.lang.String value)
                                                                        throws EBaseException
Creates a general name constraints.

Parameters:
generalNameChoice - type of general name
value - general name string
Returns:
general name object
Throws:
EBaseException - failed to create general name constraint

form_GeneralName

public static netscape.security.x509.GeneralName form_GeneralName(java.lang.String generalNameChoice,
                                                                  java.lang.String value)
                                                           throws EBaseException
Creates a general name.

Parameters:
generalNameChoice - type of general name
value - general name string
Returns:
general name object
Throws:
EBaseException - failed to create general name

getSubjAltNameConfigDefaultParams

public static void getSubjAltNameConfigDefaultParams(java.lang.String name,
                                                     java.util.Vector params)
Get default parameters for subject alt name configuration.

Parameters:
name - configuration name
params - configuration parameters

getSubjAltNameConfigExtendedPluginInfo

public static void getSubjAltNameConfigExtendedPluginInfo(java.lang.String name,
                                                          java.util.Vector params)
Get extended plugin info for subject alt name configuration.

Parameters:
name - configuration name
params - configuration parameters

createSubjAltNameConfig

public static ISubjAltNameConfig createSubjAltNameConfig(java.lang.String name,
                                                         IConfigStore config,
                                                         boolean isValueConfigured)
                                                  throws EBaseException
Creates subject alt name configuration.

Parameters:
name - configuration name
config - configuration store
isValueConfigured - true if value is configured
Throws:
EBaseException - failed to create subject alt name configuration

getGeneralNameConfigDefaultParams

public static void getGeneralNameConfigDefaultParams(java.lang.String name,
                                                     boolean isValueConfigured,
                                                     java.util.Vector params)
Retrieves default general name configuration.

Parameters:
name - configuration name
isValueConfigured - true if value is configured
params - configuration parameters
Throws:
EBaseException - failed to create subject alt name configuration

getGeneralNamesConfigDefaultParams

public static void getGeneralNamesConfigDefaultParams(java.lang.String name,
                                                      boolean isValueConfigured,
                                                      java.util.Vector params)
Retrieves default general names configuration.

Parameters:
name - configuration name
isValueConfigured - true if value is configured
params - configuration parameters
Throws:
EBaseException - failed to create subject alt name configuration

getGeneralNameConfigExtendedPluginInfo

public static void getGeneralNameConfigExtendedPluginInfo(java.lang.String name,
                                                          boolean isValueConfigured,
                                                          java.util.Vector info)
Retrieves extended plugin info for general name configuration.

Parameters:
name - configuration name
isValueConfigured - true if value is configured
info - configuration parameters
Throws:
EBaseException - failed to create subject alt name configuration

getGeneralNamesConfigExtendedPluginInfo

public static void getGeneralNamesConfigExtendedPluginInfo(java.lang.String name,
                                                           boolean isValueConfigured,
                                                           java.util.Vector info)
Retrieves extended plugin info for general name configuration.

Parameters:
name - configuration name
isValueConfigured - true if value is configured
info - configuration parameters
Throws:
EBaseException - failed to create subject alt name configuration

createGeneralNamesConfig

public static IGeneralNamesConfig createGeneralNamesConfig(java.lang.String name,
                                                           IConfigStore config,
                                                           boolean isValueConfigured,
                                                           boolean isPolicyEnabled)
                                                    throws EBaseException
Created general names configuration.

Parameters:
name - configuration name
config - configuration store
isValueConfigured - true if value is configured
isPolicyEnabled - true if policy is enabled
Throws:
EBaseException - failed to create subject alt name configuration

createGeneralNameAsConstraintsConfig

public static IGeneralNameAsConstraintsConfig createGeneralNameAsConstraintsConfig(java.lang.String name,
                                                                                   IConfigStore config,
                                                                                   boolean isValueConfigured,
                                                                                   boolean isPolicyEnabled)
                                                                            throws EBaseException
Created general name constraints configuration.

Parameters:
name - configuration name
config - configuration store
isValueConfigured - true if value is configured
isPolicyEnabled - true if policy is enabled
Throws:
EBaseException - failed to create subject alt name configuration

createGeneralNamesAsConstraintsConfig

public static IGeneralNamesAsConstraintsConfig createGeneralNamesAsConstraintsConfig(java.lang.String name,
                                                                                     IConfigStore config,
                                                                                     boolean isValueConfigured,
                                                                                     boolean isPolicyEnabled)
                                                                              throws EBaseException
Created general name constraints configuration.

Parameters:
name - configuration name
config - configuration store
isValueConfigured - true if value is configured
isPolicyEnabled - true if policy is enabled
Throws:
EBaseException - failed to create subject alt name configuration

getFingerPrint

public static java.lang.String getFingerPrint(java.security.cert.Certificate cert)
                                       throws java.security.cert.CertificateEncodingException,
                                              java.security.NoSuchAlgorithmException
Returns the finger print of the given certificate.

Parameters:
cert - certificate
Returns:
finger print of certificate
Throws:
java.security.cert.CertificateEncodingException
java.security.NoSuchAlgorithmException

getFingerPrints

public static java.lang.String getFingerPrints(byte[] certDer)
                                        throws java.security.NoSuchAlgorithmException
Returns the finger print of the given certificate.

Parameters:
certDer - DER byte array of the certificate
Returns:
finger print of certificate
Throws:
java.security.NoSuchAlgorithmException

getFingerPrints

public static java.lang.String getFingerPrints(java.security.cert.Certificate cert)
                                        throws java.security.NoSuchAlgorithmException,
                                               java.security.cert.CertificateEncodingException
Returns the finger print of the given certificate.

Parameters:
cert - certificate
Returns:
finger print of certificate
Throws:
java.security.NoSuchAlgorithmException
java.security.cert.CertificateEncodingException

getHttpPKIMessage

public static IPKIMessage getHttpPKIMessage()
Creates a HTTP PKI Message that can be sent to a remote authority.

Returns:
a new PKI Message for remote authority

getHttpRequestEncoder

public static IRequestEncoder getHttpRequestEncoder()
Creates a request encoder. A request cannot be sent to the remote authority in its regular format.

Returns:
a request encoder

BtoA

public static java.lang.String BtoA(byte[] data)
Converts a BER-encoded byte array into a MIME-64 encoded string.

Parameters:
data - data in byte array format
Returns:
base-64 encoding for the data

AtoB

public static byte[] AtoB(java.lang.String data)
Converts a MIME-64 encoded string into a BER-encoded byte array.

Parameters:
data - base-64 encoding for the data
Returns:
data data in byte array format

getLdapConnInfo

public static ILdapConnInfo getLdapConnInfo(IConfigStore config)
                                     throws EBaseException,
                                            ELdapException
Retrieves the ldap connection information from the configuration store.

Parameters:
config - configuration parameters of ldap connection
Returns:
a LDAP connection info
Throws:
EBaseException
ELdapException

getLdapJssSSLSocketFactory

public static netscape.ldap.LDAPSSLSocketFactoryExt getLdapJssSSLSocketFactory(java.lang.String certNickname)
Creates a LDAP SSL socket with the given nickname. The certificate associated with the nickname will be used for client authentication.

Parameters:
certNickname - nickname of client certificate
Returns:
LDAP SSL socket factory

getLdapJssSSLSocketFactory

public static netscape.ldap.LDAPSSLSocketFactoryExt getLdapJssSSLSocketFactory()
Creates a LDAP SSL socket.

Returns:
LDAP SSL socket factory

getLdapAuthInfo

public static ILdapAuthInfo getLdapAuthInfo()
Creates a LDAP Auth Info object.

Returns:
LDAP authentication info

getLdapBoundConnFactory

public static ILdapConnFactory getLdapBoundConnFactory()
                                                throws ELdapException
Retrieves the LDAP connection factory.

Returns:
bound LDAP connection pool
Throws:
ELdapException

getLdapAnonConnFactory

public static ILdapConnFactory getLdapAnonConnFactory()
                                               throws ELdapException
Retrieves the LDAP connection factory.

Returns:
anonymous LDAP connection pool
Throws:
ELdapException

getDefaultX509CertInfo

public static netscape.security.x509.X509CertInfo getDefaultX509CertInfo()
Retrieves the default X.509 certificate template.

Returns:
default certificate template

getEncodedCert

public static java.lang.String getEncodedCert(java.security.cert.X509Certificate cert)
Retrieves the certifcate in MIME-64 encoded format with header and footer.

Parameters:
cert - certificate
Returns:
base-64 format certificate

verifySystemCerts

public static boolean verifySystemCerts()
Verifies all system certs with tags defined in .cert.list


verifySystemCertByTag

public static boolean verifySystemCertByTag(java.lang.String tag)
Verify a system cert by tag name with tags defined in .cert.list


verifySystemCertByNickname

public static boolean verifySystemCertByNickname(java.lang.String nickname,
                                                 java.lang.String certificateUsage)
Verify a system cert by certificate nickname


getCertificateUsage

public static org.mozilla.jss.CryptoManager.CertificateUsage getCertificateUsage(java.lang.String certusage)
get the CertificateUsage as defined in JSS CryptoManager


isSigningCert

public static boolean isSigningCert(java.security.cert.X509Certificate cert)
Checks if the given certificate is a signing certificate.

Parameters:
cert - certificate
Returns:
true if the given certificate is a signing certificate

isEncryptionCert

public static boolean isEncryptionCert(java.security.cert.X509Certificate cert)
Checks if the given certificate is an encryption certificate.

Parameters:
cert - certificate
Returns:
true if the given certificate is an encryption certificate

getEmailFormProcessor

public static IEmailFormProcessor getEmailFormProcessor()
Retrieves the email form processor.

Returns:
email form processor

getEmailTemplate

public static IEmailTemplate getEmailTemplate(java.lang.String path)
Retrieves the email form template.

Returns:
email template

getMailNotification

public static IMailNotification getMailNotification()
Retrieves the email notification handler.

Returns:
email notification

getEmailResolverKeys

public static IEmailResolverKeys getEmailResolverKeys()
Retrieves the email key resolver.

Returns:
email key resolver

checkOID

public static netscape.security.util.ObjectIdentifier checkOID(java.lang.String attrName,
                                                               java.lang.String value)
                                                        throws EBaseException
Checks if the given OID is valid.

Parameters:
attrName - attribute name
value - attribute value
Returns:
object identifier of the given attrName
Throws:
EBaseException

getReqCertSANameEmailResolver

public static IEmailResolver getReqCertSANameEmailResolver()
Retrieves the email resolver that checks for subjectAlternateName.

Returns:
email key resolver

getExtPrettyPrint

public static IExtPrettyPrint getExtPrettyPrint(netscape.security.x509.Extension e,
                                                int indent)
Retrieves the extension pretty print handler.

Parameters:
e - extension
indent - indentation
Returns:
extension pretty print handler

getPrettyPrintFormat

public static IPrettyPrintFormat getPrettyPrintFormat(java.lang.String delimiter)
Retrieves the certificate pretty print handler.

Parameters:
delimiter - delimiter
Returns:
certificate pretty print handler

getCRLPrettyPrint

public static ICRLPrettyPrint getCRLPrettyPrint(java.security.cert.X509CRL crl)
Retrieves the CRL pretty print handler.

Parameters:
crl - CRL
Returns:
CRL pretty print handler

getCRLCachePrettyPrint

public static ICRLPrettyPrint getCRLCachePrettyPrint(ICRLIssuingPoint ip)
Retrieves the CRL cache pretty print handler.

Parameters:
ip - CRL issuing point
Returns:
CRL pretty print handler

getCertPrettyPrint

public static ICertPrettyPrint getCertPrettyPrint(java.security.cert.X509Certificate cert)
Retrieves the certificate pretty print handler.

Parameters:
cert - certificate
Returns:
certificate pretty print handler

getConfigSDSessionId

public static java.lang.String getConfigSDSessionId()

setConfigSDSessionId

public static void setConfigSDSessionId(java.lang.String val)

getPasswordChecker

public static IPasswordCheck getPasswordChecker()
Retrieves the password check.

Returns:
default password checker

putPasswordCache

public static void putPasswordCache(java.lang.String tag,
                                    java.lang.String pw)
Puts a password entry into the single-sign on cache.

Parameters:
tag - password tag
pw - password

getPasswordCallback

public static org.mozilla.jss.util.PasswordCallback getPasswordCallback()
Retrieves the password callback.

Returns:
default password callback

getCommandQueue

public static ICommandQueue getCommandQueue()
Retrieves command queue

Returns:
command queue

start

public static void start(java.lang.String path)
                  throws EBaseException
Loads the configuration file and starts CMS's core implementation.

Parameters:
path - path to configuration file (CMS.cfg)
Throws:
EBaseException - failed to start CMS

createFileConfigStore

public static IConfigStore createFileConfigStore(java.lang.String path)
                                          throws EBaseException
Throws:
EBaseException

createArgBlock

public static IArgBlock createArgBlock()

createArgBlock

public static IArgBlock createArgBlock(java.lang.String realm,
                                       java.util.Hashtable httpReq)

createArgBlock

public static IArgBlock createArgBlock(java.util.Hashtable httpReq)

isRevoked

public static boolean isRevoked(java.security.cert.X509Certificate[] certificates)

setListOfVerifiedCerts

public static void setListOfVerifiedCerts(int size,
                                          long interval,
                                          long unknownStateInterval)

getPasswordStore

public static com.netscape.cmsutil.password.IPasswordStore getPasswordStore()

getSecurityDomainSessionTable

public static ISecurityDomainSessionTable getSecurityDomainSessionTable()

main

public static void main(java.lang.String[] args)
Main driver to start CMS.