bridge: Do not add bridges with '/' in name.
authorDaniele Di Proietto <diproiettod@vmware.com>
Tue, 2 Feb 2016 21:28:11 +0000 (13:28 -0800)
committerDaniele Di Proietto <diproiettod@vmware.com>
Thu, 4 Feb 2016 03:02:44 +0000 (19:02 -0800)
commit6f03695d7c655105bf938047dd8bde5be3c8cec3
treef35d886ba2f68bf4fe59ec4113eb26630549b0a7
parent6108ead19335aaa7006e71d58acd9167962dcd82
bridge: Do not add bridges with '/' in name.

This effectively stops vswitchd from creating bridges with '/' in the
name. OVS used to print a warning but the bridge was created anyway.

This restriction is implemented because the bridge name is part of a
filesystem path.

This check is no substitute for Mandatory Access Control, but it
certainly helps to catch the error early.

Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
[blp@ovn.org added a test]
Acked-by: Ben Pfaff <blp@ovn.org>
tests/ovs-vswitchd.at
vswitchd/bridge.c