From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/13058 Path: news.gmane.org!.POSTED!not-for-mail From: Reiner Herrmann Newsgroups: gmane.linux.lib.musl.general Subject: Re: Segmentation fault in static binaries built with recent binutils Date: Wed, 18 Jul 2018 20:14:38 +0200 Message-ID: <20180718181438.nl4e333zkzw36rzl@reiner-h.de> References: <20180718163940.gnx6jkia4i5qdjua@reiner-h.de> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="o7vabtsr5a2kio2k" X-Trace: blaine.gmane.org 1531937572 844 195.159.176.226 (18 Jul 2018 18:12:52 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 18 Jul 2018 18:12:52 +0000 (UTC) User-Agent: NeoMutt/20170113 (1.7.2) To: musl@lists.openwall.com Original-X-From: musl-return-13074-gllmg-musl=m.gmane.org@lists.openwall.com Wed Jul 18 20:12:48 2018 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.84_2) (envelope-from ) id 1ffqwR-00006A-9z for gllmg-musl@m.gmane.org; Wed, 18 Jul 2018 20:12:47 +0200 Original-Received: (qmail 3623 invoked by uid 550); 18 Jul 2018 18:14:54 -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 3590 invoked from network); 18 Jul 2018 18:14:54 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=reiner-h.de; s=mail; t=1531937679; bh=1famETKKCy7qaLgIQQn39ugw0IuGxiK8J/is55vVbiY=; h=Date:From:To:Subject:References:In-Reply-To:From; b=k5GGG1duXdOxHfFQS3tdhXjaRA6nP1Fpq+5KzD30+9jzv6Ya3zM7ZLUWH4rW1kei6 +mZZTWtNS22J2M8TZ40x8FTgpTr1t5V4ZGKP6g4uVRHvNI8wvc3ktFb2k7lztziIeT 1Wpb6FzvSioRSeu5cIrOiPrr9XmUINORjH/281cA= Content-Disposition: inline In-Reply-To: <20180718163940.gnx6jkia4i5qdjua@reiner-h.de> Xref: news.gmane.org gmane.linux.lib.musl.general:13058 Archived-At: --o7vabtsr5a2kio2k Content-Type: multipart/mixed; boundary="ep5q2cotsw37yqy2" Content-Disposition: inline --ep5q2cotsw37yqy2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline > Can you attach a readelf -a of the binary that's crashing? The output is attached. --ep5q2cotsw37yqy2 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="readelf.txt" Content-Transfer-Encoding: quoted-printable ELF Header: Magic: 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00=20 Class: ELF64 Data: 2's complement, little endian Version: 1 (current) OS/ABI: UNIX - System V ABI Version: 0 Type: EXEC (Executable file) Machine: Advanced Micro Devices X86-64 Version: 0x1 Entry point address: 0x40102d Start of program headers: 64 (bytes into file) Start of section headers: 28880 (bytes into file) Flags: 0x0 Size of this header: 64 (bytes) Size of program headers: 56 (bytes) Number of program headers: 5 Size of section headers: 64 (bytes) Number of section headers: 23 Section header string table index: 22 Section Headers: [Nr] Name Type Address Offset Size EntSize Flags Link Info Align [ 0] NULL 0000000000000000 00000000 0000000000000000 0000000000000000 0 0 0 [ 1] .init PROGBITS 0000000000401000 00001000 0000000000000003 0000000000000000 AX 0 0 1 [ 2] .text PROGBITS 0000000000401010 00001010 0000000000000719 0000000000000000 AX 0 0 16 [ 3] .fini PROGBITS 0000000000401729 00001729 0000000000000003 0000000000000000 AX 0 0 1 [ 4] .rodata PROGBITS 0000000000402000 00002000 000000000000000a 0000000000000001 AMS 0 0 1 [ 5] .eh_frame PROGBITS 0000000000402010 00002010 000000000000003c 0000000000000000 A 0 0 8 [ 6] .init_array INIT_ARRAY 0000000000403ff0 00002ff0 0000000000000008 0000000000000008 WA 0 0 8 [ 7] .fini_array FINI_ARRAY 0000000000403ff8 00002ff8 0000000000000008 0000000000000008 WA 0 0 8 [ 8] .data PROGBITS 0000000000404000 00003000 0000000000000008 0000000000000000 WA 0 0 8 [ 9] .bss NOBITS 0000000000404020 00003008 0000000000000278 0000000000000000 WA 0 0 32 [10] .comment PROGBITS 0000000000000000 00003008 000000000000001d 0000000000000001 MS 0 0 1 [11] .debug_aranges PROGBITS 0000000000000000 00003030 00000000000000e0 0000000000000000 0 0 16 [12] .debug_info PROGBITS 0000000000000000 00003110 0000000000000159 0000000000000000 0 0 1 [13] .debug_abbrev PROGBITS 0000000000000000 00003269 00000000000000f1 0000000000000000 0 0 1 [14] .debug_line PROGBITS 0000000000000000 0000335a 0000000000000126 0000000000000000 0 0 1 [15] .debug_frame PROGBITS 0000000000000000 00003480 0000000000000038 0000000000000000 0 0 8 [16] .debug_str PROGBITS 0000000000000000 000034b8 000000000000272a 0000000000000001 MS 0 0 1 [17] .debug_loc PROGBITS 0000000000000000 00005be2 00000000000000d6 0000000000000000 0 0 1 [18] .debug_ranges PROGBITS 0000000000000000 00005cc0 00000000000000a0 0000000000000000 0 0 16 [19] .debug_macro PROGBITS 0000000000000000 00005d60 00000000000007fb 0000000000000000 0 0 1 [20] .symtab SYMTAB 0000000000000000 00006560 00000000000007e0 0000000000000018 21 48 8 [21] .strtab STRTAB 0000000000000000 00006d40 00000000000002b2 0000000000000000 0 0 1 [22] .shstrtab STRTAB 0000000000000000 00006ff2 00000000000000de 0000000000000000 0 0 1 Key to Flags: W (write), A (alloc), X (execute), M (merge), S (strings), I (info), L (link order), O (extra OS processing required), G (group), T (TLS), C (compressed), x (unknown), o (OS specific), E (exclude), l (large), p (processor specific) There are no section groups in this file. Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flags Align LOAD 0x0000000000001000 0x0000000000401000 0x0000000000401000 0x000000000000072c 0x000000000000072c R E 0x1000 LOAD 0x0000000000002000 0x0000000000402000 0x0000000000402000 0x000000000000004c 0x000000000000004c R 0x1000 LOAD 0x0000000000002ff0 0x0000000000403ff0 0x0000000000403ff0 0x0000000000000018 0x00000000000002a8 RW 0x1000 GNU_STACK 0x0000000000000000 0x0000000000000000 0x0000000000000000 0x0000000000000000 0x0000000000000000 RW 0x10 GNU_RELRO 0x0000000000002ff0 0x0000000000403ff0 0x0000000000403ff0 0x0000000000000010 0x0000000000000010 R 0x1 Section to Segment mapping: Segment Sections... 00 .init .text .fini=20 01 .rodata .eh_frame=20 02 .init_array .fini_array .data .bss=20 03 =20 04 .init_array .fini_array=20 There is no dynamic section in this file. There are no relocations in this file. The decoding of unwind sections for machine type Advanced Micro Devices X86= -64 is not currently supported. Symbol table '.symtab' contains 84 entries: Num: Value Size Type Bind Vis Ndx Name 0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND=20 1: 0000000000401000 0 SECTION LOCAL DEFAULT 1=20 2: 0000000000401010 0 SECTION LOCAL DEFAULT 2=20 3: 0000000000401729 0 SECTION LOCAL DEFAULT 3=20 4: 0000000000402000 0 SECTION LOCAL DEFAULT 4=20 5: 0000000000402010 0 SECTION LOCAL DEFAULT 5=20 6: 0000000000403ff0 0 SECTION LOCAL DEFAULT 6=20 7: 0000000000403ff8 0 SECTION LOCAL DEFAULT 7=20 8: 0000000000404000 0 SECTION LOCAL DEFAULT 8=20 9: 0000000000404020 0 SECTION LOCAL DEFAULT 9=20 10: 0000000000000000 0 SECTION LOCAL DEFAULT 10=20 11: 0000000000000000 0 SECTION LOCAL DEFAULT 11=20 12: 0000000000000000 0 SECTION LOCAL DEFAULT 12=20 13: 0000000000000000 0 SECTION LOCAL DEFAULT 13=20 14: 0000000000000000 0 SECTION LOCAL DEFAULT 14=20 15: 0000000000000000 0 SECTION LOCAL DEFAULT 15=20 16: 0000000000000000 0 SECTION LOCAL DEFAULT 16=20 17: 0000000000000000 0 SECTION LOCAL DEFAULT 17=20 18: 0000000000000000 0 SECTION LOCAL DEFAULT 18=20 19: 0000000000000000 0 SECTION LOCAL DEFAULT 19=20 20: 0000000000000000 0 FILE LOCAL DEFAULT ABS exit.lo 21: 0000000000401410 2 FUNC LOCAL DEFAULT 2 dummy 22: 0000000000401420 58 FUNC LOCAL DEFAULT 2 libc_exit_fini 23: 0000000000000000 0 FILE LOCAL DEFAULT ABS crt1.c 24: 0000000000000000 0 FILE LOCAL DEFAULT ABS crtstuff.c 25: 0000000000401080 0 FUNC LOCAL DEFAULT 2 deregister_tm_cl= ones 26: 00000000004010b0 0 FUNC LOCAL DEFAULT 2 register_tm_clon= es 27: 00000000004010f0 0 FUNC LOCAL DEFAULT 2 __do_global_dtor= s_aux 28: 0000000000404020 1 OBJECT LOCAL DEFAULT 9 completed.7090 29: 0000000000403ff8 0 OBJECT LOCAL DEFAULT 7 __do_global_dtor= s_aux_fin 30: 0000000000401120 0 FUNC LOCAL DEFAULT 2 frame_dummy 31: 0000000000403ff0 0 OBJECT LOCAL DEFAULT 6 __frame_dummy_in= it_array_ 32: 0000000000000000 0 FILE LOCAL DEFAULT ABS test.c 33: 0000000000000000 0 FILE LOCAL DEFAULT ABS __libc_start_mai= n.lo 34: 0000000000401140 2 FUNC LOCAL DEFAULT 2 dummy 35: 0000000000401150 2 FUNC LOCAL DEFAULT 2 dummy1 36: 0000000000401390 50 FUNC LOCAL DEFAULT 2 libc_start_init 37: 0000000000000000 0 FILE LOCAL DEFAULT ABS __init_tls.lo 38: 0000000000401550 378 FUNC LOCAL DEFAULT 2 static_init_tls 39: 0000000000404040 48 OBJECT LOCAL DEFAULT 9 main_tls 40: 0000000000404080 376 OBJECT LOCAL DEFAULT 9 builtin_tls 41: 0000000000000000 0 FILE LOCAL DEFAULT ABS crtstuff.c 42: 0000000000402048 0 OBJECT LOCAL DEFAULT 5 __FRAME_END__ 43: 0000000000000000 0 FILE LOCAL DEFAULT ABS=20 44: 0000000000404000 0 NOTYPE LOCAL DEFAULT 7 __fini_array_end 45: 0000000000403ff8 0 NOTYPE LOCAL DEFAULT 7 __fini_array_sta= rt 46: 0000000000403ff8 0 NOTYPE LOCAL DEFAULT 6 __init_array_end 47: 0000000000403ff0 0 NOTYPE LOCAL DEFAULT 6 __init_array_sta= rt 48: 0000000000401160 545 FUNC GLOBAL DEFAULT 2 __init_libc 49: 0000000000404200 8 OBJECT GLOBAL HIDDEN 9 __hwcap 50: 00000000004016e7 0 FUNC GLOBAL DEFAULT 2 memcpy 51: 0000000000404008 0 OBJECT GLOBAL HIDDEN 8 __TMC_END__ 52: 0000000000404220 112 OBJECT GLOBAL HIDDEN 9 __libc 53: 0000000000404000 0 OBJECT GLOBAL HIDDEN 8 __dso_handle 54: 0000000000401719 0 FUNC GLOBAL DEFAULT 2 __set_thread_area 55: 00000000004014c0 138 FUNC GLOBAL DEFAULT 2 __copy_tls 56: 0000000000404038 8 OBJECT WEAK DEFAULT 9 _environ 57: 0000000000404038 8 OBJECT GLOBAL DEFAULT 9 __environ 58: 00000000004016d0 23 FUNC GLOBAL DEFAULT 2 _Exit 59: 0000000000401550 378 FUNC WEAK DEFAULT 2 __init_tls 60: 0000000000401000 0 NOTYPE GLOBAL DEFAULT 1 _init 61: 0000000000401410 2 FUNC WEAK DEFAULT 2 __funcs_on_exit 62: 00000000004016e7 0 NOTYPE GLOBAL HIDDEN 2 __memcpy_fwd 63: 0000000000404038 8 OBJECT WEAK DEFAULT 9 environ 64: 0000000000404038 8 OBJECT WEAK DEFAULT 9 ___environ 65: 0000000000404030 8 OBJECT GLOBAL DEFAULT 9 __progname 66: 000000000040102d 0 NOTYPE GLOBAL DEFAULT 2 _start 67: 0000000000401050 40 FUNC GLOBAL DEFAULT 2 _start_c 68: 0000000000404030 8 OBJECT WEAK DEFAULT 9 program_invocati= on_short_ 69: 0000000000401390 50 FUNC WEAK DEFAULT 2 __libc_start_init 70: 0000000000401460 95 FUNC GLOBAL DEFAULT 2 __init_tp 71: 0000000000401150 2 FUNC WEAK DEFAULT 2 __init_ssp 72: 0000000000404008 0 NOTYPE GLOBAL DEFAULT 9 __bss_start 73: 0000000000401127 11 FUNC GLOBAL DEFAULT 2 main 74: 0000000000401410 2 FUNC WEAK DEFAULT 2 __stdio_exit 75: 0000000000401729 0 NOTYPE GLOBAL DEFAULT 3 _fini 76: 0000000000401420 58 FUNC WEAK DEFAULT 2 __libc_exit_fini 77: 0000000000404008 0 NOTYPE GLOBAL DEFAULT 8 _edata 78: 0000000000404298 0 NOTYPE GLOBAL DEFAULT 9 _end 79: 0000000000401010 29 FUNC GLOBAL DEFAULT 2 exit 80: 00000000004013d0 61 FUNC GLOBAL DEFAULT 2 __libc_start_main 81: 0000000000404028 8 OBJECT WEAK DEFAULT 9 program_invocati= on_name 82: 0000000000404290 8 OBJECT GLOBAL HIDDEN 9 __sysinfo 83: 0000000000404028 8 OBJECT GLOBAL DEFAULT 9 __progname_full No version information found in this file. --ep5q2cotsw37yqy2-- --o7vabtsr5a2kio2k Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEE2Pb6feok2Q1urHM7zPBJKNsO6qcFAltPg4oACgkQzPBJKNsO 6qc4Nw//QRL0qnjl060FV7Gqa7hyV4J7ccsntGclSDMt0QLa/puov344dpB9eYHq rbVlrUb048uo3aTK5SbhV/dy44X6nWmsqHBSFqMgpn1J+zVkGKajtPx87gR4YL45 y0qXJqNM8lhaP99I95Td3wDn+dyTS/jJTz7NBcI0u0lWSwkq2/yT9WNBz1XJaPSq Ig+A0zVMWsa8B2/4b8YMl/cx+oxHJzbh+quUbdiRvSuQoQ/6ISvdN+awjM2BgOD+ tY2wZyWHca5yRXngQVk3r3zFXKPq18VWiS4gi5mQ/PcyeBrcofVV2iuZ5X1Nxjw2 KNYvhKTlyjTxQq3YJiIygga4YuWz+N/4VHRJQBpHZd79ZWMY4dFPkXMuHxh1hpy2 dPdU/ABh008DqUEfqupHBfc/Gf5VjRpnbG0qFKXbiCkLguL0R9Q0Qz2Gcjks3s+O E/y/Bz3jBOypP0cJPdfy6crbEXOMZB9wWWV9OZmWkuzrBrDLlj1hcnoFzgaBXDu/ znxLLmnVHu6cJ84C3Qxq9iybtYZ0RS+wth8tQiqhBg6mTS82Nh0zqBDSO11Aomky fdM2o/9tDFvAlbZN/A+h0BkL0rM6nkNGFoLKYmntaqQyKuaaxieFr2Uv2DyJhS9g J9yw+nEi5z8QXcp3qNzpHeYxpPEg5NHaQxCcdvKS8mugyUGxZBc= =ZWet -----END PGP SIGNATURE----- --o7vabtsr5a2kio2k--