ojhawkins
ojhawkins

Reputation: 3278

Decompile .pdb file C# (Program database)

I want to decompile .pdb files so I can see where references are pointing to. The projects are being built from a build server. I also want to explore the possibility of using these to index a codebase.

I cannot seem to find any tools to decompile and view the contents.

I have found this stack post Help me to read .pdb file but the first recommended example is missing (Producing an XML would be ideal) && the second will not build on my machine.

I have also tried using reflector to open the file but does not work.

Can anyone provide insight into how I can deompile a .pdb file?

Upvotes: 3

Views: 10539

Answers (1)

Mikhail Shcherbakov
Mikhail Shcherbakov

Reputation: 1826

You can try using Mono.Cecil project. It's open source libraries for decompiling .NET assemblies to IL code. It also allow to work with .pdb files of .NET projects. Mono.Cecil doesn't use reflection, it reads assembly as byte stream.

For decompiling assembly to C# code, you can look to the ILSpy project. It's also open source project and it uses the Mono.Cecil library inside.

Upvotes: 4

Related Questions