Improve RAP security
[lgpl/argeo-commons.git] / security / plugins / org.argeo.security.equinox / src / main / java / org / argeo / security / equinox / SpringLoginModule.java
index c357a9ea7f1ae44e0e756bacfd2f15125486748e..90e8b3decedae4932ed7b6d0ba9d20d05c3c313c 100644 (file)
@@ -1,6 +1,7 @@
 package org.argeo.security.equinox;
 
 import java.util.Map;
+import java.util.concurrent.Executor;
 
 import javax.security.auth.Subject;
 import javax.security.auth.callback.Callback;
@@ -20,6 +21,7 @@ import org.springframework.security.providers.jaas.SecurityContextLoginModule;
 /** Login module which caches one subject per thread. */
 public class SpringLoginModule extends SecurityContextLoginModule {
        private AuthenticationManager authenticationManager;
+       private Executor systemExecutor;
 
        private CallbackHandler callbackHandler;
 
@@ -88,6 +90,7 @@ public class SpringLoginModule extends SecurityContextLoginModule {
                                username, password, url, workspace);
 
                try {
+                       
                        Authentication authentication = authenticationManager
                                        .authenticate(credentials);
                        registerAuthentication(authentication);
@@ -127,6 +130,10 @@ public class SpringLoginModule extends SecurityContextLoginModule {
                this.authenticationManager = authenticationManager;
        }
 
+       public void setSystemExecutor(Executor systemExecutor) {
+               this.systemExecutor = systemExecutor;
+       }
+
        // protected Subject getSubject() {
        // return subject.get();
        // }