[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug binutils/30901] New: objdump: SEGV at bfd/elf.c:2267 in _bfd_elf_ge
From: |
yan.cs10 at nycu dot edu.tw |
Subject: |
[Bug binutils/30901] New: objdump: SEGV at bfd/elf.c:2267 in _bfd_elf_get_dynamic_symbols |
Date: |
Tue, 26 Sep 2023 01:50:48 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=30901
Bug ID: 30901
Summary: objdump: SEGV at bfd/elf.c:2267 in
_bfd_elf_get_dynamic_symbols
Product: binutils
Version: 2.42 (HEAD)
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: binutils
Assignee: unassigned at sourceware dot org
Reporter: yan.cs10 at nycu dot edu.tw
Target Milestone: ---
Created attachment 15134
--> https://sourceware.org/bugzilla/attachment.cgi?id=15134&action=edit
this poc with -T argument can crash objdump in the latest version
Summary:
A crash caused when using objdump
AddressSanitizer reported it as SEGV
git commit, OS, Compiler and processor
git commit: be8e83130
gcc (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0
g++ (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0
Ubuntu 20.04.4 LTS
AMD Ryzen 5 3600X 6-Core Processor
Steps to reproduce:
$ cd binutils-gdb
$ export CFLAGS='-fsanitize=address -fsanitize-recover=address -g3'
$ export CXXFLAGS='-fsanitize=address -fsanitize-recover=address -g3'
$ make
$ binutils/objdump -T ./poc_55_hav
AddressSanitizer report:
$ /home/pt/sytseng/binutils-gdb-asan/binutils/objdump -T ./pocs/poc_55_hav
id:000050,sig:11,seed:000000,src:012011,op:havoc,rep:32
AddressSanitizer:DEADLYSIGNAL
=================================================================
==1073912==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc
0x55b97a4b0808 bp 0x7ffdb7ac8bb0 sp 0x7ffdb7ac8900 T0)
==1073912==The signal is caused by a READ memory access.
==1073912==Hint: address points to the zero page.
#0 0x55b97a4b0807 in _bfd_elf_get_dynamic_symbols
/home/pt/sytseng/binutils-gdb-asan/bfd/elf.c:2267
#1 0x55b97a4967a5 in bfd_elf64_object_p
/home/pt/sytseng/binutils-gdb-asan/bfd/elfcode.h:861
#2 0x55b97a4221fe in bfd_check_format_matches
/home/pt/sytseng/binutils-gdb-asan/bfd/format.c:431
#3 0x55b97a2e38b5 in display_object_bfd objdump.c:5748
#4 0x55b97a2e3c05 in display_any_bfd objdump.c:5837
#5 0x55b97a2e3c7f in display_file objdump.c:5858
#6 0x55b97a2e5633 in main objdump.c:6269
#7 0x7f39b2247082 in __libc_start_main ../csu/libc-start.c:308
#8 0x55b97a2c937d in _start
(/home/pt/sytseng/binutils-gdb-asan/binutils/objdump+0x13737d)
AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV
/home/pt/sytseng/binutils-gdb-asan/bfd/elf.c:2267 in
_bfd_elf_get_dynamic_symbols
==1073912==ABORTING
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug binutils/30901] New: objdump: SEGV at bfd/elf.c:2267 in _bfd_elf_get_dynamic_symbols,
yan.cs10 at nycu dot edu.tw <=