User password in the jcr not present anymore and the user principal name is corrupted. | Community
Skip to main content
October 16, 2015
Solved

User password in the jcr not present anymore and the user principal name is corrupted.

  • October 16, 2015
  • 1 reply
  • 835 views

Hi,

We do registration over ldap and login the user by doing simple credentials login 

repository.login(new SimpleCredentials(username, password.toCharArray()), defaultWorkspace); When we do this we see that user nodes (rep:User) is created in CQ with properties like below

rep:password   {SHA-256}de6799d85ccab03d-1000-d84086c13de5737aef2e8e7c23eeef13fa0cee80580fdc62163de6bb9f90bdc4
rep:principalName CN=xyz@gmail.com,OU=Consumers,DC=consumerad,DC=co,DC=com

We use form based authentication OOTB to login the user and the login happens fine. However, in some cases we have seen that only the principal name exists for the user like

rep:principalName CN=xyz@gmail.com // There is no reference of the user AD principal name and the rep:password property is missing.

Now, if such a user logs in we see the error below. Can i know why this might be happening what areas should i look to find about the root cause of the problem?

11.12.2014 14:12:54.202 *ERROR* [192.168.130.21 [1418260374192] POST /content/j_security_check?j_validate=true HTTP/1.1] org.apache.jackrabbit.core.security.authentication.AbstractLoginModule Login failed: javax.jcr.ItemNotFoundException: 4a90b3aa-9350-3d70-9b9c-6f092eba76fd/{internal}password
        at org.apache.jackrabbit.core.ItemManager.getItemData(ItemManager.java:384)
        at org.apache.jackrabbit.core.ItemManager.getItem(ItemManager.java:328)
        at org.apache.jackrabbit.core.ItemManager.getItem(ItemManager.java:622)
        at org.apache.jackrabbit.core.NodeImpl$3.perform(NodeImpl.java:1187)
        at org.apache.jackrabbit.core.NodeImpl$3.perform(NodeImpl.java:1183)
        at org.apache.jackrabbit.core.session.SessionState.perform(SessionState.java:216)
        at org.apache.jackrabbit.core.ItemImpl.perform(ItemImpl.java:91)
        at org.apache.jackrabbit.core.NodeImpl.getProperty(NodeImpl.java:1183)
        at org.apache.jackrabbit.core.security.user.UserImpl.getCredentials(UserImpl.java:87)
        at org.apache.jackrabbit.core.security.authentication.SimpleCredentialsAuthentication.<init>(SimpleCredentialsAuthentication.java:51)
        at org.apache.jackrabbit.core.security.authentication.DefaultLoginModule.getAuthentication(DefaultLoginModule.java:274)
        at com.day.crx.core.CRXLoginModule.getAuthentication(CRXLoginModule.java:107)
        at org.apache.jackrabbit.core.security.authentication.AbstractLoginModule.authenticate(AbstractLoginModule.java:452)
        at org.apache.jackrabbit.core.security.authentication.AbstractLoginModule.login(AbstractLoginModule.java:332)
        at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at javax.security.auth.login.LoginContext.invoke(LoginContext.java:784)
        at javax.security.auth.login.LoginContext.access$000(LoginContext.java:203)
        at javax.security.auth.login.LoginContext$4.run(LoginContext.java:698)
        at javax.security.auth.login.LoginContext$4.run(LoginContext.java:696)
        at java.security.AccessController.doPrivileged(Native Method)

Thanks in advance.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by smacdonald2008

 I would suggest to create an AEM ticket to find out why this issue is occurring. 

1 reply

smacdonald2008
smacdonald2008Accepted solution
Level 10
October 16, 2015

 I would suggest to create an AEM ticket to find out why this issue is occurring.