summaryrefslogtreecommitdiffstats
path: root/aai-core/src
diff options
context:
space:
mode:
authorWilliam Reehil <william.reehil@att.com>2020-07-06 17:57:54 +0000
committerGerrit Code Review <gerrit@onap.org>2020-07-06 17:57:54 +0000
commit6a7dd87128b369c1bea97bf05f16ca1873f1d8e4 (patch)
treeba54715eb4ee59aae4984693780276e94b7c9369 /aai-core/src
parent264338ad578277ecc88dddf413e7be3f6e4f0232 (diff)
parentdc9232b50a286b08d775ce6471697b53d9b483ce (diff)
Merge "Critical Sonar bug fix"
Diffstat (limited to 'aai-core/src')
-rw-r--r--aai-core/src/main/java/org/onap/aai/util/HttpsAuthClient.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/aai-core/src/main/java/org/onap/aai/util/HttpsAuthClient.java b/aai-core/src/main/java/org/onap/aai/util/HttpsAuthClient.java
index c2bfabf4..84935cdb 100644
--- a/aai-core/src/main/java/org/onap/aai/util/HttpsAuthClient.java
+++ b/aai-core/src/main/java/org/onap/aai/util/HttpsAuthClient.java
@@ -93,9 +93,9 @@ public class HttpsAuthClient {
ctx = SSLContext.getInstance("TLSv1.2");
KeyManagerFactory kmf = null;
- try {
+
+ try(FileInputStream fin = new FileInputStream(keystorePath)) {
kmf = KeyManagerFactory.getInstance("SunX509");
- FileInputStream fin = new FileInputStream(keystorePath);
KeyStore ks = KeyStore.getInstance("PKCS12");
char[] pwd = keystorePassword.toCharArray();
ks.load(fin, pwd);