Fix blocker sonar issues in dmaap-kafka11aaf
[dmaap/kafka11aaf.git] / src / main / java / org / onap / dmaap / commonauth / kafka / base / authorization / Cadi3AAFProvider.java
index 5a3be57..9cc45fe 100644 (file)
@@ -54,8 +54,6 @@ public class Cadi3AAFProvider implements AuthorizationProvider {
        private static AAFAuthn<?> aafAuthn;
        private static AbsAAFLur<AAFPermission> aafLur;
 
-       private static boolean props_ok = false;
-
        private static final Logger logger = LoggerFactory.getLogger(Cadi3AAFProvider.class);
 
        public Cadi3AAFProvider() {
@@ -85,11 +83,6 @@ public class Cadi3AAFProvider implements AuthorizationProvider {
                                logger.error("Unable to load " + CADI_PROPERTIES);
                                logger.error("Error", e);
                        }
-
-                       props_ok = true;
-                       if (props_ok == false) {
-                               return;
-                       }
                }
 
                if (aafAuthn == null) {
@@ -101,7 +94,6 @@ public class Cadi3AAFProvider implements AuthorizationProvider {
                                aafAuthn = null;
                                if (access != null)
                                        access.log(e, "Failed to initialize AAF");
-                               props_ok = false;
                        }
                }
 
@@ -123,7 +115,7 @@ public class Cadi3AAFProvider implements AuthorizationProvider {
                                hasPermission = true;
                                return hasPermission;
                        }
-                       AAFPermission perm = new AAFPermission(MR_NAMESPACE, permission, instance, action);
+                       AAFPermission perm = new AAFPermission(null, permission, instance, action);
                        if (aafLur != null) {
                                hasPermission = aafLur.fish(new UnAuthPrincipal(userId), perm);
                                logger.trace("Permission: " + perm.getKey() + " for user :" + userId + " found: " + hasPermission);