From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/14970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Jon Chesterfield Newsgroups: gmane.linux.lib.musl.general Subject: libc.so, Bsymbolic no longer necessary? Date: Mon, 2 Dec 2019 08:23:27 +0400 Message-ID: Reply-To: musl@lists.openwall.com Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0000000000009ad94d0598b0f53b" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="223082"; mail-complaints-to="usenet@blaine.gmane.org" To: musl@lists.openwall.com Original-X-From: musl-return-14986-gllmg-musl=m.gmane.org@lists.openwall.com Mon Dec 02 05:25:03 2019 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.89) (envelope-from ) id 1ibdGh-000vvE-Bp for gllmg-musl@m.gmane.org; Mon, 02 Dec 2019 05:25:03 +0100 Original-Received: (qmail 21754 invoked by uid 550); 2 Dec 2019 04:24:58 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 21721 invoked from network); 2 Dec 2019 04:24:58 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=fRw1Uiiy3Ve5BivFkiJNKU96uwmbIVxwIy5TAYKDlaE=; b=YMrjtA0lyD6SbfGgeUnWTstr6hqG3U3es5aYxkHRd+3ageSciVLvpNJzwgHoJ3n8m5 40q7zuG8Lg4VJ3+WfbKMmXTfPVTs+0CDMp+MBl3mkfJVClDIqoGy+PhwGQDpROVMCmbv 5+B3+qNvZL6oX7P7Mxa993uFy7LcwZGpJE78J8u7HgtTnAj1VlA1UipcoNZIupESoLGW Uh1JQHQKFljuj3SmEi3PhZXdBmgiCSN5GjLMlotd5ycRx7AWAvv2eP4imJOFTuCRFSwf St71Trgrflxa7cyWcmZUwGEsPIU1p4H256B79eMy1pm0cha8mVXiGcNpO0Vv0quClp70 AJQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=fRw1Uiiy3Ve5BivFkiJNKU96uwmbIVxwIy5TAYKDlaE=; b=DMC3FUD4H21m4BR5pPi9714TtmbPdatMMvT4Zb6x3AsgAdEbLD/DKPgldf6kJ89GIG YlxtC5sHZxso1xcYZwlCbE26OJ1RIwuOsSUyhU1UoIzOgQECuz6k4xsgWCKB+km/LLP/ cD1eEFCsKOL1Cj18gku+S+tFXdvan8BW0pZptyyIOF/82+0sdkqdAx3eObdlmriXWFCf k7mQlnP/A/UnOG+QUghZFhfzXyOy943h7WI8EGjpMKr6AXxox/jQnypd3FJ2+lFaLpWj byiBGXKNNeqevNU08/2DPzoTk2T3Ezf71Ycri/0tTYi/I2pRhdHFUkiLGYA0q6CH9JME jmPA== X-Gm-Message-State: APjAAAWlxOPRMpfMXhIgFAB4wBcmB1o3e5Caif97JIgt+vzxdqjYQltd AIRTRW6add4U1Ff2VSYgzs3E8bXxdJz3KHtKiZ8omsoX X-Google-Smtp-Source: APXvYqwHyJ7TlqExijF9cYufqmSgyOOW8A7/Gef2zOMnix/T0zcdL5iLl7PF36PIh4ZQpf/M/RTZSoRnT8GJWGZeaFI= X-Received: by 2002:ad4:4dc9:: with SMTP id cw9mr7399198qvb.0.1575260685783; Sun, 01 Dec 2019 20:24:45 -0800 (PST) Xref: news.gmane.org gmane.linux.lib.musl.general:14970 Archived-At: --0000000000009ad94d0598b0f53b Content-Type: text/plain; charset="UTF-8" Hey, The early design notes for musl mention linking with Bsymbolic, which seemed reasonable. I don't see that in the current Makefile, or the equivalent protected visibility. This seems to suggest that LD_PRELOAD can override calls to libc from within libc. That seems dubious. Is there a use case for this? Or is it avoided by the control flow in the loader itself? I'm thinking of building the musl loader/libc elf with protected visibility on the exported symbols and wondered whether I'm missing something. Thanks, Jon --0000000000009ad94d0598b0f53b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hey,

The ear= ly design notes for musl mention linking with Bsymbolic, which seemed reaso= nable. I don't see that in the current Makefile, or the equivalent prot= ected visibility.

This s= eems to suggest that LD_PRELOAD can override calls to libc from within libc= . That seems dubious. Is there a use case for this? Or is it avoided by the= control flow in the loader itself?

I'm thinking of building the musl loader/libc elf with prot= ected visibility on the exported symbols and wondered whether I'm missi= ng something.

Thanks,

Jon
--0000000000009ad94d0598b0f53b--