Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp1101648ybg; Mon, 27 Jul 2020 07:59:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwF+DLwTCPKC6d6VaWNDog6jZ9hSf3Fy7/RhpVtVbocTCJDrL23RORJuzlaVBKuRUm1w2/0 X-Received: by 2002:a17:906:c259:: with SMTP id bl25mr21121543ejb.303.1595861978485; Mon, 27 Jul 2020 07:59:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595861978; cv=none; d=google.com; s=arc-20160816; b=l0urPJzaQk0LtniTXV3FI53WyGVpQkW2WqJQQJnYCTRrz1OTjBME98Y1N5OjrbW32B ZKSZErusIJHNG6aAk4IkNtnZo/AZn3gs48jbg5oucY+Rfi+oTe3q17eAp/ebFKPMYrKO V4JY/aPPcerQY0U6vO0KgaEPN/dpXTzYOv7lTvPOEWRrJ/FUzUeQ0xdFwJVXTFNCpdwI oYTDAVOFmpy2B5rDHI6KyexD2tlrB023YLj4/UK56FruNjy0H3xxkv80CJ+KRvkxOs7h x1IcAza3IuFQO3gBPP+/i2LqXjbcAbVjQ+KSwZBg7T83pd5VYNBHNIvAQJOkFjHt3A9T GNdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=TkvFuceN5jtaSzIFRaFmMTmsAfPlIWdDO7sdSoKaSpw=; b=mjbMDEHNA9bor0L4T17TdsBQ9F7qhxTAODM7scnWVkwg9B69ZWbkQ2ZbWVaIyt0yod JBOt1qJdGTEkm6DR3r9UHfq1uZ9zgIkRSiy9IwQVYoEF684ppXwrAAA77cfvwE9cAzOo ljnKH5l/VTyU6qmAe5STTMIsxbxDXiCCdT75zNwNrSbEfBnsO2D+GS2FEUy1DM1Ut5/F bv7JZsGH/zoHwlG/aEwHQGe8xGvo8IVFjRVwzZetCg54nlaOGitDm8bKX4jKTO8038Ay 7RdZC7XyUiy+lO2CjenSz0FZ53E6/GNUZ3qTm1XofMI8LYO0hqjSv1257isbWZMqtxVy TOzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=oHHYVEc5; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x26si1091147ejb.350.2020.07.27.07.59.16; Mon, 27 Jul 2020 07:59:38 -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=@ziepe.ca header.s=google header.b=oHHYVEc5; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729121AbgG0O7A (ORCPT + 99 others); Mon, 27 Jul 2020 10:59:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43050 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728708AbgG0O67 (ORCPT ); Mon, 27 Jul 2020 10:58:59 -0400 Received: from mail-qk1-x742.google.com (mail-qk1-x742.google.com [IPv6:2607:f8b0:4864:20::742]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A03EBC0619D2 for ; Mon, 27 Jul 2020 07:58:59 -0700 (PDT) Received: by mail-qk1-x742.google.com with SMTP id h7so15464237qkk.7 for ; Mon, 27 Jul 2020 07:58:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=TkvFuceN5jtaSzIFRaFmMTmsAfPlIWdDO7sdSoKaSpw=; b=oHHYVEc5gtscdX6oNEqwGKJG71QcSo0Wh3LdkVEHmkW/JhR2KSGRrVQR3lciUpmSHa v0Vwe8Zww3VELryrRRUhxZw8CIuBi1dqVQKBWhzwOWdakmgLkHTr3MPIf2grpGg8D1MS 6HpaR11uS9JC0rXDm+RDhqY++zWpcCC558aFPJdBAmeImhDoEIEPpRWFlFyqjzGyQFK2 FDxLPsvTR/dqRoWxTHaXzzBqJXudlj4Ss2aRnqY2RwlnyHChjMwWiqsZSFIAQNNs+y9X qdlOoDgCXwP+pgOsXWkBkRuI9YdxRiTDOvL9/vpvKswnsCXZCKoxfa2xuL9asF3wBz13 pyfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=TkvFuceN5jtaSzIFRaFmMTmsAfPlIWdDO7sdSoKaSpw=; b=mrnJobN/YO1iUnC6e+tS+KGhDrhShv/uF2DUfcoilBMt8ssCAb1pIPCrKT3UARba6Q zXNg32ntAVlOWkKVM9oQoOQCE2mDq6fE9xoToeoRAk9mSe3HvRADj3e+siRded/0lpup VpJZbFHk0oew6J3hcVxk7z2+IkykrZn541xogJ6GKG6XsrIqKXHCeUmuwUyEDQ92C4Nh V0XhLDDfQiW4jE2CJr92kwrf9QJMnmBiW1VAjN6gYWcufSax1z7wyQzKIfVbQ1lfxLit E+UKtbQHk8TaOCycP2iWDi/3NvokaUTH4p6Z7E9lMJzNim0bgJ5Y7FLF59IaEhIcNpxR 349A== X-Gm-Message-State: AOAM530gHrX7CDq/y/+fzjNuoscPF9xHmauaOcpZuKguN+nz0PzgLcxp 8wmVOW9BMD3VOgKrcJdzdpk+Xw== X-Received: by 2002:a05:620a:142:: with SMTP id e2mr22636849qkn.418.1595861938755; Mon, 27 Jul 2020 07:58:58 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-156-34-48-30.dhcp-dynamic.fibreop.ns.bellaliant.net. [156.34.48.30]) by smtp.gmail.com with ESMTPSA id g21sm7306628qts.18.2020.07.27.07.58.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Jul 2020 07:58:57 -0700 (PDT) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1k04ae-000Cmh-Vl; Mon, 27 Jul 2020 11:58:56 -0300 Date: Mon, 27 Jul 2020 11:58:56 -0300 From: Jason Gunthorpe To: Peilin Ye Cc: Doug Ledford , Leon Romanovsky , Greg Kroah-Hartman , syzkaller-bugs@googlegroups.com, linux-kernel-mentees@lists.linuxfoundation.org, linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [Linux-kernel-mentees] [PATCH v2] infiniband: Prevent uninit-value in ucma_accept() Message-ID: <20200727145856.GA24045@ziepe.ca> References: <20200725220203.624557-1-yepeilin.cs@gmail.com> <20200726022716.635727-1-yepeilin.cs@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200726022716.635727-1-yepeilin.cs@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jul 25, 2020 at 10:27:16PM -0400, Peilin Ye wrote: > ucma_accept() is reading uninitialized memory when `in_len` is > less than `offsetof(struct rdma_ucm_accept, ece)`. Fix it. > > Reported-and-tested-by: syzbot+086ab5ca9eafd2379aa6@syzkaller.appspotmail.com > Link: https://syzkaller.appspot.com/bug?id=0bce3bb68cb383fce92f78444e3ef77c764b60ad > Signed-off-by: Peilin Ye > --- > Change in v2: > - syzbot has reported this bug as "KMSAN: uninit-value in xa_load". > Add "Reported-and-tested-by:" and "Link:" tags for it. > > drivers/infiniband/core/ucma.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Already fixed: https://lore.kernel.org/r/0-v1-d5b86dab17dc+28c25-ucma_syz_min_jgg@nvidia.com Jason