diff options
author | steigerwald, christopher (cs741q) <cs741q@att.com> | 2019-08-29 21:03:27 +0000 |
---|---|---|
committer | steigerwald, christopher (cs741q) <cs741q@att.com> | 2019-08-29 21:03:27 +0000 |
commit | ad212f7c41322f85e4352ea3ddffe2e0ed7acaab (patch) | |
tree | 509cdd0d76572693059f97ed6ad82dcb20f8e3a7 | |
parent | e72c116b00d819fe19ebf8648c646ae485d72b16 (diff) |
iptables fix
Update modifyIpTables() in GRToolkitProvider.java.
Signed-off-by: steigerwald, christopher (cs741q) <cs741q@att.com>
Issue-ID: CCSDK-1664
Change-Id: I7a6c93aed540c083b4b1eb05c42f6e614fcdb4b0
-rwxr-xr-x | grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java b/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java index f10055a1a..119c0b9c7 100755 --- a/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java +++ b/grToolkit/provider/src/main/java/org/onap/ccsdk/sli/plugins/grtoolkit/GrToolkitProvider.java @@ -779,7 +779,7 @@ public class GrToolkitProvider implements AutoCloseable, GrToolkitService, DataT (org.opendaylight.yang.gen.v1.org.onap.ccsdk.sli.plugins.gr.toolkit.rev180926.halt.akka.traffic.input.NodeInfo) node; log.info("Isolating {}", n.getNode()); executeCommand(String.format("sudo /sbin/iptables -A INPUT -p tcp --destination-port %s -j DROP -s %s", properties.get(PropertyKeys.CONTROLLER_PORT_AKKA), n.getNode())); - executeCommand(String.format("sudo /sbin/iptables -A OUTPUT -p tcp --destination-port %s -j DROP -s %s", n.getPort(), n.getNode())); + executeCommand(String.format("sudo /sbin/iptables -A OUTPUT -p tcp --destination-port %s -j DROP -d %s", n.getPort(), n.getNode())); } } else if(task == IpTables.DELETE) { @@ -788,7 +788,7 @@ public class GrToolkitProvider implements AutoCloseable, GrToolkitService, DataT (org.opendaylight.yang.gen.v1.org.onap.ccsdk.sli.plugins.gr.toolkit.rev180926.resume.akka.traffic.input.NodeInfo) node; log.info("De-isolating {}", n.getNode()); executeCommand(String.format("sudo /sbin/iptables -D INPUT -p tcp --destination-port %s -j DROP -s %s", properties.get(PropertyKeys.CONTROLLER_PORT_AKKA), n.getNode())); - executeCommand(String.format("sudo /sbin/iptables -D OUTPUT -p tcp --destination-port %s -j DROP -s %s", n.getPort(), n.getNode())); + executeCommand(String.format("sudo /sbin/iptables -D OUTPUT -p tcp --destination-port %s -j DROP -d %s", n.getPort(), n.getNode())); } } |