Received: by 2002:a25:d783:0:0:0:0:0 with SMTP id o125csp659312ybg; Thu, 19 Mar 2020 06:33:24 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuBsfLr9ayyNT43sYN6Gwpwk9LnwoJgMSNTTwtWg2/JFAmobXfOXP4dnDEkEH2Q54h/Z0hH X-Received: by 2002:aca:fc0f:: with SMTP id a15mr2401634oii.68.1584624804333; Thu, 19 Mar 2020 06:33:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584624804; cv=none; d=google.com; s=arc-20160816; b=nii3kiQUjjfeKJ5f5P6AdtWXw1uGi7TEsOEFuocZ3A7RFrqkuBa6aK/y0N3h+UKQuY gBJn16L9TkwXYHvfmd4X7sUaX1feMy6czfZL6FG6gHuaW452d1HgoW9IDBgCg956EYwO 6j5j/H4heZ8Mi19gPtVIFw3uUuMj69rymY7EB6hiFyWS/QRhy9YbQgpwm1Vf3v8PrcGy kY28G1dZaUATxJEMMllOA8r3jBzOWkmkR11yt6LmPhXvc7rkMzghD9c1dBLC2PMNnIMG So0iGbsOdzKMr7pjHQFG4QE4e8kh/CLQy6/uUVAphnGnXk1cI1V9gMdSot3zwtva7UFw axLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=1aPlePVJNbwLQFfzd9zDBtuFbknRtLppu3zGfs9v5Yg=; b=xPdwZRfUU3zfit3dU1UVgHWMAfZsWYQ2v0teNcuTkj9oBKuvGwPl4II8BJRW5tDxqN CVybMApjKK0sCsiTCJId1xOJE4uMYp/adso5C0PHC1JWra/14N3h/XRMkI3NNbLEKllk f137lReZBtI5NggDlplAVxOQgp8Y2JXhVQm47fsE22apofgU4tJTmVORZ+yiU29i8wAJ 84VlJ2d8K+fChdn0douf2BocAsieUXm6prU+90EGQE7wjWWTviMr58XppKZkueaEZded SkZBmduQ1F8C+41Y2mHWwkCwMWxwjXpCuRn0Bm6yjTlaHk58dyaxwyrbYnavMjkKGFTR +Tdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BAc9z17d; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 23si950328oir.119.2020.03.19.06.33.10; Thu, 19 Mar 2020 06:33:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BAc9z17d; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727023AbgCSNc5 (ORCPT + 99 others); Thu, 19 Mar 2020 09:32:57 -0400 Received: from mail.kernel.org ([198.145.29.99]:34210 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728793AbgCSNOn (ORCPT ); Thu, 19 Mar 2020 09:14:43 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0EEB9206D7; Thu, 19 Mar 2020 13:14:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1584623683; bh=crAqJyoagg8GitwByqJaPF+YkVcw17OpzZ34+rgPKAk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BAc9z17dUiEaQMMBHNoIjdo1G8Hl00kj3aT8mekmcovwBbxJtZ1ThgbQXmdsKhyjt M6pak0kDMqncBBjyl0KcpV1IAcWYFkfdyzCR8u+1xU7qEAvsYaGHiai9cro/8MKUd1 6GO+V1qUXQ/uaPz5O7bk1IAORkabNzHBVv5b+KR8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jakub Kicinski , Stefan Schmidt , "David S. Miller" Subject: [PATCH 4.14 19/99] nl802154: add missing attribute validation Date: Thu, 19 Mar 2020 14:02:57 +0100 Message-Id: <20200319123947.442125518@linuxfoundation.org> X-Mailer: git-send-email 2.25.2 In-Reply-To: <20200319123941.630731708@linuxfoundation.org> References: <20200319123941.630731708@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jakub Kicinski [ Upstream commit 9322cd7c4af2ccc7fe7c5f01adb53f4f77949e92 ] Add missing attribute validation for several u8 types. Fixes: 2c21d11518b6 ("net: add NL802154 interface for configuration of 802.15.4 devices") Signed-off-by: Jakub Kicinski Acked-by: Stefan Schmidt Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- net/ieee802154/nl_policy.c | 5 +++++ 1 file changed, 5 insertions(+) --- a/net/ieee802154/nl_policy.c +++ b/net/ieee802154/nl_policy.c @@ -30,6 +30,11 @@ const struct nla_policy ieee802154_polic [IEEE802154_ATTR_HW_ADDR] = { .type = NLA_HW_ADDR, }, [IEEE802154_ATTR_PAN_ID] = { .type = NLA_U16, }, [IEEE802154_ATTR_CHANNEL] = { .type = NLA_U8, }, + [IEEE802154_ATTR_BCN_ORD] = { .type = NLA_U8, }, + [IEEE802154_ATTR_SF_ORD] = { .type = NLA_U8, }, + [IEEE802154_ATTR_PAN_COORD] = { .type = NLA_U8, }, + [IEEE802154_ATTR_BAT_EXT] = { .type = NLA_U8, }, + [IEEE802154_ATTR_COORD_REALIGN] = { .type = NLA_U8, }, [IEEE802154_ATTR_PAGE] = { .type = NLA_U8, }, [IEEE802154_ATTR_COORD_SHORT_ADDR] = { .type = NLA_U16, }, [IEEE802154_ATTR_COORD_HW_ADDR] = { .type = NLA_HW_ADDR, },