From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C3887C4361A for ; Sat, 5 Dec 2020 07:36:17 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 173E922D50 for ; Sat, 5 Dec 2020 07:36:17 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 173E922D50 Authentication-Results: mail.kernel.org; dmarc=pass (p=none dis=none) header.from=lists.ozlabs.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 4Cp1bL5Pn9zDqfr for ; Sat, 5 Dec 2020 18:36:14 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lists.ozlabs.org; s=201707; t=1607153774; bh=FXN989fHKNRrT1Ht+s7OqmqQokX0EgHFztik8IisHTg=; h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=TqNCXMgcCLbFsAm0ZUzTHH1tsDEtKwEmIZfpjQKUD8hf1IzAgf6x4EQsIwOf4WWpq 1LQ5IN74QTcBFA0N/Kx0fnutub0yCqTHxylbJu6muIRzLCiy1UQHToj2trUVbdyT1y 2LxD4byqkH3aaU97gK4vka8mMPoCQe0CesyOESCa8fxZjhvdNGs02gh9pfJ/fTJQFK TnmzjPxpb1rYuS2BFO1gG3X/fYWYMoGZ8SZpdIF5zYqgYfbnTEYVM15y3tSAokJ85W hdUPLQ48RTaJ2AHbApFlqpvxPNaKE0+ZKM3ApaXS+PxskU4zproJZhZF3ekwLlpcvU OxjnqBW6duvGA== Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=aliyun.com (client-ip=115.124.30.5; helo=out30-5.freemail.mail.aliyun.com; envelope-from=bluce.lee@aliyun.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=quarantine dis=none) header.from=aliyun.com Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=aliyun.com header.i=@aliyun.com header.a=rsa-sha256 header.s=s1024 header.b=bckti4Xp; dkim-atps=neutral Received: from out30-5.freemail.mail.aliyun.com (out30-5.freemail.mail.aliyun.com [115.124.30.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4Cp1b80vJ8zDqbl for ; Sat, 5 Dec 2020 18:36:01 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aliyun.com; s=s1024; t=1607153744; h=Subject:To:From:Message-ID:Date:MIME-Version:Content-Type; bh=WhDYIAV+phPzGXEO/g9rCMIdupZQQcgmOEZ4YCJHI1E=; b=bckti4XpzwQtPBE9JZlYYt6Q8SNVJ7CN5uoybZTdAcsXy81kSXkqN2eIDvcUAjGSxXLh8/Z3aWC1+b11LhG6LfMmDlCEXdrPz/eqWWGH7x5vX/Q7eADI6/QmDfZA4cQhmXL4k+ZwspDWn8Kfven2J3X2j7CypK8xSVuYaFiwEPE= X-Alimail-AntiSpam: AC=CONTINUE; BC=0.2271816|-1; CH=green; DM=|CONTINUE|false|; DS=CONTINUE|ham_news_journal|0.0117554-0.00120863-0.987036; FP=0|0|0|0|0|-1|-1|-1; HT=e01e04423; MF=bluce.lee@aliyun.com; NM=1; PH=DS; RN=2; RT=2; SR=0; TI=SMTPD_---0UHZO4L3_1607153741; Received: from 172.168.2.18(mailfrom:bluce.lee@aliyun.com fp:SMTPD_---0UHZO4L3_1607153741) by smtp.aliyun-inc.com(127.0.0.1); Sat, 05 Dec 2020 15:35:42 +0800 Subject: Re: [PATCH] erofs-utils: xattr: fix OOB access due to alignment To: Gao Xiang , linux-erofs@lists.ozlabs.org References: <20201127143359.667374-1-hsiangkao@redhat.com> Message-ID: Date: Sat, 5 Dec 2020 15:35:41 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 MIME-Version: 1.0 In-Reply-To: <20201127143359.667374-1-hsiangkao@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: linux-erofs@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development of Linux EROFS file system List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Li GuiFu via Linux-erofs Reply-To: Li GuiFu Errors-To: linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Sender: "Linux-erofs" On 2020/11/27 22:33, Gao Xiang wrote: > From: Gao Xiang > > erofs_buf_write_bhops can only be safely used for block-aligned > buffers, otherwise, it could write random out-of-bound data due > to buffer alignment. Such random data is meaningless but it does > harm to reproducable builds. > > Fixes: 116ac0a254fc ("erofs-utils: introduce shared xattr support") > Reported-by: Huang Jianan > Signed-off-by: Gao Xiang > --- > lib/xattr.c | 18 +++++++++++++++++- > 1 file changed, 17 insertions(+), 1 deletion(-) > It looks good Reviewed-by: Li Guifu Thanks,