aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorBansal, Nitin (nb121v) <nitin.bansal@amdocs.com>2019-01-10 10:53:20 -0500
committerBansal, Nitin (nb121v) <nitin.bansal@amdocs.com>2019-01-10 10:55:29 -0500
commit1d3b5fa96b41dd13e1d9f9f1c0e1d3929e4a432d (patch)
treee3d80ffc1867a3f38adbe7d2bfcb7421e9b101cb /src/main/java
parenta11b8dda11186bf9c760fce77d080a4390702566 (diff)
Support clear text keystore pwd
Support clear text keystore pwd Change-Id: I49580543ebadbe0d578695b01d973e13b2bac9c6 Issue-ID: AAI-2046 Signed-off-by: Bansal, Nitin (nb121v) <nitin.bansal@amdocs.com>
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/org/onap/aai/datarouter/util/SearchServiceAgent.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/org/onap/aai/datarouter/util/SearchServiceAgent.java b/src/main/java/org/onap/aai/datarouter/util/SearchServiceAgent.java
index bbdb4c8..612a40e 100644
--- a/src/main/java/org/onap/aai/datarouter/util/SearchServiceAgent.java
+++ b/src/main/java/org/onap/aai/datarouter/util/SearchServiceAgent.java
@@ -96,13 +96,14 @@ public class SearchServiceAgent {
String documentEndpoint,
Logger logger) {
+ String deobfuscatedCertPassword = keystorePwd.startsWith("OBF:")?Password.deobfuscate(keystorePwd):keystorePwd;
// Create REST client for search service
searchClient = new RestClient()
.authenticationMode(RestAuthenticationMode.SSL_CERT)
.validateServerHostname(false)
.validateServerCertChain(true)
.clientCertFile(DataRouterConstants.DR_HOME_AUTH + certName)
- .clientCertPassword(Password.deobfuscate(keystorePwd))
+ .clientCertPassword(deobfuscatedCertPassword)
.trustStore(DataRouterConstants.DR_HOME_AUTH + keystore);
this.searchUrl = searchUrl;