Forwarding packets in a single Open vSwitch bridge
0
I am trying to emulate a L3-switch where multiple machines are connected (in no VLANs or a single VLAN.) Then I would like to configure the switch to forward packets as I want, which I had no luck. My system configuration: Host machine OS: Ubuntu 18.04. Open vSwitch 2.9.0 Client machines: UBuntu 18.04 clients in VirtualBox 5.2.20 What I want to do (basically emulating a man-in-the-middle attack.) VM1, VM2 and VM3 are connected to a virtual switch or bridge (BR0). VM1 sends a packet (e.g., HTTP GET request) to VM3. BR0 intercepts it and forward it to VM2. VM2 sends the response to VM1. BR0 forwards it to VM1 like VM3 responding. What I did: ovs-vsctl add-br br0 : Create a bridge (BR0) Create VM1,2,3 that use br0 as a network bridge. Run different webservers inside VM2 and VM3 (e.g.,...