neutron/neutron/tests/unit/api/rpc/handlers
LIU Yulong 64a0916d2b [Security] fix allowed-address-pair 0.0.0.0/0 issue
When add allowed-address-pair 0.0.0.0/0 to one port, it will
unexpectedly open all others' protocol under same security
group. IPv6 has the same problem.

The root cause is the openflow rules calculation of the
security group, it will unexpectedly allow all IP(4&6)
traffic to get through.

For openvswitch openflow firewall, this patch adds a source
mac address match for the allowed-address-pair which has
prefix lenght 0, that means all ethernet packets from this
mac will be accepted. It exactly will meet the request of
accepting any IP address from the configured VM.

Test result shows that the remote security group and
allowed address pair works:
1. Port has 0.0.0.0/0 allowed-address-pair clould send any
   IP (src) packet out.
2. Port has x.x.x.x/y allowed-address-pair could be accepted
   for those VMs under same security group.
3. Ports under same network can reach each other (remote
   security group).
4. Protocol port number could be accessed only when there
   has related rule.

Closes-bug: #1867119
Change-Id: I2e3aa7c400d7bb17cc117b65faaa160b41013dde
(cherry picked from commit 00298fe6e8)
2020-07-31 11:23:18 +00:00
..
__init__.py Fix AttributeError when using DVRServerRpcApi 2015-01-27 13:59:00 -08:00
test_dhcp_rpc.py Optimize the code that fixes the race condition of DHCP agent. 2019-06-11 09:28:40 +08:00
test_dvr_rpc.py Revert "DVR: Inter Tenant Traffic between networks not possible with shared net" 2018-10-02 15:13:49 -04:00
test_l3_rpc.py Switch to use _get_subnet_object() in ipam_backend_mixin module 2017-12-18 14:59:17 +01:00
test_resources_rpc.py use common agent topics from neutron-lib 2018-03-13 11:35:50 -06:00
test_securitygroups_rpc.py [Security] fix allowed-address-pair 0.0.0.0/0 issue 2020-07-31 11:23:18 +00:00