Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp1594849pxb; Mon, 12 Apr 2021 01:47:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy8WyphkW+K9cutieVJjNclxP4RT833S/OAd5mvk4eiWGSYdwIfF/dd3WQtofzYUCiML494 X-Received: by 2002:a17:90b:2305:: with SMTP id mt5mr10804847pjb.198.1618217238231; Mon, 12 Apr 2021 01:47:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618217238; cv=none; d=google.com; s=arc-20160816; b=m9zNiplsuD2uKAHG93x8ie4ZKfWjHnW9CoFfuJJGBftZl6bGXkYWK9kQgCyATBKMv9 NJphETZv2OUOwIT09ta2ThHTkVQuS0UemDlNCn8WgESqYZ+eKK6C+9NzlY9CnGQNVUOL hQFE5TkrOt/sH4BksSj5qc48RkpxWIijOd2g0QHNpp0ocZcznI7Fj5Ds41aarRJ8qCB5 dFqiPUcoyTJpwh8e3anOCEl6n71nG4F4fJjPPzBWJCQLc2E8DSHoXSBEPn4tZJbEO0Au lq+y6Q9RpiecyY3HYtsUvgRFm4Zq0sL/rcbNND2rg1lPwqj6/wHjy9vSEmgLNSUxzsTL KxUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=dH/XPORQH1pC17FfHAPds00I3pSD4KgHfasTb2T6+F8=; b=LPOFTjKRThLKKXAiogbzM9MHZwAEy08ctUMuNniY9703WalsbvYSANpXj/I0ozMMDG UM2YW0XIho0z8J5GRdV08HfLFqeddueUAU/EDRMm8E5JfB/02FAY75olbiexwNsCAzrT vIl2p2RKOQawRZMZ4OCrNB48TdpnG1SAEqJb6ApuGYiq+auRuhB2Ro8aaYyep8Ooouzo yBGMxz9EtmM+hdaegkxcrGz4hgZMnb6WRNraFTrSW+7MZ7SUQ4/Eprw1mpcLshI+hU9O QAYrTaT6oKH0WB1AZmqiY/HrfWC8e59pOt0PRDc2B6i5Er+d7n8Ji1t1N+2+ji7qnFGY b6eg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=KwTYx5MU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g1si9789952plc.370.2021.04.12.01.47.06; Mon, 12 Apr 2021 01:47:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=KwTYx5MU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237792AbhDLIqO (ORCPT + 99 others); Mon, 12 Apr 2021 04:46:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:37260 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237468AbhDLIpC (ORCPT ); Mon, 12 Apr 2021 04:45:02 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A883C61241; Mon, 12 Apr 2021 08:44:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1618217085; bh=6ckTbPMMaDUT4z/zGAWEqSYIUtGsOiCjYlVqascaMcs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KwTYx5MU539MF+H8pM3SN5P4XI+lNUTRAU0JHVyJEAoP9KQZe1uxo+kV5zI111+jG pz/P/23EmvqNFJnQtO9x68v2eFpbO/R6TmF27NEbVChTG6+T7SUfoMbp6YXrjR2r4I Cbj7TcJMJrDpBlk/a6wrXjih0Rj/VbdvU4ehZDx4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, syzbot+8b6719da8a04beeafcc3@syzkaller.appspotmail.com, Alexander Aring , Stefan Schmidt Subject: [PATCH 4.19 63/66] net: ieee802154: forbid monitor for set llsec params Date: Mon, 12 Apr 2021 10:41:09 +0200 Message-Id: <20210412084000.161986840@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210412083958.129944265@linuxfoundation.org> References: <20210412083958.129944265@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Alexander Aring commit 88c17855ac4291fb462e13a86b7516773b6c932e upstream. This patch forbids to set llsec params for monitor interfaces which we don't support yet. Reported-by: syzbot+8b6719da8a04beeafcc3@syzkaller.appspotmail.com Signed-off-by: Alexander Aring Link: https://lore.kernel.org/r/20210405003054.256017-3-aahringo@redhat.com Signed-off-by: Stefan Schmidt Signed-off-by: Greg Kroah-Hartman --- net/ieee802154/nl802154.c | 3 +++ 1 file changed, 3 insertions(+) --- a/net/ieee802154/nl802154.c +++ b/net/ieee802154/nl802154.c @@ -1402,6 +1402,9 @@ static int nl802154_set_llsec_params(str u32 changed = 0; int ret; + if (wpan_dev->iftype == NL802154_IFTYPE_MONITOR) + return -EOPNOTSUPP; + if (info->attrs[NL802154_ATTR_SEC_ENABLED]) { u8 enabled;