Encrypting and Decrypting the Oracle Identity Manager user password as follows
1. Create the config directory
Create the config directory and its required to encrypt and decrypt the password. The following way to create the config directory in your home.
mkdir config
mkdir config/fwmconfig
2. Copy the WeB Logic Config Files
Copy the WebLogic OIM Domain config files to the config/fmwconfig directory. The config files are located in $DOMAIN_HOME/config/fmwconfig.
xlserver.cert
xell.csr
usermessagingconfig.xml
system-jazn-data.xml
policy-accessor-config.xml
opss-resource-types.xml
logging-template.xml
keystores.xml
jps-config.xml
jps-config-jse.xml
default-keystore.jks
.xldatabasekey
3. Setup the Class Path
If your Decrypting the password at the web logic server level, the following class path needs to be set. They are
1. source $DOMAIN_HOME/bin/setDomainEnv.sh
2. export CLASSPATH=$OIM_ORACLE_HOME/server/platform/iam-platform-utils.jar:$WL_HOME/server/lib/wlfullclient.jar:$OIM_ORACLE_HOME/designconsole/ext/spring.jar:$OIM_ORACLE_HOME/designconsole/lib/oimclient.jar:$OIM_ORACLE_HOME/designconsole/ext/commons-logging.jar:$CLASSPATH
If your going to decrypt the user password using eclipse IDE, set the following jar files into the eclipse classpath. They are
commons-logging.jar
fmw_audit.jar
glassfish.jaxb_1.0.0.0_2-1-12.jar
iam-platform-utils.jar
identitystore.jar
jacc-spi.jar
jps-api.jar
jps-az-api.jar
jps-az-common.jar
jps-az-management.jar
jps-az-rt.jar
jps-az-sspi.jar
jps-common.jar
jps-ee.jar
jps-internal.jar
jps-jboss-deployer.jar
jps-jboss.jar
jps-manifest.jar
jps-mbeans.jar
jps-patching.jar
jps-pep.jar
jps-platform.jar
jps-unsupported-api.jar
jps-upgrade.jar
jps-was.jar
jps-wls-trustprovider.jar
jps-wls.jar
jrf-api.jar
mdsrt.jar
oimclient.jar
opss-patch-wlst.jar
opss-patch.jar
oracle.security.jps.was.deployment.jar
oraclepki.jar
osdt_cert.jar
osdt_core.jar
osdt_xmlsec.jar
spring.jar
wlfullclient.jar
4. Execute the Sample Code
The Sample Code is given below to encrypt and decrypt the password.
package dcrpwd;
import com.thortech.xl.crypto.*;
public class DecryptPassword
{
public static void main(String[] args) throws tcCryptoException
{
String encryptPwd= tcCryptoUtil.encrypt("testpwd123","DBSecretKey");
System.out.println(encryptPwd);
String decryptPwd = tcCryptoUtil.decrypt(encryptPwd,"DBSecretKey" );
System.out.println(decryptPwd );
}
}
java -Doracle.security.jps.config=<Location Of the jps-config.xml file> -DDOMAIN_HOME=<Specify the Before config directory> dcrpwd.DecryptPassword
Final Sample Execution
java -Doracle.security.jps.config=c:/sample/config/fmwconfig/jps-config.xml -DDOMAIN_HOME=c:/sample dcrpwd.DecryptPassword
Final Execution Output in eclipse:
I have highlighted the encryption and decryption string in bold font below.
May 27, 2014 11:31:16 AM org.springframework.context.support.AbstractApplicationContext prepareRefresh
INFO: Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@7f8bea70: display name [org.springframework.context.support.ClassPathXmlApplicationContext@7f8bea70]; startup date [Tue May 27 11:31:16 PDT 2014]; root of context hierarchy
May 27, 2014 11:31:16 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions
INFO: Loading XML bean definitions from class path resource [META-INF/iam-spring-config.xml]
May 27, 2014 11:31:16 AM oracle.iam.platform.utils.SpringBeanFactory createBeanFactory
SEVERE: Instantiating Spring Bean Factory Failed.IOException parsing XML document from class path resource [META-INF/iam-spring-config.xml]; nested exception is java.io.FileNotFoundException: class path resource [META-INF/iam-spring-config.xml] cannot be opened because it does not exist
May 27, 2014 11:31:18 AM oracle.security.jps.internal.keystore.util.KeyStoreServiceUtil getMasterKey
WARNING: Failed to get/set credential in credstore.
May 27, 2014 11:31:18 AM oracle.security.jps.internal.keystore.util.KeyStoreServiceUtil getMasterKey
WARNING: Failed to get/set credential in credstore.
WLS ManagedService is not up running. Fall back to use system properties for configuration.
May 27, 2014 11:31:19 AM com.thortech.xl.crypto.tcCryptoHelper getKeyStoreFile
WARNING: Not able to fetch OIMPlatform instance for the given Platform. Hence defaulting to the OIMWebLogicPlatform
6013:DsDvxzJYlY47sP6WUaZNMw==
testpwd123
I got this error:
ReplyDeleteWARNING: Could not create credential store instance. Reason oracle.security.jps.service.policystore.PolicyStoreException: javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
Nov 14, 2013 6:14:20 PM oracle.iam.platform.utils.config.CSFCredentialProvider getPassword
SEVERE: IAM-0077002
oracle.security.jps.service.credstore.CredStoreException: JPS-01055: Could not create credential store instance. Reason oracle.security.jps.service.policystore.PolicyStoreException: javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
at oracle.security.jps.internal.credstore.ldap.LdapCredentialStore.(LdapCredentialStore.java:108)
Are you connecting any web server instance. Please can you share your password encrypt and decrypt code. I will look into your code and let you know the details to you.
DeleteMy program keeps failing at compile time when importing the thortech library: "error: package com.thortech.xl.crypto does not exist"
ReplyDeleteI have searched my local drives and it seems that the thortech packages installed on my machine are com.thortech.xl.ejb, com.thortech.xl.scheduler, and com.thortech.xl.systemverification.
Do you know why the crypto package wouldn't have installed with OIM 11g? I have searched for a means to download the thortech.xl.crypto package, and have had no luck.
It Turns out this existed in oimclient.jar, adding the class path resolved my issue.
Deletewhere to add the config directory in the server?
ReplyDeleteCan we run this code in Eclipse?
directory structure to decrypt and encrypt the password as follows.
DeleteConfig directory Location:
/home/oracle/oimpwd/config
Source Class File Location:
/home/oracle/oimpwd/src/dcrpwd/DecryptPassword
Execution DecryptPassword java file as follows
cd /home/oracle/oimpwd/
java dcrpwd.DecryptPassword
It will execute and give the output as follows.
log4j:WARN No appenders could be found for logger (org.springframework.context.support.ClassPathXmlApplicationContext).
log4j:WARN Please initialize the log4j system properly.
Apr 22, 2014 11:10:57 AM oracle.iam.platform.utils.SpringBeanFactory createBeanFactory
SEVERE: Instantiating Spring Bean Factory Failed.IOException parsing XML document from class path resource [META-INF/iam-spring-config.xml]; nested exception is java.io.FileNotFoundException: class path resource [META-INF/iam-spring-config.xml] cannot be opened because it does not exist
Apr 22, 2014 11:10:59 AM oracle.security.jps.internal.keystore.util.KeyStoreServiceUtil getMasterKey
WARNING: Failed to get/set credential in credstore.
Apr 22, 2014 11:10:59 AM oracle.security.jps.internal.keystore.util.KeyStoreServiceUtil getMasterKey
WARNING: Failed to get/set credential in credstore.
WLS ManagedService is not up running. Fall back to use system properties for configuration.
Apr 22, 2014 11:11:00 AM com.thortech.xl.crypto.tcCryptoHelper getKeyStoreFile
WARNING: Not able to fetch OIMPlatform instance for the given Platform. Hence defaulting to the OIMWebLogicPlatform
Please let me know if you need more info.
and also how this code will know of the files present in config directory.We have to give reference to these somwhere in the code.
ReplyDeleteI followed your procedure and I am getting this exception
ReplyDeleteWLS ManagedService is not up running. Fall back to use system properties for configuration.
java.lang.Exception
at oracle.iam.platform.utils.config.OIMPrivilegedExceptionAction.run(CSFCredentialProvider.java:212)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.iam.platform.utils.config.CSFCredentialProvider.getPassword(CSFCredentialProvider.java:75)
at oracle.iam.platform.utils.config.standalone.StandAloneCryptoConfig.getPassword(StandAloneCryptoConfig.java:80)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:67)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:96)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.encrypt(tcDefaultDBEncryptionImpl.java:193)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:118)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:152)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:133)
at com.oim.Encrypt.main(Encrypt.java:13)
Unknown Credential type to find the password for the given map : oim key : .xldatabasekey
com.thortech.xl.crypto.tcCryptoException
May 7, 2014 9:46:48 PM com.thortech.util.logging.Logger error
SEVERE: Class/Method: tcDefaultDBEncryptionImpl/initKeyStore encounter some problems: {1}
java.lang.NullPointerException
at com.thortech.xl.crypto.tcCryptoHelper.loadKeyStore(tcCryptoHelper.java:87)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:67)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:96)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.encrypt(tcDefaultDBEncryptionImpl.java:193)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:118)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:152)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:133)
at com.oim.Encrypt.main(Encrypt.java:13)
Hi Prasad.
ReplyDeletePlease can you run this component in oim server and your issue will be resolved.
I'm getting exception:-
ReplyDeleteException in thread "main" java.lang.NoClassDefFoundError: oracle/jrf/UnknownPlatformException
at com.thortech.xl.crypto.tcCryptoFactory.getSymmetricImpl(tcCryptoFactory.java:75)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:118)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:152)
at com.thortech.xl.crypto.tcCryptoUtil.encrypt(tcCryptoUtil.java:133)
at dcrpwd.DecryptPassword.main(DecryptPassword.java:7)
Caused by: java.lang.ClassNotFoundException: oracle.jrf.UnknownPlatformException
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 5 more
Code
at dcrpwd.DecryptPassword.main(DecryptPassword.java:7)
String encryptPwd = tcCryptoUtil.encrypt("testpwd123", "DBSecretKey");
Hi
ReplyDeletePlease set the class path as follows.
1. Login to the oim server.
2. execute the source $OIM_DOMAIN/bin/setDomainEnv.sh
3. export CLASS path and i have mentioned jar files in the same blog.
execute the DecryptPassword as follows
java -Doracle.security.jps.config=$DOMAIN_HOME/config/fmwconfig/jps-config.xml dcrpwd.DecryptPassword.
Please let me know if you have any issue
Do you know by any chance what Encryption Algorithm/method is used to encrypt USR password?
ReplyDeleteHi
DeleteYou can find the default encrypt algorithm for encrypt and decrypt password as follows:
tcCryptoHelper.getCryptoConfiguration().getSymmetricProviderConfig().getSignatureAlgorithm()
Default algorithm is SHA1withRSA
Please let me know if you need more info.
Hi,
ReplyDeletei am using above code to decrypt the pasword with eclipse. But facing exception as below:
"SEVERE: Class/Method: tcDefaultDBEncryptionImpl/initKeyStore encounter some problems: {1}
java.lang.NullPointerException
at oracle.iam.platform.utils.config.OIMPrivilegedExceptionAction.run(CSFCredentialProvider.java:240)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.iam.platform.utils.config.CSFCredentialProvider.getPassword(CSFCredentialProvider.java:79)
at oracle.iam.platform.utils.config.standalone.StandAloneCryptoConfig.getPassword(StandAloneCryptoConfig.java:76)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:67)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:99)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.decrypt(tcDefaultDBEncryptionImpl.java:218)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:122)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:163)
at DecryptPassword.getDecryptedValue(DecryptPassword.java:21)
at DecryptPassword.main(DecryptPassword.java:10)
com.thortech.xl.crypto.tcCryptoException
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:79)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:99)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.decrypt(tcDefaultDBEncryptionImpl.java:218)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:122)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:163)
at DecryptPassword.getDecryptedValue(DecryptPassword.java:21)
at DecryptPassword.main(DecryptPassword.java:10)
Caused by: java.lang.NullPointerException
at oracle.iam.platform.utils.config.OIMPrivilegedExceptionAction.run(CSFCredentialProvider.java:240)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.iam.platform.utils.config.CSFCredentialProvider.getPassword(CSFCredentialProvider.java:79)
at oracle.iam.platform.utils.config.standalone.StandAloneCryptoConfig.getPassword(StandAloneCryptoConfig.java:76)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:67)
... 6 more"
Can you pelase suggest me some inputs so as to decrypt the password. I am working on OIM 11g R1.
Hi
ReplyDeleteI have listed the set of jar files in the eclipse project classpath in the blog. Look the section "If your going to decrypt the user password using eclipse IDE, set the following jar files into the eclipse classpath. They are"
Please add the jar files in the eclipse classpath and let me know if you have any issues.
Hi,
ReplyDeleteWill this code also work when used against the values stored in the PWH table. I would like to get at a users password password history.
Thanks
Did you ever find a way to decrypt the PWH password history? I've run into the same issue. It doesn't appear the same method is used to encrypt the passwords in USR and PWH tables?
DeleteI am getting JPS-00065 (java.lang.ClassNotFoundException: oracle.security.jps.se.JpsSEPlatformFactory) where does this class come from?
ReplyDeleteOk, solved adding /oracle/Middleware/oracle_common/modules/oracle.jps_11.1.1/jps-se.jar to the classpath, but now I am getting JPS-00056 (The WLS ManagementService has not been initialized) -- any help is welcome, thanks
DeleteHi,
DeleteI think your running the code in the OIM installed server. You can set the classpath and issue will be resolved. You can set the classpath as follows:
1. Go to the DOMAIN_HOME/bin directory and execute source ./setSOADomainEnv.sh and it will set the classpath from the command line.
Please let me know if you need more assistance.
I am running in my local eclipse after importing all jars , i am seeing wls managementservice has not been initialized.DO i have to change content of any config file.
DeleteHi,
ReplyDeleteAdded this piece of code to my custom web application java code and deployed in weblogic admin server. Getting below error while accessing the web application. I have set path and classpath as specified int his blog. Please assist how we can use this code within webapplication
com.thortech.xl.crypto.tcCryptoException: oracle.security.jps.internal.core.runtime.JpsContextFactoryImpl cannot be cast to oracle.security.jps.JpsContextFactory
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:79)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:96)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.decrypt(tcDefaultDBEncryptionImpl.java:215)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:100)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:127)
at com.cvs.sspr.controller.Controller.decryptOIMPwd(Unknown Source)
at com.cvs.sspr.controller.Controller.submitResetHome(Unknown Source)
Hi,
DeleteCopy All your jar files into the WEB-INF/lib directory and redeploy the web application into the weblogic and restart the web logic server.
Please let me know if you need more help.
Thanks for your reply. After copying I m getting below error 500 while access custom application in weblogic server,
Deletejava.security.AccessControlException: access denied ("oracle.security.jps.JpsPermission" "AppSecurityContext.setApplicationID.null") at java.security.AccessControlContext.checkPermission(AccessControlContext.java:372) at java.security.AccessController.checkPermission(AccessController.java:559) at oracle.security.jps.util.JpsAuth$AuthorizationMechanism$3.checkPermission(JpsAuth.java:463) at oracle.security.jps.util.JpsAuth.checkPermission(JpsAuth.java:523)
Hello there,
DeleteCan you help me for above "Access Denied" exception. I m seriously stuck here and any suggestion from you will be of great to me. Also I refered to below link for any missing configuration, http://docs.oracle.com/cd/E21764_01/core.1111/e10043/devmancfg.htm#JISEC3917
Hi,
ReplyDeletePlease can you share the code and I will look the code and let you know the details.
This comment has been removed by the author.
DeleteHi,
DeleteI am posting the code to decrypt the password in OIM Web Application and this web application deployed in Web Logic OIM Admin Server. This application required sql data source to get the encrypted password from USR table. You need to pass the userid as a parameter as follows:
https://admin-server:7002/oimpwdwebapp/TestDecrptPwd?encrstring=
The code is given below.
package test.decrypt;
import java.io.IOException;
import java.io.PrintWriter;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import javax.naming.InitialContext;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.sql.DataSource;
import com.thortech.xl.crypto.tcCryptoException;
import com.thortech.xl.crypto.tcCryptoUtil;
public class TestDecrptPwd extends HttpServlet {
/**
*
*/
private static final long serialVersionUID = 3632040791412992239L;
public TestDecrptPwd() {
// TODO Auto-generated constructor stub
}
@Override
protected void service(HttpServletRequest req, HttpServletResponse resp)
throws ServletException, IOException {
PrintWriter out= resp.getWriter();
out.println("Start the TestDecrptPwd");
String value=req.getParameter("encrstring");
if(value != null)
{
out.println("Encr String Clear text "+value);
String encryptPwd;
DataSource ds=null;
Connection conn=null;
Statement stmt=null;
ResultSet rs=null;
try
{
InitialContext context= new InitialContext();
ds=(DataSource)context.lookup("testdatasource");
out.println("Data Object "+ds);
if(ds != null)
{
conn= ds.getConnection();
stmt = conn.createStatement();
rs= stmt.executeQuery("select USR_PASSWORD from USR where upper(USR_LOGIN)='"+ value + "'");
if(rs != null && rs.next() )
{
String encPwd=rs.getString("USR_PASSWORD");
out.println("Getting DB Password: "+encPwd);
String decryptPwd = tcCryptoUtil.decrypt(encPwd,"DBSecretKey");
out.println(decryptPwd);
}
}
encryptPwd = tcCryptoUtil.encrypt(value,"DBSecretKey");
out.println("Encrpting Value : "+encryptPwd);
String decryptPwd = tcCryptoUtil.decrypt(encryptPwd,"DBSecretKey");
out.println("Decrypting Value : "+decryptPwd);
} catch (tcCryptoException e)
{
e.printStackTrace();
out.println("Error Message "+e.getMessage());
} catch (SQLException e) {
// TODO Auto-generated catch block
out.println("Error Message SQL"+e.getMessage());
}
catch (Exception e) {
// TODO Auto-generated catch block
out.println("Error Message General"+e.getMessage());
e.printStackTrace();
}
finally
{
try
{
if(rs != null)
{
rs.close();
}
if(stmt != null)
{
stmt.close();
}
if(conn != null)
{
conn.close();
}
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
else
{
out.println("USer ID Value Can not be empty");
}
out.println("End the TestDecrptPwd");
}
}
Please let me know if you need more info.
Hi
DeleteI am using oim11gr2 ps3.I am approaching same method as you have described.Here setting classpath in oim env. means only to execute ./setDomainEnv.sh or do i need to add any jar related path in the script file.
Hi,
ReplyDeleteGetting the below error when trying to execute the code from OIM server after following all the steps you have mentioned.
Exception in thread "Main Thread" java.lang.NoClassDefFoundError: decrypt/DecryptPassword
Caused by: java.lang.ClassNotFoundException: decrypt.DecryptPassword
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
Could not find the main class: decrypt.DecryptPassword. Program will exit.
Hi Test,
ReplyDeletePlease can you set the classpath and issue will be resolved.
Hi,
ReplyDeleteIs there any way we can run this code from the remote machine or any alternate approach to run from remote machine.
Thanks,
Sateesh
can you share to set classpath to fix SEVERE: Class/Method: tcCryptoHelper/getCryptoConfiguration encounter some problems: oracle/security/jps/JpsException
ReplyDeletejava.lang.NoClassDefFoundError: oracle/security/jps/JpsException
Hi,
ReplyDeleteYou need to execute the java program in the OIM installed environment and setting the OIM classpath using setDomainEnv.sh or setDomainEnv.bat file. Please let me know if you need anything
Hi
Deletedo i need to connect oimoperationsdb datasource and setting classpath in oim env. means only to execute ./setDomainEnv.sh or do i need to add any jar related path in the script file.
Hi,
ReplyDeleteI followed the instructions as per your blog but getting the below error:
java dcrpwd.DecryptPassword
Error: Could not find or load main class dcrpwd.DecryptPassword
Please advise.
Hi,
ReplyDeleteI followed the above steps and running code on server where OIM is installed and getting following error
Mar 25, 2019 12:47:09 AM oracle.iam.platform.utils.config.CSFCredentialProvider getPassword
SEVERE: IAM-0077002
oracle.security.jps.service.idstore.IdentityStoreException: JPS-00056: Failed to create identity store service instance idstore.ldap.provider:idstore.ldap. Reason: weblogic.security.service.SecurityServiceRuntimeException: The WLS ManagementService has not been initialized..
at oracle.security.jps.internal.idstore.ldap.LdapIdentityStoreProvider.getIdStoreConfig(LdapIdentityStoreProvider.java:175)
at oracle.security.jps.internal.idstore.ldap.LdapIdentityStoreProvider.access$200(LdapIdentityStoreProvider.java:90)
at oracle.security.jps.internal.idstore.ldap.LdapIdentityStoreProvider$NoLibOvd.getInstance(LdapIdentityStoreProvider.java:224)
at oracle.security.jps.internal.idstore.ldap.LdapIdentityStoreProvider.getInstance(LdapIdentityStoreProvider.java:116)
at oracle.security.jps.internal.idstore.ldap.LdapIdentityStoreProvider.getInstance(LdapIdentityStoreProvider.java:90)
at oracle.security.jps.internal.core.runtime.ContextFactoryImpl.findServiceInstance(ContextFactoryImpl.java:139)
at oracle.security.jps.internal.core.runtime.ContextFactoryImpl.getContext(ContextFactoryImpl.java:170)
at oracle.security.jps.internal.core.runtime.ContextFactoryImpl.getContext(ContextFactoryImpl.java:191)
at oracle.security.jps.internal.core.runtime.JpsContextFactoryImpl.getContext(JpsContextFactoryImpl.java:132)
at oracle.security.jps.internal.core.runtime.JpsContextFactoryImpl.getContext(JpsContextFactoryImpl.java:159)
at oracle.security.jps.internal.core.runtime.JpsContextFactoryImpl.getContext(JpsContextFactoryImpl.java:165)
at oracle.iam.platform.utils.config.CSFCredentialProvider.getPassword(CSFCredentialProvider.java:74)
at oracle.iam.platform.utils.config.standalone.StandAloneCryptoConfig.getPassword(StandAloneCryptoConfig.java:76)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.initKeyStore(tcDefaultDBEncryptionImpl.java:67)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.getCipher(tcDefaultDBEncryptionImpl.java:99)
at com.thortech.xl.crypto.tcDefaultDBEncryptionImpl.decrypt(tcDefaultDBEncryptionImpl.java:218)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:122)
at com.thortech.xl.crypto.tcCryptoUtil.decrypt(tcCryptoUtil.java:163)
at DecryptPassword.getDecryptedPassword(DecryptPassword.java:13)
at DecryptPassword.main(DecryptPassword.java:8)
Caused by: weblogic.security.service.SecurityServiceRuntimeException: The WLS ManagementService has not been initialized.
at weblogic.security.utils.IdentityStoreConfigUtil.getSecurityConfiguration(IdentityStoreConfigUtil.java:138)