zeroKilo / XEXLoaderWV

Ghidra Loader Module for X360 XEX Files
112 stars 13 forks source link

The loadpdb functionality is somewhat broken #19

Closed guccigang420 closed 1 year ago

guccigang420 commented 1 year ago

The load pdb functionality does not load datatypes or the function names properly for the .xex executable.

zeroKilo commented 1 year ago

thats your word against mine, please dont provide any files or details

zeroKilo commented 1 year ago

ok I will take a look, this can take a while, pls be patient or find me on discord if you wanna chat in the meantime. greetz

guccigang420 commented 1 year ago

Could you post your discord id here?

zeroKilo commented 1 year ago

its under every recent yt vid of mine... wv#9312

zeroKilo commented 1 year ago

about demangling, I found this, maybe it solves the mangled name problem already:

https://github.com/NationalSecurityAgency/ghidra/issues/1103

PDB support for types is coming, but dont expect too much, documentation for both PDBs and Ghidra are very hard to come by

guccigang420 commented 1 year ago

Understandable. Hopefully you manage to make it with the types. It's pretty tricky because you have to represent CPP classes as C-Structs with v-tables

zeroKilo commented 1 year ago

result: https://github.com/zeroKilo/XEXLoaderWV/commit/754cca3daf48c5bdc61cfff88734d660561b10a0

well I dont have more time to spend on this, that commit and current release are as good as it gets:

essentially my code can read pretty much every typerecord from the pdb, but the code to apply/import it into ghidra is as best a hack of mine, it needs serious improvement, starting here: https://github.com/zeroKilo/XEXLoaderWV/blob/master/XEXLoaderWV/src/main/java/xexloaderwv/TPIStream.java#L141

greetz

mirh commented 1 year ago

https://github.com/NationalSecurityAgency/ghidra/pull/1433 maybe?