cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhais...@apache.org
Subject [04/19] git commit: updated refs/heads/4.9 to 20986ba
Date Fri, 23 Dec 2016 12:21:33 GMT
CLOUDSTACK-9615: Fixed applying ingress rules without ports


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/fed58eeb
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/fed58eeb
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/fed58eeb

Branch: refs/heads/4.9
Commit: fed58eebdd04cf656ada7037d5c43214c1f23b61
Parents: 7da95172
Author: Jayapalu <Jayapal@apache.org>
Authored: Thu Dec 8 16:27:16 2016 +0530
Committer: Jayapalu <Jayapal@apache.org>
Committed: Mon Dec 12 11:11:02 2016 +0530

----------------------------------------------------------------------
 systemvm/patches/debian/config/opt/cloud/bin/configure.py | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/fed58eeb/systemvm/patches/debian/config/opt/cloud/bin/configure.py
----------------------------------------------------------------------
diff --git a/systemvm/patches/debian/config/opt/cloud/bin/configure.py b/systemvm/patches/debian/config/opt/cloud/bin/configure.py
index dd62f1a..5a2a9ed 100755
--- a/systemvm/patches/debian/config/opt/cloud/bin/configure.py
+++ b/systemvm/patches/debian/config/opt/cloud/bin/configure.py
@@ -122,10 +122,10 @@ class CsAcl(CsDataBag):
             rnge = ''
             if "first_port" in self.rule.keys() and \
                self.rule['first_port'] == self.rule['last_port']:
-                    rnge = self.rule['first_port']
+                    rnge = " --dport %s " %self.rule['first_port']
             if "first_port" in self.rule.keys() and \
                self.rule['first_port'] != self.rule['last_port']:
-                    rnge = "%s:%s" % (rule['first_port'], rule['last_port'])
+                    rnge = " --dport %s:%s" % (rule['first_port'], rule['last_port'])
             if self.direction == 'ingress':
                 if rule['protocol'] == "icmp":
                     self.fw.append(["mangle", "front",
@@ -140,7 +140,7 @@ class CsAcl(CsDataBag):
                                     " -s %s " % cidr +
                                     " -p %s " % rule['protocol'] +
                                     " -m %s " % rule['protocol'] +
-                                    " --dport %s -j RETURN" % rnge])
+                                    "  %s -j RETURN" % rnge])
 
             logging.debug("Current ACL IP direction is ==> %s", self.direction)
             if self.direction == 'egress':
@@ -174,7 +174,7 @@ class CsAcl(CsDataBag):
                     fwr += " -s %s " % cidr + \
                            " -p %s " % rule['protocol'] + \
                            " -m %s " % rule['protocol'] + \
-                           " --dport %s" % rnge
+                           "  %s" % rnge
                 elif rule['protocol'] == "all":
                     fwr += " -s %s " % cidr
 


Mime
View raw message