From nobody Wed Nov 24 16:23:55 2021 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id B31871899BC6; Wed, 24 Nov 2021 16:23:56 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4HzmXr41ZNz3sqT; Wed, 24 Nov 2021 16:23:56 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from [10.0.1.4] (ralph.baldwin.cx [66.234.199.215]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id D70B23D9; Wed, 24 Nov 2021 16:23:55 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <30da11f2-d34b-d12e-836a-bf53949ed499@FreeBSD.org> Date: Wed, 24 Nov 2021 08:23:55 -0800 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:91.0) Gecko/20100101 Thunderbird/91.3.0 Subject: Re: git: b014e0f15bc7 - main - Enable ASLR by default for 64-bit executables Content-Language: en-US To: Slawa Olhovchenkov , Marcin Wojtas Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202111162226.1AGMQg00099240@gitrepo.freebsd.org> <20211124144112.GF77338@zxy.spb.ru> From: John Baldwin In-Reply-To: <20211124144112.GF77338@zxy.spb.ru> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1637771036; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=GX3dcqEUxnAMiNo0+MLVDe3mV6/CUUUkE2sY/aJiZ1M=; b=PpZj2+6vljFtKGF7kTZonKgJGWBwcyjuNFI29+vGpetQCTzHo2ggW2GFPUX3ZUejHbiXv4 l5LwDPPryxK4Hs22rHeofFYPwikzSHHnxEYt9JyLfuQbZbugO06P+c8IGUXdB7sUF/vfPe hn80QuRUG2XwuIg/HTDqww6Tzvxgo0HU83Qzxhbf+U8byvrNkUH1Vf3hTnUoTuaqZs+6qE OTH9rhInrtrMV2T9llQKby22M+ARow2O2c8D0c3mY8SjxXRrta658SOdTO71NHzMV8222j qqDibMjnPwLTgHwmEwxb5bDj805ZoN9PP7VdvmzmUDS+8CBTK0JYVSNrfS1dRw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1637771036; a=rsa-sha256; cv=none; b=r2syi1Yo1flk1mhklb5A8kzP7UOt5tz/auq886xQaMCydeo6t183+GVtZQApYMbFUXr3Eq ZVozK9kV8OoOP9+SeGCJjMAABm64e3w061NsG/kUnmx1e7UltecNg/7kDGRUbASJfM2/WM ofBkPJOoMjVQWBF9kToEXmh8kGYrZhWlMNdEZ9pEAeDmV490KFMQzRyW8LY8awQUBLiPIQ lHtShpRxojKTdDiy75lBZ8wFBrKmBb82Xxdmh5Zmh64vi7oova6qqOGgxPJzsQlGD6zTCn ZLYB9xINNjHL7Yv+3rZYq4L2nKoOHTmjjioqtzQWRoJohvsCkSh8l9GVZ6ZLnA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N On 11/24/21 6:41 AM, Slawa Olhovchenkov wrote: > On Tue, Nov 16, 2021 at 10:26:42PM +0000, Marcin Wojtas wrote: > >> >> Enable ASLR by default for 64-bit executables >> > > Now any core dumps will be useless? I believe core dumps should be fine. We include the ELF auxv values in core dumps as a NT_PROCSTAT_AUXV note that GDB (and I presume LLDB) both look at to determine the location of the main executable (AT_BASE). Once the dynamic section of the main executable is found, DT_DEBUG is used to find the linked list of shared libraries (including rtld itself) just as with PDEs. -- John Baldwin