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 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E2FEAC77B7F for ; Fri, 12 May 2023 08:20:19 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 9D77E1D9; Fri, 12 May 2023 10:19:27 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 9D77E1D9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1683879617; bh=gsxIknhruh4OfwGk39OcgGUAMGa0Zfu1HUlFnPiexmo=; h=Date:From:To:Cc:Subject:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=UOKzk+lYMIE52pxv2zaSyj2UqeJybI3QkIqBfO9/X5UXTDzxlTHUabCYVwv5pEL5Y tWdL1qe/Yg0HrF9Ww1hfR8DaiW9ES20TorIlznIc07zVCANwmLMnuRJBcoRIHrdzAk dzwgYXQ5M0y3JIU8t54jaJcuXXYqhFGTlOlxa62I= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 6EF3EF80087; Fri, 12 May 2023 10:19:01 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 077B3F8052E; Fri, 12 May 2023 10:19:01 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 70B19F8052E; Fri, 12 May 2023 10:18:58 +0200 (CEST) Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 9BE08F80087 for ; Fri, 12 May 2023 10:18:55 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 9BE08F80087 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KuhOTEmA; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=GkmGUlMA Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 1C6F020413; Fri, 12 May 2023 08:18:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1683879535; h=from:from:reply-to: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=pHVVEhj71TC5ei0Y7OES5Dbgca5o5EL3xb2/itYcJ0Y=; b=KuhOTEmAL4pz5kmY8i0dgeAn/rR9lsUkJRLIwH7Z+xh6Cst0lh9J071NEpB6OT8kASJubS /fslgokY1Z9XkE3bVTSVTMlK0jbb4+D9FwYfBoFQ61Gz34bPWn/ED054hxuRnSTYIudPC5 Xdm2mFse4BgoxYwEDvm87+xfPxZ1bOY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1683879535; h=from:from:reply-to: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=pHVVEhj71TC5ei0Y7OES5Dbgca5o5EL3xb2/itYcJ0Y=; b=GkmGUlMAOQpLCF5jriMdUR0ztxRyVPlblX6Wsfh0YPl3BEijFIyDqug5qwTPwHQrnD8gx6 o+R7lduFXbQy6RAw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id E21BB13466; Fri, 12 May 2023 08:18:54 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id o2hNNm72XWTLHQAAMHmgww (envelope-from ); Fri, 12 May 2023 08:18:54 +0000 Date: Fri, 12 May 2023 10:18:54 +0200 Message-ID: <873542aro1.wl-tiwai@suse.de> From: Takashi Iwai To: Dan Carpenter Cc: Takashi Sakamoto , Clemens Ladisch , Jaroslav Kysela , Takashi Iwai , alsa-devel@alsa-project.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH] ALSA: firewire-digi00x: prevent potential use after free In-Reply-To: References: User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII Message-ID-Hash: YSTUZMF7JUTPPNH23KQQWEX5GQJBRNUF X-Message-ID-Hash: YSTUZMF7JUTPPNH23KQQWEX5GQJBRNUF X-MailFrom: tiwai@suse.de X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Tue, 09 May 2023 11:07:11 +0200, Dan Carpenter wrote: > > This code was supposed to return an error code if init_stream() > failed, but it instead freed dg00x->rx_stream and returned success. > This potentially leads to a use after free. > > Fixes: 9a08067ec318 ("ALSA: firewire-digi00x: support AMDTP domain") > Signed-off-by: Dan Carpenter Thanks, applied now. Takashi