This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/22237] New: Check internal symbols of libc.so accessed via PLT or GOT
- From: "hjl.tools at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Mon, 02 Oct 2017 21:36:05 +0000
- Subject: [Bug libc/22237] New: Check internal symbols of libc.so accessed via PLT or GOT
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=22237
Bug ID: 22237
Summary: Check internal symbols of libc.so accessed via PLT or
GOT
Product: glibc
Version: 2.27
Status: NEW
Severity: normal
Priority: P2
Component: libc
Assignee: unassigned at sourceware dot org
Reporter: hjl.tools at gmail dot com
CC: drepper.fsp at gmail dot com
Depends on: 18822
Target Milestone: ---
If supported by target, internal symbols of libc.so should be accessed
without PLT nor GOT. X86 PLT relocation is checked on libc_pic.a:
[hjl@gnu-efi-2 build-x86_64-linux]$ readelf -rW libc_pic.a | grep " __" | grep
PLT32 | awk '{ print $5 }' | sort | uniq
It assumes that only symbols with "__" prefix are internal symbols. A
machine-independent script should not be checking names
of relocations. Instead it needs to look at properties of (global/weak)
symbols in objects that go into shared libraries. Symbols (defined or
undefined) that are not hidden, but are not exported from those shared
libraries, are suspect, but I'm not sure how reliably GCC will mark
undefined symbols hidden even given appropriate declarations (and there
may also be issues with undefined symbols properly called from .S sources
but not marked hidden there). So likely lists of exceptions to any such
tests would be needed (including architecture-specific exceptions for e.g.
libgcc symbols).
Referenced Bugs:
https://sourceware.org/bugzilla/show_bug.cgi?id=18822
[Bug 18822] Internal functions are called via PLT
--
You are receiving this mail because:
You are on the CC list for the bug.