AsmResolver icon indicating copy to clipboard operation
AsmResolver copied to clipboard

Support for Portable PDB streams and tables in AsmResolver.PE

Open Washi1337 opened this issue 2 years ago • 0 comments

Problem Description

Newer .NET file formats define extensions to the metadata model that store symbols. This includes the #Pdb stream, as well as a couple of extra metadata table types. To lay a foundation for rich support for Portable PDB files, we would need to be able to read and write these types of streams and metadata tables.

Proposal

Add support for reading standalone Portable PDB files, as well as PE files containing embedded Portable PDB symbols.

To do this, we will need the following:

  • Add PdbStream representing the #Pdb stream, and update DefaultMetadataStreamReader appropriately.
  • Add all relevant metadata table indice to TableIndex.
  • Add all relevant metadata table row structures in AsmResolver.PE.DotNet.Metadata.Tables.Rows.
  • Update SerializedTablesStream to include all new tables.

Alternatives

No response

Additional Context

Official specification: https://github.com/dotnet/runtime/blob/main/docs/design/specs/PortablePdb-Metadata.md Related #297

Washi1337 avatar May 26 '22 14:05 Washi1337