Bug 66670 - strings dumps core
strings dumps core
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: binutils (Show other bugs)
7.3
i686 Linux
medium Severity high
: ---
: ---
Assigned To: Jakub Jelinek
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-06-13 09:51 EDT by Toni Willberg
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-06-18 05:13:20 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Toni Willberg 2002-06-13 09:51:40 EDT
Description of problem:
I have couple binary files that causes strings to dump core when running
"strings mybinary".

Doing "strings -a mybinary" seems to work.




How reproducible:
Always

Steps to Reproduce:
strings mybinary


Actual Results:  Segmentation fault (core dumped)


Expected Results:  /lib/ld-linux.so.2
qoH
q^
__gmon_start__
(and so on...)


Additional info:

broken version:  binutils-2.11.93.0.2-11
works fine in:   binutils-2.11.90.0.8-12 

Here's gdb output of the problem.

"env.exe" is the binary I'm testing. Don't mind the funny name of it. ;)
env.exe: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically
linked (uses shared libs), stripped

gdb strings
GNU gdb Red Hat Linux (5.1.90CVS-5)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux"...(no debugging symbols found)...
(gdb) run env.exe
Starting program: /usr/bin/strings env.exe
(no debugging symbols found)...(no debugging symbols found)...(no debugging
symbols found)...(no debugging symbols found)...
Program received signal SIGSEGV, Segmentation fault.
0x4005c888 in bfd_section_from_shdr () from /usr/lib/libbfd-2.11.93.0.2.so
(gdb) bt
#0  0x4005c888 in bfd_section_from_shdr () from /usr/lib/libbfd-2.11.93.0.2.so
#1  0x4004da07 in bfd_elf32_object_p () from /usr/lib/libbfd-2.11.93.0.2.so
#2  0x4003a1b7 in bfd_check_format_matches () from /usr/lib/libbfd-2.11.93.0.2.so
#3  0x40039ff5 in bfd_check_format () from /usr/lib/libbfd-2.11.93.0.2.so
#4  0x08049360 in strcpy ()
#5  0x080493da in strcpy ()
#6  0x08049245 in strcpy ()
#7  0x42017499 in __libc_start_main () from /lib/i686/libc.so.6
(gdb)
Comment 1 Olivier Baudron 2002-06-16 20:29:44 EDT
Can you attach your file 'env.exe'?
Comment 2 Toni Willberg 2002-06-17 01:33:08 EDT
I can't attach it to public Bugzilla, but I can give it to someone directly for
testing.

Comment 3 Olivier Baudron 2002-06-17 16:12:36 EDT
Maybe, you can try to find a minimal sub-part of your exe file that makes
strings segfaults. Otherwise, for me: no testcase, no debug.
Comment 4 Toni Willberg 2002-06-18 02:34:04 EDT
Hi.

I have sent an URL of the binary to <jakub@redhat.com>.

He may decide if it is necessary to give it to others, but only with my permission.

Thanks!

ps. Try also gdb, it crashes also (no bugreport filed yet)

Comment 5 Jakub Jelinek 2002-06-18 05:13:15 EDT
http://sources.redhat.com/ml/binutils/2002-06/msg00500.html

Note that perl2exe should probably be fixed to create section header table too.
Comment 6 Jakub Jelinek 2002-08-16 04:32:42 EDT
Should be fixed in binutils-2.13.90.0.2-1.

Note You need to log in before you can comment on or make changes to this bug.