Re: [libopcodes] Decoder crash and incorrect results

2016-02-19 Thread Nick Clifton
Hi Nathan,

> Redhat Enterprise Linux 6.

RHEL 6 contains a very old version of the binutils (2.20).  We are now on
release 2.26...

> I have found that the library will segfault given certain inputs 
> to print_insn_i386. Here is the code I am using to decode:

Does the library also crash if you place these inputs into an object file,
assemble them, and then try to run "objdump -d" on them ?

If you cab reproduce these seg-faults using the current binutils sources, 
please file a bug report here, including a way to reproduce the problem if
at all possible:

  https://sourceware.org/bugzilla/

Cheers
  Nick

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19630] crash in bin/as null pointer dereference

2016-02-19 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=19630

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Nick Clifton :

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=3be64886b5cd7e877d8783a53b81e2c6f7d01307

commit 3be64886b5cd7e877d8783a53b81e2c6f7d01307
Author: Nick Clifton 
Date:   Fri Feb 19 13:19:57 2016 +

Prevent seg-fault in gas reading a binary input file.

PR 19630
* read.c (read_a_source_file): Check for assemble_one returning
with input_line_pointer set to NULL.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19630] crash in bin/as null pointer dereference

2016-02-19 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19630

Nick Clifton  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||nickc at redhat dot com
 Resolution|--- |FIXED

--- Comment #2 from Nick Clifton  ---
Hi Aladdin,

  Thanks for reporting this problem.

  GAS is not really expected to work when given a binary input file, but it
should not generate a seg-fault either.  So I have checked in a small patch to
prevent that happening.  For this particular input file anyway.

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19628] null pointer dereference when linking crafted file

2016-02-19 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=19628

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Nick Clifton :

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=737684142b3f7dfa6d440c8363750911a8ac20ce

commit 737684142b3f7dfa6d440c8363750911a8ac20ce
Author: Nick Clifton 
Date:   Fri Feb 19 15:20:30 2016 +

Fix a seg-fault in the linker when it encounters a corrupt binary
containing a reloc with no associated symbol.

PR ld/19628
* reloc.c (bfd_generic_get_relocated_section_contents): Stop
processing if we encounter a reloc without an associated symbol.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19628] null pointer dereference when linking crafted file

2016-02-19 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19628

Nick Clifton  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||nickc at redhat dot com
 Resolution|--- |FIXED

--- Comment #2 from Nick Clifton  ---
Hi Aladdin,

  Thanks for reporting this problem.

  I have checked in a patch which will prevent the null pointer dereference and
instead issue an error message.

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19629] crash in ld.bfd - possible null pointer dereference

2016-02-19 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=19629

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Nick Clifton :

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=e517df3dbf7556ddb389228d713a804594ee3c1f

commit e517df3dbf7556ddb389228d713a804594ee3c1f
Author: Nick Clifton 
Date:   Fri Feb 19 15:55:06 2016 +

Prevent a seg-fault in the linker when accessing a specially crafted,
corrupt, aout binary.

PR ld/19629
* aoutx.h (aout_link_add_symbols): Check for out of range string
table offsets.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19629] crash in ld.bfd - possible null pointer dereference

2016-02-19 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19629

Nick Clifton  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||nickc at redhat dot com
 Resolution|--- |FIXED

--- Comment #2 from Nick Clifton  ---
Hi Alanddin,

  Thanks for reporting this problem.

  I have checked in a patch which adds checks to make sure that the linker does
not attempt to access beyond the end of the aout format's string table.

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19629] crash in ld.bfd - possible null pointer dereference

2016-02-19 Thread alaa.mubaied at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19629

--- Comment #3 from Aladdin Mubaied  ---
Thanks, do you think CVE is required here to warn users about this bug?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19630] crash in bin/as null pointer dereference

2016-02-19 Thread alaa.mubaied at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19630

--- Comment #3 from Aladdin Mubaied  ---
Thanks, do you think CVE is required here to warn users about this bug?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19628] null pointer dereference when linking crafted file

2016-02-19 Thread alaa.mubaied at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=19628

--- Comment #3 from Aladdin Mubaied  ---
Thanks, do you think CVE is required here to warn users about this bug?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/19685] New: vcmppd, vcmpps, vcmpsd, vcmpss disassembly is wrong

2016-02-19 Thread jdetter at wisc dot edu
https://sourceware.org/bugzilla/show_bug.cgi?id=19685

Bug ID: 19685
   Summary: vcmppd, vcmpps, vcmpsd, vcmpss disassembly is wrong
   Product: binutils
   Version: 2.26
Status: NEW
  Severity: normal
  Priority: P2
 Component: binutils
  Assignee: unassigned at sourceware dot org
  Reporter: jdetter at wisc dot edu
  Target Milestone: ---

I compiled the following lines using GNU as:

  vcmppd $0x0, %xmm0, %xmm0, %xmm0
  vcmpps $0x0, %xmm0, %xmm0, %xmm0
  vcmpsd $0x0, %xmm0, %xmm0, %xmm0
  vcmpss $0x0, %xmm0, %xmm0, %xmm0

And the disassembly doesn't match. The mnemonics are wrong and objdump
interprets the instruction with 3 operands instead of 4:

  40049a:   c5 f9 c2 c0 00  vcmpeqpd %xmm0,%xmm0,%xmm0
  40049f:   c5 f8 c2 c0 00  vcmpeqps %xmm0,%xmm0,%xmm0
  4004a4:   c5 fb c2 c0 00  vcmpeqsd %xmm0,%xmm0,%xmm0
  4004a9:   c5 fa c2 c0 00  vcmpeqss %xmm0,%xmm0,%xmm0

Output from version:

[detter@galapagos-03] (31)$ objdump --version
GNU objdump (GNU Binutils) 2.26.20160125
Copyright (C) 2015 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils