summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/org/onap/clamp/clds/service/CldsService.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main/java/org/onap/clamp/clds/service/CldsService.java b/src/main/java/org/onap/clamp/clds/service/CldsService.java
index 888b782e1..9b68845c0 100644
--- a/src/main/java/org/onap/clamp/clds/service/CldsService.java
+++ b/src/main/java/org/onap/clamp/clds/service/CldsService.java
@@ -835,6 +835,10 @@ public class CldsService extends SecureServiceBase {
fillInCldsModel(model);
String bpmnJson = cldsBpmnTransformer.doXslTransformToString(model.getBpmnText());
logger.info("PUT bpmnJson={}", bpmnJson);
+ SecureServicePermission permisionManage = SecureServicePermission.create(cldsPermissionTypeClManage,
+ cldsPermissionInstance, CldsEvent.ACTION_DEPLOY);
+ isAuthorized(permisionManage);
+ isAuthorizedForVf(model);
ModelProperties modelProp = new ModelProperties(modelName, model.getControlName(), CldsEvent.ACTION_DEPLOY,
false, bpmnJson, model.getPropText());
checkForDuplicateServiceVf(modelName, model.getPropText());
@@ -890,6 +894,10 @@ public class CldsService extends SecureServiceBase {
LoggingUtils.setRequestContext("CldsService: Undeploy model", getPrincipalName());
Boolean errorCase = false;
try {
+ SecureServicePermission permisionManage = SecureServicePermission.create(cldsPermissionTypeClManage,
+ cldsPermissionInstance, CldsEvent.ACTION_UNDEPLOY);
+ isAuthorized(permisionManage);
+ isAuthorizedForVf(model);
String operationStatusUndeployUrl = dcaeDispatcherServices.deleteExistingDeployment(model.getDeploymentId(),
model.getTypeId());
String operationStatus = dcaeDispatcherServices.getOperationStatusWithRetry(operationStatusUndeployUrl);