Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1206012yba; Sun, 5 May 2019 00:55:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqzi5RXnjJxieNIq0kpg13WYcaOUfTgCHnRJsTmw1YuOuDs8kbPxBK+e9qu7b0l1esLG7jGQ X-Received: by 2002:a17:902:aa48:: with SMTP id c8mr2111268plr.130.1557042913293; Sun, 05 May 2019 00:55:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557042913; cv=none; d=google.com; s=arc-20160816; b=eZZahCK4SeTldAIXRSvHqE7py8lYG6Zwz3/CgF1ypIHJ4p07F6jLYV3aD7rOumx0rR OT4CH2elelnYOMkhOUNQmt1/PirsePl6/HNSb+qlGl8RzneooI0K1JXSoRRU9YMQhLV0 IFqgXwHH1VrgVubHzhKPs8puxnvYUNq/jzYfuABe+r1ZZSFOsA0hIxAitZkJAYcYLSQv Bx+vYCXhLQL/K6gL6fVixFBM4EUTStfkYuqMFu8MHF8O26Rquwduo/56oWbWes8RahEJ sKCMlCf9fEFJJO588OKGGIRtpK2qBWRY4goeY2RN02pwDoA8KD8dRFy5FWzFFLdCz+PB I5og== 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 :references:in-reply-to:from:subject:cc:to:message-id:date; bh=rqyYDUBaI8eiBj1zcFx64k0ynowTb+FfT/D6ajZaPKE=; b=k9nWZQJ1thy5pFSjvjQOa7zor3BfbbJ7h7E9HH2uHAlT41Prf8frRBtHqLy0wUeN0/ JFhFeLDmOKAuHQUvta1E7H126GUWNRq/FYq9fpF85BixBseCv5l6ojGgaMdsD/u9lAMs LDxFgmWZXh4nPcqJEPT985Ti0KRwvqYzsQqevC5+PpDuCbadhJlQeE3LiL4gwvwZQLMt /McnTFImGH6d1J0R6pKHyZ7gs5d97HvL49a9vYXjYEcO8No/FG1TEUSHvJbGZvMNQAL5 UurMLx8Zrp68my4FojkIj+oIv2CFKWS3+0MUIvWbAqghHApBS1MNAGIuNHDti6LpJD7y Vfqg== ARC-Authentication-Results: i=1; mx.google.com; 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 a128si2689292pgc.242.2019.05.05.00.54.58; Sun, 05 May 2019 00:55:13 -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; 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 S1727661AbfEEHwX (ORCPT + 99 others); Sun, 5 May 2019 03:52:23 -0400 Received: from shards.monkeyblade.net ([23.128.96.9]:46512 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725792AbfEEHwX (ORCPT ); Sun, 5 May 2019 03:52:23 -0400 Received: from localhost (unknown [IPv6:2601:601:9f80:35cd::3d8]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id C7F8A14C048DE; Sun, 5 May 2019 00:52:22 -0700 (PDT) Date: Sun, 05 May 2019 00:52:22 -0700 (PDT) Message-Id: <20190505.005222.425677449950429602.davem@davemloft.net> To: colin.king@canonical.com Cc: pshelar@ovn.org, netdev@vger.kernel.org, dev@openvswitch.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH][next] openvswitch: check for null pointer return from nla_nest_start_noflag From: David Miller In-Reply-To: <20190501134158.15307-1-colin.king@canonical.com> References: <20190501134158.15307-1-colin.king@canonical.com> X-Mailer: Mew version 6.8 on Emacs 26.1 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Sun, 05 May 2019 00:52:23 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Colin King Date: Wed, 1 May 2019 14:41:58 +0100 > From: Colin Ian King > > The call to nla_nest_start_noflag can return null in the unlikely > event that nla_put returns -EMSGSIZE. Check for this condition to > avoid a null pointer dereference on pointer nla_reply. > > Addresses-Coverity: ("Dereference null return value") > Fixes: 11efd5cb04a1 ("openvswitch: Support conntrack zone limit") > Signed-off-by: Colin Ian King Applied, thank you.