Received: by 10.223.176.5 with SMTP id f5csp3447445wra; Mon, 29 Jan 2018 13:19:24 -0800 (PST) X-Google-Smtp-Source: AH8x227tEDX9mgv9Rjy/nE8pCiURDp+Rl259a+gnmbD3dXFGdGdbQxmX2pPp98EjWHJwyl2mASun X-Received: by 10.99.94.193 with SMTP id s184mr11405887pgb.423.1517260764789; Mon, 29 Jan 2018 13:19:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517260764; cv=none; d=google.com; s=arc-20160816; b=RfIJenMNyAmij9srDjJHAbit0FceMod/V1LqUpwY8IPhGjtu9QVQUlvZwroiEnDcNt V0toPqpZUESnUtcSfcfX13sQ23YVQW4nHxhF313mHMTWiqDW8na/1r2tlUZSJOZyx/pc M8ogQQ60VhFMIbzg9PuEnCry7apBAWXjZ9xywf0Lx/BE4toEBlXX+pf2NJ7jN94IpMiI QngN66ke2XuVzscRyqRNhsNwQF/fVw/NBSk4PbMRknZh+k3Eu+BA/UlrjMvzU83S0tPe kggKoZMXZpGFLWCy7dyOKJXq7iABX2gXarPt4DebjK21TdTVkBnjTpKLAfP24KYwBSzJ GcMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=wyAVT2o1KN8QiGIBky34nXJEnnMfc4iU0rRaNR61JWg=; b=oCiRromFiTZhRbQoH3yNi407v6xBCmbxkmfDQirIkWQRhNXdOlQPbY6/bghwetDWZV emfVijmGQxzDKEaq6bDfU99sKnFQOM68xFy2oR23l0L/mpdhS+4OMbE6l3m2iGxGOk8r EZmBjcUDgfag0pIyDP4YBX0L0dVPvp9wsU+hXPR541Us1PgbuLM7dcH8hGojFWl+9qrd uDkJR4gHLCVVkAyeTLzGRaPkp9tOREYe3wruK3ZqejXAQg8uQ64j5XX2R22L5B6XpVx6 l1EXeV2oetOyUiPDOQGFqtV0WdjlXUUZj5TG5az5FjFaApG4ql/0cad38HrN8YFK6bRv EcSw== 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 e12-v6si659925plj.600.2018.01.29.13.19.10; Mon, 29 Jan 2018 13:19:24 -0800 (PST) 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 S1752178AbeA2UEP (ORCPT + 99 others); Mon, 29 Jan 2018 15:04:15 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:41868 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752158AbeA2UEM (ORCPT ); Mon, 29 Jan 2018 15:04:12 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 195692EB1; Mon, 29 Jan 2018 12:59:45 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kevin Cernekee , Sebastian Gottschall , Felix Fietkau , "David S. Miller" Subject: [PATCH 3.18 43/52] net: igmp: fix source address check for IGMPv3 reports Date: Mon, 29 Jan 2018 13:57:01 +0100 Message-Id: <20180129123630.069487246@linuxfoundation.org> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180129123628.168904217@linuxfoundation.org> References: <20180129123628.168904217@linuxfoundation.org> User-Agent: quilt/0.65 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 3.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Felix Fietkau [ Upstream commit ad23b750933ea7bf962678972a286c78a8fa36aa ] Commit "net: igmp: Use correct source address on IGMPv3 reports" introduced a check to validate the source address of locally generated IGMPv3 packets. Instead of checking the local interface address directly, it uses inet_ifa_match(fl4->saddr, ifa), which checks if the address is on the local subnet (or equal to the point-to-point address if used). This breaks for point-to-point interfaces, so check against ifa->ifa_local directly. Cc: Kevin Cernekee Fixes: a46182b00290 ("net: igmp: Use correct source address on IGMPv3 reports") Reported-by: Sebastian Gottschall Signed-off-by: Felix Fietkau Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- net/ipv4/igmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/net/ipv4/igmp.c +++ b/net/ipv4/igmp.c @@ -329,7 +329,7 @@ static __be32 igmpv3_get_srcaddr(struct return htonl(INADDR_ANY); for_ifa(in_dev) { - if (inet_ifa_match(fl4->saddr, ifa)) + if (fl4->saddr == ifa->ifa_local) return fl4->saddr; } endfor_ifa(in_dev);