Browse Source

Merge "Removing leftovers from subnet Port Groups"

Zuul 5 months ago
parent
commit
64ec23ab39
1 changed files with 0 additions and 33 deletions
  1. 0
    33
      networking_ovn/common/acl.py

+ 0
- 33
networking_ovn/common/acl.py View File

@@ -154,39 +154,6 @@ def add_acls_for_drop_port_group(pg_name):
154 154
     return acl_list
155 155
 
156 156
 
157
-def add_acls_for_subnet_port_group(ovn, pg_name, subnet, ovn_dhcp=True):
158
-    # Allow DHCP requests for OVN native DHCP service, while responses are
159
-    # allowed in ovn-northd.
160
-    # Allow both DHCP requests and responses to pass for other DHCP services.
161
-    # We do this even if DHCP isn't enabled for the subnet
162
-    acl_list = []
163
-    if not ovn_dhcp:
164
-        acl = {"port_group": pg_name,
165
-               "priority": ovn_const.ACL_PRIORITY_ALLOW,
166
-               "action": ovn_const.ACL_ACTION_ALLOW,
167
-               "log": False,
168
-               "name": [],
169
-               "severity": [],
170
-               "direction": 'to-lport',
171
-               "match": ('outport == @%s && ip4 && ip4.src == %s && '
172
-                         'udp && udp.src == 67 && udp.dst == 68'
173
-                         ) % (pg_name, subnet['cidr'])}
174
-        acl_list.append(acl)
175
-    acl = {"port_group": pg_name,
176
-           "priority": ovn_const.ACL_PRIORITY_ALLOW,
177
-           "action": ovn_const.ACL_ACTION_ALLOW,
178
-           "log": False,
179
-           "name": [],
180
-           "severity": [],
181
-           "direction": 'from-lport',
182
-           "match": ('inport == @%s && ip4 && '
183
-                     'ip4.dst == {255.255.255.255, %s} && '
184
-                     'udp && udp.src == 68 && udp.dst == 67'
185
-                     ) % (pg_name, subnet['cidr'])}
186
-    acl_list.append(acl)
187
-    return acl_list
188
-
189
-
190 157
 def drop_all_ip_traffic_for_port(port):
191 158
     acl_list = []
192 159
     for direction, p in (('from-lport', 'inport'),

Loading…
Cancel
Save