coff-go32-exe segv in _bfd_pe_print_private_bfd_data_common

Project / Subsystem

binutils / binutils

Date

2026-10-04

Proposer

Alan Modra <amodra@gmail.com>

Source type

public_inbox

Consensus

Proposed

Sentiment

—/10

All attributes

project
binutils
subsystem
binutils
patch_id
—
discussion_id
asG27CdAaBmPF3h2@squeak.grove.modra.org
source_type
public_inbox
title
coff-go32-exe segv in _bfd_pe_print_private_bfd_data_common
headline
coff-go32-exe segv in _bfd_pe_print_private_bfd_data_common
tldr
Fixes a segfault in binutils when handling coff-go32-exe files due to incorrect offset interpretation.
proposer
Alan Modra <amodra@gmail.com>
consensus
Proposed
outcome
proposed
sentiment_score
—
technical_tradeoffs
[]
series_id
—
series_role
standalone
series_parts
[]
tags
  • • binutils
  • • bugfix
  • • coff
  • • PE
  • • segfault
bugzilla_url
—
date
2026-10-04T00:00:00.000Z

coff-go32-exe segv in _bfd_pe_print_private_bfd_data_common

A segfault in binutils’ _bfd_pe_print_private_bfd_data_common function, triggered by oss-fuzz, is addressed by this patch. The issue arises from a recent change that repurposed the bfd.offset field for coff-go32-exe files, causing confusion in format checking. This change introduces bfd_preserve_save and bfd_preserve_restore to correctly handle the origin field, ensuring that files are accurately recognized as coff-go32-exe and not misidentified as other PE variants.