Package org.alfresco.solr.security
Class SecretSharedAuthPlugin
- java.lang.Object
-
- org.apache.solr.security.AuthenticationPlugin
-
- org.alfresco.solr.security.SecretSharedAuthPlugin
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
public class SecretSharedAuthPlugin extends org.apache.solr.security.AuthenticationPluginSOLR Authentication Plugin based in shared secret token via request header. This Web Filter is loaded from SOLR_HOME/security.json file, so it will be executed for every request to SOLR. Authentication logic is only applied when Alfresco Communication is using "secret" method but it doesn't apply to "none" and "https" methods.
-
-
Constructor Summary
Constructors Constructor Description SecretSharedAuthPlugin()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()booleandoAuthenticate(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain)Verify that request header includes "secret" word when using "secret" communication method.voidinit(java.util.Map<java.lang.String,java.lang.Object> parameters)
-
-
-
Method Detail
-
doAuthenticate
public boolean doAuthenticate(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain) throws java.lang.ExceptionVerify that request header includes "secret" word when using "secret" communication method. "alfresco.secureComms.secret" value is expected as Java environment variable.- Specified by:
doAuthenticatein classorg.apache.solr.security.AuthenticationPlugin- Throws:
java.lang.Exception
-
init
public void init(java.util.Map<java.lang.String,java.lang.Object> parameters)
- Specified by:
initin classorg.apache.solr.security.AuthenticationPlugin
-
close
public void close() throws java.io.IOException- Throws:
java.io.IOException
-
-