Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp2499341lqo; Mon, 20 May 2024 07:45:46 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWR8KzXiYNIpo6YZqKZ+GeQcreA0JF9NNpXnxEjOeD152i2O4MJhopSEVcmb3JBiw1mmTEJDPUt48U1b6wDYvmAbkFHeH22IgL6f9OTQw== X-Google-Smtp-Source: AGHT+IGX4I9vZHvWO6av0hvxNtHSX590N/FhtExgMA2A/QolwqEaD1p6D5D1Sd9Ji2+VcYg9n1N5 X-Received: by 2002:a17:90a:f2d8:b0:2b9:f6bc:e4c1 with SMTP id 98e67ed59e1d1-2b9f6bceda6mr11396247a91.28.1716216345931; Mon, 20 May 2024 07:45:45 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716216345; cv=pass; d=google.com; s=arc-20160816; b=pXirpWokv7G4uZSq/v3jyAoNZkG54YwkY3DNW5JYMfw9ly++9c8UyPBrReSiCXDqNy wiJl68EogXfpkqqKviN1x09589+HmdcmJ2UILwMO+kUIwhkPLsEjOyh4yNKjC5AeJZHv g3EHLTORvU8uQla9neviFaZn6dQ0caadBYLeVSER6lOqfiyfLn9zjlJz8XqzFn3GCKhy LJeOHDfFjNDjgfrxkAb3HHpLqMF9ViiNOaNktqV3gFB+//IGa8/UIn6levSthclkuPWI Dh9zd40GI/yPZqD2tuNmb01ctDpTd3kaOi9Rbqavgk4HoOq6LMxP/FR3X1SmF/DWu4JV QLyQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=0KCk58wS70fFfp9wh3lG0S0zT2I32k7WzSL3uhS3b9w=; fh=jtvsQ3bJeBpsmBTPIFeaSP1VtIR6CB0gtadbyvgh8ao=; b=e0tcaHF0YRLJR6TT9L553p1XK1jj9cQ/rSiJZj/9kkzzH4Z02lrMn0vCl6H8WqCVAs G9ytGJ3zSwhk3Z7EgR18/78hbtUplEc34PRbxJ82Zn2KP7nqEj7Kpl15Mly0qafX9s3i b0b2xK/Qhk+gryQPa89f88Z4IG8RPQnUfKPKYFOvK8BPFIWgXfBMiBRforJUQapRWgUs 8OOY/gUd+0tovyhMryl/k7uDPupZxdKTql4ApNDJJVMwJ+0CLhh1/Er/6GMfiRNZp3+d tuUxwSsym+yytJeS7J84h9ea+azWgVVrLPsh/rnCFTNIy9kaL2WhiRBiDXhihZ1EkO3x SQaw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=H0w+Fr1t; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-183854-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-183854-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2b628865221si23174273a91.31.2024.05.20.07.45.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 May 2024 07:45:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-183854-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=H0w+Fr1t; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-183854-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-183854-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id BDBD6B231A2 for ; Mon, 20 May 2024 14:43:00 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 95F4F1369AD; Mon, 20 May 2024 14:42:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="H0w+Fr1t" Received: from out-176.mta1.migadu.com (out-176.mta1.migadu.com [95.215.58.176]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5B98F136669 for ; Mon, 20 May 2024 14:42:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.176 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716216174; cv=none; b=JzLHa5VvG5W43wPewoI7LPTd0a8YTpUEbAxf3RYVLtnx2MDQN5B5LjW8yJBIUm90PTSjTIISa6B8rwcT4fsE1EVVUH5cmxn9FrqSjWoLBtOylKRB61KAFAKdAz5geYgYyZxkKHZc3GAE/8fAKMbUmAgvova2gwhCOdSg86IPXdI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716216174; c=relaxed/simple; bh=KUgBuEaVcI4ydQagLxbGYRK4MhcScQHsdwehLTvW9Aw=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=r3/ZIahg0kXXz9s8b8NPDdV2By2rGzmuLrhtDyccDvEvYm40kz47b/CEfBtxOcvjShZvTGasboLX4b/qPSIgeo1Eq32BUGM5QHdZzEqrDRSYy3EihsjiClSYT49TC9gpVBDvwlXR2xjjhW5SHjLhBPkSGgkPUWBi/pQCao7h+fs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=H0w+Fr1t; arc=none smtp.client-ip=95.215.58.176 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev X-Envelope-To: rostedt@goodmis.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1716216170; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=0KCk58wS70fFfp9wh3lG0S0zT2I32k7WzSL3uhS3b9w=; b=H0w+Fr1tyaK0dgotrLbIBNgrB1mOi3KV38cxZpo+6Yyt4k+fO/2vrDH+iGt3UjFRD8fn/H 4uejzgWDY0WsHI9V3l3aWie7L631vo/dQ8HI4xdI0irJWkUB4r3afU3hIDSU5P51XHGC4d qup6Oab80OmddLIInLfZaL4n8I/oDYs= X-Envelope-To: bugreport@ubisectech.com X-Envelope-To: linux-trace-kernel@vger.kernel.org X-Envelope-To: linux-kernel@vger.kernel.org Date: Mon, 20 May 2024 10:42:45 -0400 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kent Overstreet To: Steven Rostedt Cc: Ubisectech Sirius , linux-trace-kernel , linux-kernel Subject: Re: UBSAN: shift-out-of-bounds in validate_sb_layout Message-ID: References: <20240520103153.245b0c51@gandalf.local.home> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240520103153.245b0c51@gandalf.local.home> X-Migadu-Flow: FLOW_OUT On Mon, May 20, 2024 at 10:31:53AM -0400, Steven Rostedt wrote: > On Mon, 20 May 2024 15:02:26 +0800 > "Ubisectech Sirius" wrote: > > > Hello. > > We are Ubisectech Sirius Team, the vulnerability lab of China ValiantSec. Recently, our team has discovered a issue in Linux kernel 6.7. Attached to the email were a PoC file of the issue. > > > > Stack dump: > > UBSAN: shift-out-of-bounds in fs/bcachefs/super-io.c:310:18 > > shift exponent 127 is too large for 32-bit type 'int' > > CPU: 0 PID: 14408 Comm: syz-executor.3 Not tainted 6.7.0 #2 > > Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.15.0-1 04/01/2014 > > Call Trace: > > > > __dump_stack lib/dump_stack.c:88 [inline] > > dump_stack_lvl+0x136/0x150 lib/dump_stack.c:106 > > ubsan_epilogue lib/ubsan.c:217 [inline] > > __ubsan_handle_shift_out_of_bounds+0x24b/0x430 lib/ubsan.c:387 > > validate_sb_layout.cold+0x1a/0x51 fs/bcachefs/super-io.c:310 > > bch2_read_super+0x980/0x1000 fs/bcachefs/super-io.c:786 > > bch2_fs_open+0x471/0x3890 fs/bcachefs/super.c:1922 > > bch2_mount+0x538/0x13c0 fs/bcachefs/fs.c:1863 > > legacy_get_tree+0x109/0x220 fs/fs_context.c:662 > > vfs_get_tree+0x93/0x380 fs/super.c:1771 > > do_new_mount fs/namespace.c:3337 [inline] > > path_mount+0x679/0x1e40 fs/namespace.c:3664 > > do_mount fs/namespace.c:3677 [inline] > > __do_sys_mount fs/namespace.c:3886 [inline] > > __se_sys_mount fs/namespace.c:3863 [inline] > > __x64_sys_mount+0x287/0x310 fs/namespace.c:3863 > > do_syscall_x64 arch/x86/entry/common.c:52 [inline] > > do_syscall_64+0x43/0x120 arch/x86/entry/common.c:83 > > entry_SYSCALL_64_after_hwframe+0x6f/0x77 > > RIP: 0033:0x7f41e1091b3e > > Code: 48 c7 c0 ff ff ff ff eb aa e8 be 0d 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 f3 0f 1e fa 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 > > RSP: 002b:00007f41e1d22e38 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5 > > RAX: ffffffffffffffda RBX: 0000000000005d82 RCX: 00007f41e1091b3e > > RDX: 0000000020005d80 RSI: 0000000020000100 RDI: 00007f41e1d22e90 > > RBP: 00007f41e1d22ed0 R08: 00007f41e1d22ed0 R09: 0000000000000080 > > R10: 0000000000000080 R11: 0000000000000202 R12: 0000000020005d80 > > R13: 0000000020000100 R14: 00007f41e1d22e90 R15: 0000000020005e00 > > > > > > Thank you for taking the time to read this email and we look forward to working with you further. > > I'm not sure why this is getting Cc'd to linux-trace-kernel. That's for > anything to do with the tracing code (trace events, tracepoints, kprobes, > uprobes, function tracer etc). > > What part of tracing is this for? Everything I've seen from Ubisectech has been duplicates of stuff syzbot found awhile ago and is already fixed.