aboutsummaryrefslogtreecommitdiffstats
path: root/cmso-service
diff options
context:
space:
mode:
Diffstat (limited to 'cmso-service')
-rwxr-xr-xcmso-service/src/main/java/org/onap/optf/cmso/aaf/AafAuthProvider.java4
1 files changed, 1 insertions, 3 deletions
diff --git a/cmso-service/src/main/java/org/onap/optf/cmso/aaf/AafAuthProvider.java b/cmso-service/src/main/java/org/onap/optf/cmso/aaf/AafAuthProvider.java
index 332ca73..0a7a69e 100755
--- a/cmso-service/src/main/java/org/onap/optf/cmso/aaf/AafAuthProvider.java
+++ b/cmso-service/src/main/java/org/onap/optf/cmso/aaf/AafAuthProvider.java
@@ -66,11 +66,9 @@ public class AafAuthProvider implements AuthenticationProvider {
sessionId = webAuthDetails.getRemoteAddress() + ":" + webAuthDetails.getSessionId();
}
}
- if (env.getProperty(AafProperties.aafEnabled.toString(), Boolean.class, true)) {
- if (clientCache.authenticate(name, password, sessionId) != AuthorizationResult.Authenticated) {
+ if (env.getProperty(AafProperties.aafEnabled.toString(), Boolean.class, true) && clientCache.authenticate(name, password, sessionId) != AuthorizationResult.Authenticated ) {
return null;
}
- }
return new UsernamePasswordAuthenticationToken(name, password, new ArrayList<>());
}