Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp1194387pxb; Sun, 11 Apr 2021 10:34:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzgb2qEA9EoVEoaH5xowwTDi5tTSBN/BYlYnkXc+1WvOJiUNrqeQOW94tbou9O53BFf6tYx X-Received: by 2002:a17:906:a1c5:: with SMTP id bx5mr25149483ejb.166.1618162489689; Sun, 11 Apr 2021 10:34:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618162489; cv=none; d=google.com; s=arc-20160816; b=XT3VT84x4Pa1JEPRjg1IobQkcde1LlOvOEcbUMb8nAj1BnIGkNpyv9isacsFAk7fPf LtTZkzYfilNBBLxKeszxffh/xzSn3FgKnfEkKnArj/4Gie5JESFgUMK/EI/gfXIswQ4Q Z+jYU8ltWjfYUrLBPZf+3qBG8VJFPW2mmKlR7u2NpjTRWiDr7Fy10ydFk2J9FW5Iapfh bU+K8sxPGjl2BFYEFpaipIl4XHUbtF73w3tEJ/pn8aqTastmZIzps3hNXrooeBO/33KE QOWcv7RQitVGd6tkA2bPFl4RAdVIJE+SC89jcZYQCSgBLxp+CazUwrk8SJt9CxJKCZ4G p0Jw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=gZdYxGjM5vS4dJgv0fgZ/TigJ4XDAhlJO5G9vI9SLR4=; b=BeQBH5AbaHd2YPmAoWts2ng4qrqRI2a1o0wnItMAp9QLYUOf4+SMGrq9vGzO/v+P7E el15kynqUbl6t0eaSLPUzls0c8T4fFEkOXLHpX1Gbh5OSxjsQ06Yra06VqamUpcuXMeI 3B1LUEsoMrIf8l2i1DQiFRkHrlsk4iWtt2IvH3rM/9jikYu83q4m8waAUsAfbY/BUx2l Vh9bXb7w7ukoz5JxW02yUgbR1ROvHGtNAVwA5aQqYYajY1i4WsP+5KMlsdLqynU31hKX F6IP+Fae0bi8Fe7QGabTix9KlCyZvO20DTPscLNmwDj8VXhQq2bCFc5HIJEZio4irskg RAMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=KRh4TWat; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s20si6172421edu.53.2021.04.11.10.34.24; Sun, 11 Apr 2021 10:34:49 -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=@google.com header.s=20161025 header.b=KRh4TWat; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236308AbhDKPVx (ORCPT + 99 others); Sun, 11 Apr 2021 11:21:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36784 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236021AbhDKPVw (ORCPT ); Sun, 11 Apr 2021 11:21:52 -0400 Received: from mail-yb1-xb36.google.com (mail-yb1-xb36.google.com [IPv6:2607:f8b0:4864:20::b36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 07E32C06138B for ; Sun, 11 Apr 2021 08:21:35 -0700 (PDT) Received: by mail-yb1-xb36.google.com with SMTP id x76so2157031ybe.5 for ; Sun, 11 Apr 2021 08:21:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=gZdYxGjM5vS4dJgv0fgZ/TigJ4XDAhlJO5G9vI9SLR4=; b=KRh4TWatW1ReO35QFMWUqn4uWKKPMdqnAIEXI3QzH1AIRs9aGAFZuUpoOjd315Yf// Sfk1ZSmQV4gNzmmECso56PaWuJWAUhP0u9cxrLR3XUHiuLXCsthZvUcFBAkBPjcQk/3m rC1jBtnga/MCJVqAJtOWenSpoWW5VwdIbTHqVWl1tRcN9vvJj2bU8kpHD1T940txPZNZ liMxNA/Drd+H7s/t6cyKWfuE2B2jKjfa7bnyiSDg/I1ZHmA43ue1RUQNVWrOZOGQyFNa 9fqzU3oPBe3l4acfG/HXixDuzcAHjFnJrWU2jkcqixydbhm7UnoSzCKlGY2PZdjEqMT5 YolA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=gZdYxGjM5vS4dJgv0fgZ/TigJ4XDAhlJO5G9vI9SLR4=; b=JIeHNnjECQeIHIVxeoblmT0nMAwGSKWGW3UUciaIADNxXHW8DoVFM0Q2x1166RrsaB S85vKmHK+p7G1wyJfdTiKGUTL/Cc4ZSKSLF/yQQ4JwjFa+3ZbBQqfaHRsfdBP4HUMQb+ jDgaJRcBqsKt9JJWiPWbVvtLgemgyR/qx7lV8LmFRYY86MA2Yd6H+PxpWgDAGkyJDi5u 34W4C/yYYqHXDHkYnYkHLpZXMmKDWKjNrs8VnglaQJSstfChMXrUt+w+cftAQyXlr6+Z L6qBoi9mffZOVTMxg97ZPVE8Yp6ojTLBIAAm+WzxhyiGojwF7InzpwNufQRD4YZF+6/C 1NQg== X-Gm-Message-State: AOAM531g0QTD7kXArs1K8ZziCBleiQMn7eNy/+2VidNbA8dK+TkRMZnD DAiosyl26WUafYo0duBp2PivXd7/eadptL5VbMlfbw== X-Received: by 2002:a25:e89:: with SMTP id 131mr9205440ybo.132.1618154494670; Sun, 11 Apr 2021 08:21:34 -0700 (PDT) MIME-Version: 1.0 References: <20210411112824.1149-1-phil@philpotter.co.uk> In-Reply-To: <20210411112824.1149-1-phil@philpotter.co.uk> From: Eric Dumazet Date: Sun, 11 Apr 2021 17:21:23 +0200 Message-ID: Subject: Re: [PATCH] net: geneve: check skb is large enough for IPv4/IPv6 header To: Phillip Potter Cc: David Miller , Jakub Kicinski , netdev , LKML Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Apr 11, 2021 at 1:28 PM Phillip Potter wrote: > > Check within geneve_xmit_skb/geneve6_xmit_skb that sk_buff structure > is large enough to include IPv4 or IPv6 header, and reject if not. The > geneve_xmit_skb portion and overall idea was contributed by Eric Dumazet. > Fixes a KMSAN-found uninit-value bug reported by syzbot at: > https://syzkaller.appspot.com/bug?id=abe95dc3e3e9667fc23b8d81f29ecad95c6f106f > > Suggested-by: Eric Dumazet > Reported-by: syzbot+2e406a9ac75bb71d4b7a@syzkaller.appspotmail.com > Signed-off-by: Phillip Potter Signed-off-by: Eric Dumazet Thanks !