Package org.apache.solr.security
Class CertAuthPlugin
- java.lang.Object
- 
- org.apache.solr.security.AuthenticationPlugin
- 
- org.apache.solr.security.CertAuthPlugin
 
 
- 
- All Implemented Interfaces:
- AutoCloseable,- SolrInfoBean,- SolrMetricProducer
 
 public class CertAuthPlugin extends AuthenticationPlugin An authentication plugin that sets principal based on the certificate subject
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from interface org.apache.solr.core.SolrInfoBeanSolrInfoBean.Category, SolrInfoBean.Group
 
- 
 - 
Field Summary- 
Fields inherited from class org.apache.solr.security.AuthenticationPluginAUTHENTICATION_PLUGIN_PROP, HTTP_HEADER_X_SOLR_AUTHDATA, numAuthenticated, numErrors, numMissingCredentials, numPassThrough, numWrongCredentials, requests, requestTimes, solrMetricsContext, totalTime
 
- 
 - 
Constructor SummaryConstructors Constructor Description CertAuthPlugin()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandoAuthenticate(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.FilterChain filterChain)This method attempts to authenticate the request.voidinit(Map<String,Object> pluginConfig)This is called upon loading up of a plugin, used for setting it up.- 
Methods inherited from class org.apache.solr.security.AuthenticationPluginauthenticate, closeRequest, getCategory, getDescription, getName, getSolrMetricsContext, initializeMetrics, interceptInternodeRequest, interceptInternodeRequest, wrapWithPrincipal, wrapWithPrincipal
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.apache.solr.metrics.SolrMetricProducerclose
 
- 
 
- 
- 
- 
Method Detail- 
initpublic void init(Map<String,Object> pluginConfig) Description copied from class:AuthenticationPluginThis is called upon loading up of a plugin, used for setting it up.- Specified by:
- initin class- AuthenticationPlugin
- Parameters:
- pluginConfig- Config parameters, possibly from a ZK source
 
 - 
doAuthenticatepublic boolean doAuthenticate(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.FilterChain filterChain) throws ExceptionDescription copied from class:AuthenticationPluginThis method attempts to authenticate the request. Upon a successful authentication, this must call the next filter in the filter chain and set the user principal of the request, or else, upon an error or an authentication failure, throw an exception.- Specified by:
- doAuthenticatein class- AuthenticationPlugin
- Parameters:
- request- the http request
- response- the http response
- filterChain- the servlet filter chain
- Returns:
- false if the request not be processed by Solr (not continue), i.e. the response and status code have already been sent.
- Throws:
- Exception- any exception thrown during the authentication, e.g. PrivilegedActionException
 
 
- 
 
-