[NETLINK]: Make use of NLA_STRING/NLA_NUL_STRING attribute validation
[deliverable/linux.git] / net / ipv4 / devinet.c
index 0487677729cf126cf95f1264b823f7edfd80365b..8e8d1f17d77a7c29009fbcbc760a290259d5afc2 100644 (file)
@@ -85,7 +85,7 @@ static struct nla_policy ifa_ipv4_policy[IFA_MAX+1] __read_mostly = {
        [IFA_ADDRESS]           = { .type = NLA_U32 },
        [IFA_BROADCAST]         = { .type = NLA_U32 },
        [IFA_ANYCAST]           = { .type = NLA_U32 },
-       [IFA_LABEL]             = { .type = NLA_STRING },
+       [IFA_LABEL]             = { .type = NLA_STRING, .len = IFNAMSIZ - 1 },
 };
 
 static void rtmsg_ifa(int event, struct in_ifaddr *, struct nlmsghdr *, u32);
This page took 0.027365 seconds and 5 git commands to generate.