Package com.netscape.cms.profile.input
Class EnrollInput
- java.lang.Object
-
- com.netscape.cms.profile.common.ProfileInput
-
- com.netscape.cms.profile.input.EnrollInput
-
- All Implemented Interfaces:
com.netscape.certsrv.property.IConfigTemplate
- Direct Known Subclasses:
CertReqInput
,CMCCertReqInput
,DualKeyGenInput
,EncryptionKeyGenInput
,FileSigningInput
,GenericInput
,ImageInput
,KeyGenInput
,nsHKeyCertReqInput
,nsNKeyCertReqInput
,SerialNumRenewInput
,ServerKeygenInput
,SigningKeyGenInput
,SubjectAltNameExtInput
,SubjectDNInput
,SubjectNameInput
,SubmitterInfoInput
public abstract class EnrollInput extends ProfileInput
This class implements the base enrollment input.- Version:
- $Revision$, $Date$
-
-
Field Summary
Fields Modifier and Type Field Description static org.slf4j.Logger
logger
protected IConfigStore
mConfig
protected java.util.Vector<java.lang.String>
mConfigNames
protected Profile
mProfile
protected java.util.Vector<java.lang.String>
mValueNames
-
Constructor Summary
Constructors Constructor Description EnrollInput()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
addConfigName(java.lang.String name)
void
addValueName(java.lang.String name)
protected java.lang.String
auditSubjectID()
Signed Audit Log Subject ID This method is inherited by all extended "CMSServlet"s, and is called to obtain the "SubjectID" for a signed audit log message.java.lang.String
getConfig(java.lang.String name)
Retrieves configuration parameter by name.com.netscape.certsrv.property.IDescriptor
getConfigDescriptor(java.util.Locale locale, java.lang.String name)
Returns the descriptors of configuration parameter.java.util.Enumeration<java.lang.String>
getConfigNames()
Returns a list of configuration parameter names.IConfigStore
getConfigStore()
Returns configuration store.java.lang.String
getDefaultConfig(java.lang.String name)
java.util.Locale
getLocale(com.netscape.certsrv.request.IRequest request)
abstract java.lang.String
getName(java.util.Locale locale)
Retrieves the localizable name of this policy.abstract java.lang.String
getText(java.util.Locale locale)
Retrieves the localizable description of this policy.java.lang.String
getValue(java.lang.String name, java.util.Locale locale, com.netscape.certsrv.request.IRequest request)
Retrieves value from the request.abstract com.netscape.certsrv.property.IDescriptor
getValueDescriptor(java.util.Locale locale, java.lang.String name)
Retrieves the descriptor of the given value property by name.java.util.Enumeration<java.lang.String>
getValueNames()
Retrieves a list of names of the value parameter.void
init(Profile profile, IConfigStore config)
Initializes this default policy.abstract void
populate(java.util.Map<java.lang.String,java.lang.String> ctx, com.netscape.certsrv.request.IRequest request)
Populates the request with this policy default.void
setConfig(java.lang.String name, java.lang.String value)
Sets configuration parameter.void
setValue(java.lang.String name, java.util.Locale locale, com.netscape.certsrv.request.IRequest request, java.lang.String value)
Sets the value of the given value parameter by name.void
verifyPOP(java.util.Locale locale, org.mozilla.jss.pkix.crmf.CertReqMsg certReqMsg)
-
-
-
Field Detail
-
logger
public static org.slf4j.Logger logger
-
mConfig
protected IConfigStore mConfig
-
mValueNames
protected java.util.Vector<java.lang.String> mValueNames
-
mConfigNames
protected java.util.Vector<java.lang.String> mConfigNames
-
mProfile
protected Profile mProfile
-
-
Method Detail
-
init
public void init(Profile profile, IConfigStore config) throws com.netscape.certsrv.profile.EProfileException
Initializes this default policy.- Throws:
com.netscape.certsrv.profile.EProfileException
-
getConfigStore
public IConfigStore getConfigStore()
Description copied from class:ProfileInput
Returns configuration store.- Specified by:
getConfigStore
in classProfileInput
- Returns:
- configuration store
-
populate
public abstract void populate(java.util.Map<java.lang.String,java.lang.String> ctx, com.netscape.certsrv.request.IRequest request) throws java.lang.Exception
Populates the request with this policy default.- Specified by:
populate
in classProfileInput
- Parameters:
ctx
- profile contextrequest
- request- Throws:
java.lang.Exception
- failed to populate
-
getName
public abstract java.lang.String getName(java.util.Locale locale)
Retrieves the localizable name of this policy.- Specified by:
getName
in classProfileInput
- Parameters:
locale
- user locale- Returns:
- localized input name
-
getText
public abstract java.lang.String getText(java.util.Locale locale)
Retrieves the localizable description of this policy.- Specified by:
getText
in classProfileInput
- Parameters:
locale
- user locale- Returns:
- localized input description
-
getValueDescriptor
public abstract com.netscape.certsrv.property.IDescriptor getValueDescriptor(java.util.Locale locale, java.lang.String name)
Retrieves the descriptor of the given value property by name.- Specified by:
getValueDescriptor
in classProfileInput
- Parameters:
locale
- user localename
- property name- Returns:
- descriptor of the property
-
addValueName
public void addValueName(java.lang.String name)
-
getValueNames
public java.util.Enumeration<java.lang.String> getValueNames()
Retrieves a list of names of the value parameter.- Specified by:
getValueNames
in classProfileInput
- Returns:
- a list of property names
-
addConfigName
public void addConfigName(java.lang.String name)
-
getConfigNames
public java.util.Enumeration<java.lang.String> getConfigNames()
Description copied from interface:com.netscape.certsrv.property.IConfigTemplate
Returns a list of configuration parameter names.- Returns:
- parameter names
-
setConfig
public void setConfig(java.lang.String name, java.lang.String value) throws com.netscape.certsrv.property.EPropertyException
Description copied from interface:com.netscape.certsrv.property.IConfigTemplate
Sets configuration parameter.- Parameters:
name
- parameter namevalue
- parameter value- Throws:
com.netscape.certsrv.property.EPropertyException
- failed to set parameter
-
getConfig
public java.lang.String getConfig(java.lang.String name)
Description copied from interface:com.netscape.certsrv.property.IConfigTemplate
Retrieves configuration parameter by name.- Returns:
- parameter
-
getDefaultConfig
public java.lang.String getDefaultConfig(java.lang.String name)
-
getValue
public java.lang.String getValue(java.lang.String name, java.util.Locale locale, com.netscape.certsrv.request.IRequest request) throws com.netscape.certsrv.profile.EProfileException
Description copied from class:ProfileInput
Retrieves value from the request.- Specified by:
getValue
in classProfileInput
- Parameters:
name
- property namelocale
- user localerequest
- request- Throws:
com.netscape.certsrv.profile.EProfileException
- failed to get value
-
setValue
public void setValue(java.lang.String name, java.util.Locale locale, com.netscape.certsrv.request.IRequest request, java.lang.String value) throws com.netscape.certsrv.property.EPropertyException
Sets the value of the given value parameter by name.- Specified by:
setValue
in classProfileInput
- Parameters:
name
- property namelocale
- user localerequest
- requestvalue
- value- Throws:
com.netscape.certsrv.property.EPropertyException
-
getLocale
public java.util.Locale getLocale(com.netscape.certsrv.request.IRequest request)
-
getConfigDescriptor
public com.netscape.certsrv.property.IDescriptor getConfigDescriptor(java.util.Locale locale, java.lang.String name)
Description copied from interface:com.netscape.certsrv.property.IConfigTemplate
Returns the descriptors of configuration parameter.- Parameters:
locale
- user localename
- configuration parameter name- Returns:
- descriptor
-
verifyPOP
public void verifyPOP(java.util.Locale locale, org.mozilla.jss.pkix.crmf.CertReqMsg certReqMsg) throws com.netscape.certsrv.profile.EProfileException
- Throws:
com.netscape.certsrv.profile.EProfileException
-
auditSubjectID
protected java.lang.String auditSubjectID()
Signed Audit Log Subject ID This method is inherited by all extended "CMSServlet"s, and is called to obtain the "SubjectID" for a signed audit log message.- Returns:
- id string containing the signed audit log message SubjectID
-
-