Uploaded image for project: 'ModeShape'
  1. ModeShape
  2. MODE-1278

Misleading error message when logging to secured repository with wrong credentials

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Minor Minor
    • None
    • 2.5.1.GA
    • Server
    • None

      There is a secured ModeShape repository. If I try to login using invalid password I get the following error message

      The JAAS policy named 'modeshape' (nor the policy named 'other') could not be found; check the value of the 'JAAS_LOGIN_CONFIG_NAME' repository option in the configuration for the 'test-secured' repository
      org.modeshape.jcr.JcrRepository.login(JcrRepository.java:1327)
      at org.jboss.soa.modeshape.qa.tests.AuthenticationTest.logWithWrongCredentials(AuthenticationTest.java:35)
      26 lines not shown

      Caused by Password Incorrect/Password Required
      org.jboss.security.auth.spi.UsernamePasswordLoginModule.login(UsernamePasswordLoginModule.java:252)
      at org.jboss.security.auth.spi.UsersRolesLoginModule.login(UsersRolesLoginModule.java:152)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
      at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
      at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
      at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
      at org.modeshape.graph.JaasSecurityContext.<init>(JaasSecurityContext.java:115)
      at org.modeshape.graph.JaasSecurityContext.<init>(JaasSecurityContext.java:82)
      at org.modeshape.jcr.JcrRepository.login(JcrRepository.java:1324)
      at org.jboss.soa.modeshape.qa.tests.AuthenticationTest.logWithWrongCredentials(AuthenticationTest.java:35)
      26 lines not shown

      The wording of the message should be modified as using wrong credentials is not infrequent situation

              rhauch Randall Hauch (Inactive)
              jpechane Jiri Pechanec
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: