From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 6E28A3857C6A; Tue, 14 Jul 2020 22:30:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6E28A3857C6A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1594765821; bh=ktMsWaCZA0Vn+GJKbaF+4uo7SzGOMeIPiPrLeDwbWrQ=; h=From:To:Subject:Date:In-Reply-To:References:From; b=LbvG82+LDxZW9A920T2cduR2XuFS9vnxmvPBDIjv8AO8YcsCw3SHiuw08nSrhujIF X/ePF1nc2VZEW4hrpNMtJ/L5CrExxNIRxCMLEhM+ivGFsFhI4lA35S7hH8PZEn6IuF 9T5WnpZHElnSeCaQtcwJyKyLNURYSnPZOM1/uEjI= From: "wilson at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/96191] aarch64 stack_protect_test canary leak Date: Tue, 14 Jul 2020 22:30:21 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: wilson at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: rsandifo at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jul 2020 22:30:21 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D96191 --- Comment #3 from Jim Wilson --- The location of the canary is not known to the attacker. You are not suppo= sed to leak the address of the canary or the value of the canary. If you leak either, then an attacker has a chance to restore the canary after clobbering it. See the descriptions of the stack_protect_set and stack_protect_test patter= ns in gcc/doc/md.texi which make clear that no intermediate values should be allowed to survive past the end of the pattern.=