diff options
author | Matthew Thode <mthode@mthode.org> | 2015-02-17 18:31:57 -0600 |
---|---|---|
committer | Sasha Levin <sasha.levin@oracle.com> | 2015-03-14 15:37:12 -0400 |
commit | e664c2cc867cce095a7f07b3b3de614072aa7bb6 (patch) | |
tree | 47ddbb870b0b4e8dc54b8ad130960aad356e2aad /net | |
parent | 4946f9d29794e6b5f2efc47eb6ac23b8bf9645f6 (diff) |
net: reject creation of netdev names with colons
[ Upstream commit a4176a9391868bfa87705bcd2e3b49e9b9dd2996 ]
colons are used as a separator in netdev device lookup in dev_ioctl.c
Specific functions are SIOCGIFTXQLEN SIOCETHTOOL SIOCSIFNAME
Signed-off-by: Matthew Thode <mthode@mthode.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Diffstat (limited to 'net')
-rw-r--r-- | net/core/dev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 9704a5c1103e..5db3a3f96198 100644 --- a/net/core/dev.c +++ b/net/core/dev.c @@ -943,7 +943,7 @@ bool dev_valid_name(const char *name) return false; while (*name) { - if (*name == '/' || isspace(*name)) + if (*name == '/' || *name == ':' || isspace(*name)) return false; name++; } |