2 Replies Latest reply on Apr 9, 2013 12:25 PM by rodolfoarce

    jaasAuthenticator not found

    davidtwebb

      I have installed the latest jBPM distribution and when I change my beans.xml to use the JAAS authentication, I get the following error:

       

      {noformat}

      12:08:58,454 ERROR [org.jboss.seam.security.IdentityImpl] (http-localhost-127.0.0.1-8080-2) No authenticator with name [jaasAuthenticator] was found

      12:08:58,455 ERROR [org.jboss.seam.security.IdentityImpl] (http-localhost-127.0.0.1-8080-2) Login failed: org.jboss.seam.security.AuthenticationException: An Authenticator could not be located

                at org.jboss.seam.security.IdentityImpl.authenticate(IdentityImpl.java:221) [seam-security-3.1.0.Final.jar:]

      {noformat}

       

      Here is my beans.xml

       

      {code}

        <security:IdentityImpl>

          <s:modifies/>

       

       

          <!-- No real authentication: demo authentication for demo purposes -->

          <!--<security:authenticatorClass>org.drools.guvnor.server.security.DemoAuthenticator</security:authenticatorClass>-->

       

       

          <!-- JAAS based authentication -->

          <security:authenticatorName>jaasAuthenticator</security:authenticatorName>

       

       

          <!-- IDM based authentication (supports LDAP, see Seam 3 and PicketLink IDM documentation) -->

          <!--<security:authenticatorClass>org.jboss.seam.security.management.IdmAuthenticator</security:authenticator>-->

        </security:IdentityImpl>

       

       

       

       

       

        <security:jaas.JaasAuthenticator>

          <s:modifies/>

          <!--

            The following one will use the jaas configuration called "other",

            which in jboss AS means you can use properties files for users.

          -->

          <!--<jaasConfigName>other</jaasConfigName>-->

                <security:jaasConfigName>drools-guvnor</security:jaasConfigName>

        </security:jaas.JaasAuthenticator>

      {code}

       

      I have been reading articles and trying to resolve this for the last 3 hours.  Can you please tell me what I am missing?   Thank you.

        • 1. Re: jaasAuthenticator not found
          sebastian8712

          Hey David,

           

          I had the same issue - this two steps worked for me:

           

          1) beans.xml:

           

          <security:IdentityImpl>

              <s:modifies/>

              <security:authenticatorClass>org.jboss.seam.security.jaas.JaasAuthenticator</security:authenticatorClass>

          </security:IdentityImpl>

           

          <security:jaas.JaasAuthenticator>

              <security:jaasConfigName>drools-guvnor</security:jaasConfigName>

              <s:modifies />

          </security:jaas.JaasAuthenticator>

           

          <component name="org.jboss.seam.security.roleBasedPermissionResolved">

              <s:modifies/>

              <property name="enableRoleBaseAuthorization">true</property>

          </component>

           

          It is really annoying that the config suggestions in beans.xml are not updated to newer versions.

           

          Source: http://docs.jboss.org/seam/3/security/latest/reference/en-US/html/security-authentication.html#d0e212

           

          2) I added a modified seam-security jar to the war file (WEB-INF/lib) which is available here: https://community.jboss.org/message/772921#772921

           

          Of course you have to remove the old version (3.1.0).

           

          Regards,

          Sebastian

          • 2. Re: jaasAuthenticator not found
            rodolfoarce

            I tried your solution  and still get errors

             

            13:58:10,000 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"drools-guvnor.war\".WeldService" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"drools-guvnor.war\".WeldService: org.jboss.weld.exceptions.DefinitionException: Exception List with 1 exceptions:

            Exception 0 :

            java.lang.Exception

                      at org.jboss.solder.config.xml.bootstrap.XmlConfigExtension.beforeBeanDiscovery(XmlConfigExtension.java:121)

                      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

                      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

                      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

                      at java.lang.reflect.Method.invoke(Method.java:601)

                      at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:264)

                      at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52)

                      at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137)

                      at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:260)

                      at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:170)

                      at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:51)

                      at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:154)

                      at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:241)

                      at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:229)

                      at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:207)

                      at org.jboss.weld.bootstrap.events.AbstractContainerEvent.fire(AbstractContainerEvent.java:75)

                      at org.jboss.weld.bootstrap.events.AbstractDefinitionContainerEvent.fire(AbstractDefinitionContainerEvent.java:46)

                      at org.jboss.weld.bootstrap.events.BeforeBeanDiscoveryImpl.fire(BeforeBeanDiscoveryImpl.java:46)

                      at org.jboss.weld.bootstrap.WeldBootstrap.startInitialization(WeldBootstrap.java:322)

                      at org.jboss.as.weld.WeldContainer.start(WeldContainer.java:81)

                      at org.jboss.as.weld.services.WeldService.start(WeldService.java:76)

                      at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)

                      at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)

                      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

                      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

                      at java.lang.Thread.run(Thread.java:722)

            "}}}}

            13:58:10,170 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back

            13:58:10,183 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back

            13:58:10,190 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back

            13:58:10,196 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back

            13:58:10,203 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back