Monday, February 13, 2012

Reset password in weblogic portal

Error message

Caused By: javax.security.auth.login.FailedLoginException: [Security:090302]
Authentication Failed: User canopiadmin denied
       at weblogic.security.providers.authentication.shared.DBMSAtnLoginModuleImpl.login(DBMSAtnLoginModuleImpl.java:285)
       at com.bea.common.security.internal.service.LoginModuleWrapper$1.run(LoginModuleWrapper.java:110)
       at java.security.AccessController.doPrivileged(Native Method)
       at com.bea.common.security.internal.service.LoginModuleWrapper.login(LoginModuleWrapper.java:106)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       Truncated. see log file for complete stacktrace

 
In weblogic portal the authentication happens via DB, since it uses SQL based authentication.
1. We need to enter the original username password in database
2. enable plain text password in config.xml if its not already so, since the above entered credentials are in plaintext and table will have encrypted values.

to enable plaintext in config.xml as

<wls:plaintext-passwords-enabled>true</wls:plaintext-passwords-enabled>

so it would look like below in config.xml

<realm>
     <sec:authentication-provider xsi:type="wls:sql-authenticatorType">
       <sec:control-flag>SUFFICIENT</sec:control-flag>
       <wls:data-source-name>p**nDataSource</wls:data-source-name>
       <wls:plaintext-passwords-enabled>true</wls:plaintext-passwords-enabled>
 

3. restart the servers.

plaintext password is reachable via console as
console - security realm - myrealm - providers - authentication - select the respective sql authenticator - config - provider specific - Plaintext Passwords Enabled

You may disable plain text after successful login,  

No comments: