Disable TLS in DataRouter (CSIT)

Issue-ID: DCAEGEN2-3037
Signed-off-by: Tomasz Wrobel <tomasz.wrobel@nokia.com>
Change-Id: I01dd54ac173ed2bf705071e2bca118a068680f0a
diff --git a/csit/plans/filesprocessingconfigpmmapper/assets/addSubscriber.json b/csit/plans/filesprocessingconfigpmmapper/assets/addSubscriber.json
index 0666a7d..5d40973 100644
--- a/csit/plans/filesprocessingconfigpmmapper/assets/addSubscriber.json
+++ b/csit/plans/filesprocessingconfigpmmapper/assets/addSubscriber.json
@@ -9,12 +9,7 @@
     "metadataOnly":false,
     "suspend":false,
     "groupid":0,
-    "links":{
-       "self": "https://dmaap-dr-prov/subscribe/1",
-       "log": "https://dmaap-dr-prov/feedlog/1",
-       "feed": "https://dmaap-dr-prov/feed/1"
-    },
     "subscriber":"pmmapper",
     "decompress":true,
     "privilegedSubscriber": true
- }
\ No newline at end of file
+ }
diff --git a/csit/plans/filesprocessingconfigpmmapper/assets/config.yaml b/csit/plans/filesprocessingconfigpmmapper/assets/config.yaml
index 6f438f7..5f0406f 100644
--- a/csit/plans/filesprocessingconfigpmmapper/assets/config.yaml
+++ b/csit/plans/filesprocessingconfigpmmapper/assets/config.yaml
@@ -5,7 +5,7 @@
 key_store_pass_path: "/opt/app/pm-mapper/etc/certs/jks.pass"
 trust_store_path: "/opt/app/pm-mapper/etc/certs/trust.jks"
 trust_store_pass_path: "/opt/app/pm-mapper/etc/certs/trust.pass"
-dmaap_dr_delete_endpoint: "https://dmaap-dr-node:8443/delete"
+dmaap_dr_delete_endpoint: "http://dmaap-dr-node:8080/delete"
 dmaap_dr_feed_name: "1"
 aaf_identity: "aaf_admin@people.osaaf.org"
 aaf_password: "demo123456!"
diff --git a/csit/plans/filesprocessingconfigpmmapper/assets/node.properties b/csit/plans/filesprocessingconfigpmmapper/assets/node.properties
index 7abaf60..8ceb228 100644
--- a/csit/plans/filesprocessingconfigpmmapper/assets/node.properties
+++ b/csit/plans/filesprocessingconfigpmmapper/assets/node.properties
@@ -3,8 +3,7 @@
 # * org.onap.dmaap
 # * ===========================================================================
 # * Copyright � 2017 AT&T Intellectual Property. All rights reserved.
-# * ===========================================================================
-# * Modifications Copyright (C) 2021 Nokia Intellectual Property
+# * Copyright (C) 2021-2022 Nokia Intellectual Property
 # * ===========================================================================
 # * Licensed under the Apache License, Version 2.0 (the "License");
 # * you may not use this file except in compliance with the License.
@@ -26,10 +25,10 @@
 #    Configuration parameters set at startup for the DataRouter node
 #
 #    URL to retrieve dynamic configuration
-ProvisioningURL = https://dmaap-dr-prov:8443/internal/prov
+ProvisioningURL = http://dmaap-dr-prov:8080/internal/prov
 #
 #    URL to upload PUB/DEL/EXP logs
-LogUploadURL = https://dmaap-dr-prov:8443/internal/logs
+LogUploadURL = http://dmaap-dr-prov:8080/internal/logs
 #
 #    The port number for http as seen within the server
 IntHttpPort = 8080
@@ -87,3 +86,5 @@
 #
 #    AAF Props file path
 AAFPropsFilePath = /opt/app/osaaf/local/org.onap.dmaap-dr.props
+
+TlsEnabled = false
diff --git a/csit/plans/filesprocessingconfigpmmapper/assets/provserver.properties b/csit/plans/filesprocessingconfigpmmapper/assets/provserver.properties
index cd333ef..6190961 100644
--- a/csit/plans/filesprocessingconfigpmmapper/assets/provserver.properties
+++ b/csit/plans/filesprocessingconfigpmmapper/assets/provserver.properties
@@ -3,8 +3,7 @@
 # * org.onap.dmaap
 # * ===========================================================================
 # * Copyright � 2017 AT&T Intellectual Property. All rights reserved.
-# * ===========================================================================
-# * Modifications Copyright (C) 2021 Nokia Intellectual Property
+# * Copyright (C) 2021-2022 Nokia Intellectual Property
 # * ===========================================================================
 # * Licensed under the Apache License, Version 2.0 (the "License");
 # * you may not use this file except in compliance with the License.
@@ -25,7 +24,9 @@
 
 #Jetty Server properties
 org.onap.dmaap.datarouter.provserver.http.port           = 8080
+org.onap.dmaap.datarouter.nodeserver.http.port           = 8080
 org.onap.dmaap.datarouter.provserver.https.port          = 8443
+org.onap.dmaap.datarouter.nodeserver.https.port          = 8443
 org.onap.dmaap.datarouter.provserver.https.relaxation    = true
 
 org.onap.dmaap.datarouter.provserver.aafprops.path       = /opt/app/osaaf/local/org.onap.dmaap-dr.props
@@ -38,6 +39,7 @@
 #DMAAP-597 (Tech Dept) REST request source IP auth
 # relaxation to accommodate OOM kubernetes deploy
 org.onap.dmaap.datarouter.provserver.isaddressauthenabled = false
+org.onap.dmaap.datarouter.provserver.tlsenabled = false
 
 #Localhost address config
 org.onap.dmaap.datarouter.provserver.localhost = 127.0.0.1
diff --git a/csit/plans/filesprocessingconfigpmmapper/setup.sh b/csit/plans/filesprocessingconfigpmmapper/setup.sh
index ee6d111..5ce3e36 100644
--- a/csit/plans/filesprocessingconfigpmmapper/setup.sh
+++ b/csit/plans/filesprocessingconfigpmmapper/setup.sh
@@ -1,4 +1,20 @@
 #!/bin/bash
+# ============LICENSE_START=======================================================
+# Copyright (C) 2022 NOKIA
+# ================================================================================
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ============LICENSE_END=========================================================
+
 # Place the scripts in run order:
 source ${SCRIPTS}/common_functions.sh
 
@@ -82,22 +98,22 @@
 
 # Data Router Configuration.
 docker exec -i datarouter-prov sh -c \
-    "curl -k  -X PUT https://$DR_PROV_IP:8443/internal/api/NODES?val=dmaap-dr-node\|$GATEWAY_IP"
+    "curl -X PUT http://$DR_PROV_IP:8080/internal/api/NODES?val=dmaap-dr-node\|$GATEWAY_IP"
 docker exec -i datarouter-prov sh -c \
-    "curl -k  -X PUT https://$DR_PROV_IP:8443/internal/api/PROV_AUTH_ADDRESSES?val=dmaap-dr-prov\|$GATEWAY_IP"
+    "curl -X PUT http://$DR_PROV_IP:8080/internal/api/PROV_AUTH_ADDRESSES?val=dmaap-dr-prov\|$GATEWAY_IP"
 
 # Create PM Mapper feed and create PM Mapper subscriber on data router
 curl -v -X POST -H "Content-Type:application/vnd.dmaap-dr.feed" -H "X-DMAAP-DR-ON-BEHALF-OF:pmmapper" \
       --data-ascii @$TEST_PLANS_DIR/assets/createFeed.json \
-      --post301 --location-trusted -k https://${DR_PROV_IP}:8443
+      --post301 --location-trusted "http://${DR_PROV_IP}:8080"
 curl -v -X POST -H "Content-Type:application/vnd.dmaap-dr.subscription" -H "X-DMAAP-DR-ON-BEHALF-OF:pmmapper" \
       --data-ascii @$TEST_PLANS_DIR/assets/addSubscriber.json \
-      --post301 --location-trusted -k https://${DR_PROV_IP}:8443/subscribe/1
+      --post301 --location-trusted "http://${DR_PROV_IP}:8080/subscribe/1"
 
 docker cp pmmapper:/var/log/ONAP/dcaegen2/services/pm-mapper/pm-mapper_output.log /tmp/pmmapper.log
 sleep 10
 docker exec -it datarouter-prov sh -c "curl http://dmaap-dr-node:8080/internal/fetchProv"
-curl -k https://$DR_PROV_IP:8443/internal/prov
+curl "http://$DR_PROV_IP:8080/internal/prov"
 
 #Pass any variables required by Robot test suites in ROBOT_VARIABLES
 ROBOT_VARIABLES="-v DR_PROV_IP:${DR_PROV_IP} -v DMAAP_MR_IP:${DMAAP_MR_IP} -v CBS_IP:${CBS_IP} -v PMMAPPER_IP:${PMMAPPER_IP} -v DR_NODE_IP:${DR_NODE_IP} -v NODE_IP:${NODE_IP}"
diff --git a/csit/plans/pmmapper/assets/addSubscriber.json b/csit/plans/pmmapper/assets/addSubscriber.json
index 0666a7d..5d40973 100644
--- a/csit/plans/pmmapper/assets/addSubscriber.json
+++ b/csit/plans/pmmapper/assets/addSubscriber.json
@@ -9,12 +9,7 @@
     "metadataOnly":false,
     "suspend":false,
     "groupid":0,
-    "links":{
-       "self": "https://dmaap-dr-prov/subscribe/1",
-       "log": "https://dmaap-dr-prov/feedlog/1",
-       "feed": "https://dmaap-dr-prov/feed/1"
-    },
     "subscriber":"pmmapper",
     "decompress":true,
     "privilegedSubscriber": true
- }
\ No newline at end of file
+ }
diff --git a/csit/plans/pmmapper/assets/config.yaml b/csit/plans/pmmapper/assets/config.yaml
index c535113..8b54aa8 100644
--- a/csit/plans/pmmapper/assets/config.yaml
+++ b/csit/plans/pmmapper/assets/config.yaml
@@ -5,7 +5,7 @@
 key_store_pass_path: "/opt/app/pm-mapper/etc/certs/jks.pass"
 trust_store_path: "/opt/app/pm-mapper/etc/certs/trust.jks"
 trust_store_pass_path: "/opt/app/pm-mapper/etc/certs/trust.pass"
-dmaap_dr_delete_endpoint: https://dmaap-dr-node:8443/delete
+dmaap_dr_delete_endpoint: http://dmaap-dr-node:8080/delete
 dmaap_dr_feed_name: '1'
 aaf_identity: aaf_admin@people.osaaf.org
 aaf_password: demo123456!
diff --git a/csit/plans/pmmapper/assets/node.properties b/csit/plans/pmmapper/assets/node.properties
index ddd4ebc..dd796e7 100644
--- a/csit/plans/pmmapper/assets/node.properties
+++ b/csit/plans/pmmapper/assets/node.properties
@@ -3,6 +3,7 @@
 # * org.onap.dmaap
 # * ===========================================================================
 # * Copyright � 2017 AT&T Intellectual Property. All rights reserved.
+# * Copyright (C) 2022 Nokia Intellectual Property
 # * ===========================================================================
 # * Licensed under the Apache License, Version 2.0 (the "License");
 # * you may not use this file except in compliance with the License.
@@ -24,10 +25,10 @@
 #    Configuration parameters set at startup for the DataRouter node
 #
 #    URL to retrieve dynamic configuration
-ProvisioningURL = https://dmaap-dr-prov:8443/internal/prov
+ProvisioningURL = http://dmaap-dr-prov:8080/internal/prov
 #
 #    URL to upload PUB/DEL/EXP logs
-LogUploadURL = https://dmaap-dr-prov:8443/internal/logs
+LogUploadURL = http://dmaap-dr-prov:8080/internal/logs
 #
 #    The port number for http as seen within the server
 IntHttpPort = 8080
@@ -84,4 +85,6 @@
 CadiEnabled = false
 #
 #    AAF Props file path
-AAFPropsFilePath = /opt/app/osaaf/local/org.onap.dmaap-dr.props
\ No newline at end of file
+AAFPropsFilePath = /opt/app/osaaf/local/org.onap.dmaap-dr.props
+
+TlsEnabled = false
diff --git a/csit/plans/pmmapper/assets/provserver.properties b/csit/plans/pmmapper/assets/provserver.properties
index 20b5cb9..2f75257 100644
--- a/csit/plans/pmmapper/assets/provserver.properties
+++ b/csit/plans/pmmapper/assets/provserver.properties
@@ -3,6 +3,7 @@
 # * org.onap.dmaap
 # * ===========================================================================
 # * Copyright � 2017 AT&T Intellectual Property. All rights reserved.
+# * Copyright (C) 2022 Nokia Intellectual Property
 # * ===========================================================================
 # * Licensed under the Apache License, Version 2.0 (the "License");
 # * you may not use this file except in compliance with the License.
@@ -23,7 +24,9 @@
 
 #Jetty Server properties
 org.onap.dmaap.datarouter.provserver.http.port           = 8080
+org.onap.dmaap.datarouter.nodeserver.http.port           = 8080
 org.onap.dmaap.datarouter.provserver.https.port          = 8443
+org.onap.dmaap.datarouter.nodeserver.https.port          = 8443
 org.onap.dmaap.datarouter.provserver.https.relaxation    = true
 
 org.onap.dmaap.datarouter.provserver.aafprops.path       = /opt/app/osaaf/local/org.onap.dmaap-dr.props
@@ -36,6 +39,7 @@
 #DMAAP-597 (Tech Dept) REST request source IP auth
 # relaxation to accommodate OOM kubernetes deploy
 org.onap.dmaap.datarouter.provserver.isaddressauthenabled = false
+org.onap.dmaap.datarouter.provserver.tlsenabled = false
 
 #Localhost address config
 org.onap.dmaap.datarouter.provserver.localhost = 127.0.0.1
@@ -57,4 +61,4 @@
 org.onap.dmaap.datarouter.provserver.aaf.sub.type         = org.onap.dmaap-dr.sub
 org.onap.dmaap.datarouter.provserver.aaf.instance         = legacy
 org.onap.dmaap.datarouter.provserver.aaf.action.publish   = publish
-org.onap.dmaap.datarouter.provserver.aaf.action.subscribe = subscribe
\ No newline at end of file
+org.onap.dmaap.datarouter.provserver.aaf.action.subscribe = subscribe
diff --git a/csit/plans/pmmapper/setup.sh b/csit/plans/pmmapper/setup.sh
index a0e823b..3867f1b 100644
--- a/csit/plans/pmmapper/setup.sh
+++ b/csit/plans/pmmapper/setup.sh
@@ -1,4 +1,20 @@
 #!/bin/bash
+# ============LICENSE_START=======================================================
+# Copyright (C) 2022 NOKIA
+# ================================================================================
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ============LICENSE_END=========================================================
+
 # Place the scripts in run order:
 source ${SCRIPTS}/common_functions.sh
 
@@ -72,22 +88,22 @@
 
 # Data Router Configuration.
 docker exec -i datarouter-prov sh -c \
-    "curl -k  -X PUT https://$DR_PROV_IP:8443/internal/api/NODES?val=dmaap-dr-node\|$GATEWAY_IP"
+    "curl -X PUT http://$DR_PROV_IP:8080/internal/api/NODES?val=dmaap-dr-node\|$GATEWAY_IP"
 docker exec -i datarouter-prov sh -c \
-    "curl -k  -X PUT https://$DR_PROV_IP:8443/internal/api/PROV_AUTH_ADDRESSES?val=dmaap-dr-prov\|$GATEWAY_IP"
+    "curl -X PUT http://$DR_PROV_IP:8080/internal/api/PROV_AUTH_ADDRESSES?val=dmaap-dr-prov\|$GATEWAY_IP"
 
 # Create PM Mapper feed and create PM Mapper subscriber on data router
 curl -v -X POST -H "Content-Type:application/vnd.dmaap-dr.feed" -H "X-DMAAP-DR-ON-BEHALF-OF:pmmapper" \
       --data-ascii @$TEST_PLANS_DIR/assets/createFeed.json \
-      --post301 --location-trusted -k https://${DR_PROV_IP}:8443
+      --post301 --location-trusted "http://${DR_PROV_IP}:8080"
 curl -v -X POST -H "Content-Type:application/vnd.dmaap-dr.subscription" -H "X-DMAAP-DR-ON-BEHALF-OF:pmmapper" \
       --data-ascii @$TEST_PLANS_DIR/assets/addSubscriber.json \
-      --post301 --location-trusted -k https://${DR_PROV_IP}:8443/subscribe/1
+      --post301 --location-trusted "http://${DR_PROV_IP}:8080/subscribe/1"
 
 docker cp pmmapper:/var/log/ONAP/dcaegen2/services/pm-mapper/pm-mapper_output.log /tmp/pmmapper.log
 sleep 10
 docker exec -it datarouter-prov sh -c "curl http://dmaap-dr-node:8080/internal/fetchProv"
-curl -k https://$DR_PROV_IP:8443/internal/prov
+curl "http://$DR_PROV_IP:8080/internal/prov"
 
 #Pass any variables required by Robot test suites in ROBOT_VARIABLES
 ROBOT_VARIABLES="-v DR_PROV_IP:${DR_PROV_IP} -v DMAAP_MR_IP:${DMAAP_MR_IP} -v CBS_IP:${CBS_IP} -v PMMAPPER_IP:${PMMAPPER_IP} -v DR_NODE_IP:${DR_NODE_IP}"
diff --git a/csit/tests/filesprocessingconfigpmmapper/filesprocessingconfigpmmapper.robot b/csit/tests/filesprocessingconfigpmmapper/filesprocessingconfigpmmapper.robot
index 11b19b7..9efba80 100644
--- a/csit/tests/filesprocessingconfigpmmapper/filesprocessingconfigpmmapper.robot
+++ b/csit/tests/filesprocessingconfigpmmapper/filesprocessingconfigpmmapper.robot
@@ -13,7 +13,7 @@
 ${ASSETS_PATH}                           %{WORKSPACE}/tests/filesprocessingconfigpmmapper/assets
 ${NR_VALID_METADATA_PATH}                ${ASSETS_PATH}/valid_metadata.json
 ${CLI_EXEC_CLI_PM_LOG_CLEAR}             docker exec pmmapper /bin/sh -c "echo -n "" > /var/log/ONAP/dcaegen2/services/pm-mapper/pm-mapper_output.log"
-${PUBLISH_NODE_URL}                      https://${DR_NODE_IP}:8443/publish/1
+${PUBLISH_NODE_URL}                      http://${DR_NODE_IP}:8080/publish/1
 ${CLI_EXEC_LOGS_LIST}                    docker exec datarouter-node /bin/sh -c "ls /opt/app/datartr/logs"
 ${DOCKER_CLIENT_IMAGE}                   onap/org.onap.dcaegen2.services.pm-mapper:latest
 ${CLIENT_CONTAINER_NAME}                 pmmapper
diff --git a/csit/tests/pmmapper/assets/pm_filter_config.yaml b/csit/tests/pmmapper/assets/pm_filter_config.yaml
index aa7f6c4..c6119d3 100644
--- a/csit/tests/pmmapper/assets/pm_filter_config.yaml
+++ b/csit/tests/pmmapper/assets/pm_filter_config.yaml
@@ -12,7 +12,7 @@
 key_store_pass_path: "/opt/app/pm-mapper/etc/jks.pass"
 trust_store_path: "/opt/app/pm-mapper/etc/trust.jks"
 trust_store_pass_path: "/opt/app/pm-mapper/etc/trust.pass"
-dmaap_dr_delete_endpoint: https://dmaap-dr-node:8443/delete
+dmaap_dr_delete_endpoint: http://dmaap-dr-node:8080/delete
 dmaap_dr_feed_name: '1'
 aaf_identity: aaf_admin@people.osaaf.org
 aaf_password: demo123456!
diff --git a/csit/tests/pmmapper/assets/pm_filter_regex_config.yaml b/csit/tests/pmmapper/assets/pm_filter_regex_config.yaml
index 5cb564a..e8f181a 100644
--- a/csit/tests/pmmapper/assets/pm_filter_regex_config.yaml
+++ b/csit/tests/pmmapper/assets/pm_filter_regex_config.yaml
@@ -10,7 +10,7 @@
 key_store_pass_path: "/opt/app/pm-mapper/etc/jks.pass"
 trust_store_path: "/opt/app/pm-mapper/etc/trust.jks.b64"
 trust_store_pass_path: "/opt/app/pm-mapper/etc/trust.pass"
-dmaap_dr_delete_endpoint: https://dmaap-dr-node:8443/delete
+dmaap_dr_delete_endpoint: http://dmaap-dr-node:8080/delete
 dmaap_dr_feed_name: '1'
 aaf_identity: aaf_admin@people.osaaf.org
 aaf_password: demo123456!
diff --git a/csit/tests/pmmapper/assets/vendor_filter_config.yaml b/csit/tests/pmmapper/assets/vendor_filter_config.yaml
index 9a622ab..097cba7 100644
--- a/csit/tests/pmmapper/assets/vendor_filter_config.yaml
+++ b/csit/tests/pmmapper/assets/vendor_filter_config.yaml
@@ -9,7 +9,7 @@
 key_store_pass_path: "/opt/app/pm-mapper/etc/jks.pass"
 trust_store_path: "/opt/app/pm-mapper/etc/trust.jks"
 trust_store_pass_path: "/opt/app/pm-mapper/etc/trust.pass"
-dmaap_dr_delete_endpoint: https://dmaap-dr-node:8443/delete
+dmaap_dr_delete_endpoint: http://dmaap-dr-node:8080/delete
 dmaap_dr_feed_name: '1'
 aaf_identity: aaf_admin@people.osaaf.org
 aaf_password: demo123456!
diff --git a/csit/tests/pmmapper/pmmapper.robot b/csit/tests/pmmapper/pmmapper.robot
index b7131a3..e5d3084 100644
--- a/csit/tests/pmmapper/pmmapper.robot
+++ b/csit/tests/pmmapper/pmmapper.robot
@@ -11,7 +11,7 @@
 
 *** Variables ***
 ${CLI_EXEC_CLI_CONFIG}                   { head -n 100 | tail -50;} < /tmp/pmmapper.log
-${CLI_EXEC_CLI_SUBS}                     curl -k https://${DR_PROV_IP}:8443/internal/prov
+${CLI_EXEC_CLI_SUBS}                     curl -k http://${DR_PROV_IP}:8080/internal/prov
 ${PMMAPPER_BASE_URL}                     http://${PMMAPPER_IP}:8081
 ${DELIVERY_ENDPOINT}                     /delivery
 ${HEALTHCHECK_ENDPOINT}                  /healthcheck
@@ -25,7 +25,7 @@
 ${NON_XML_FILE}                          ${ASSETS_PATH}/diff_vendor_metadata.json
 ${CLI_EXEC_CLI_PM_LOG}                   docker exec pmmapper /bin/sh -c "cat /var/log/ONAP/dcaegen2/services/pm-mapper/pm-mapper_output.log"
 ${CLI_EXEC_CLI_PM_LOG_CLEAR}             docker exec pmmapper /bin/sh -c "echo -n "" > /var/log/ONAP/dcaegen2/services/pm-mapper/pm-mapper_output.log"
-${PUBLISH_NODE_URL}                      https://${DR_NODE_IP}:8443/publish/1
+${PUBLISH_NODE_URL}                      http://${DR_NODE_IP}:8080/publish/1
 ${TYPE-A_PM_DATA_FILE_PATH}              ${ASSETS_PATH}/A20181002.0000-1000-0015-1000_5G.xml
 ${TYPE-C_PM_DATA_FILE_PATH}              ${ASSETS_PATH}/C20190328.0000-0015.xml
 ${NR-TYPE-A_PM_DATA_FILE_PATH}           ${ASSETS_PATH}/new_radio/A20181004.0000-1000-0015-1000_5G.xml