How can I browse through a game's filesystem to find/extract specific files?

Discussion in 'PS3 - Hacking & Homebrew' started by dj505, Jul 4, 2017.

  1. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    I'm trying to figure out how I can look through a PS3 game's contents and extract certain files for modification; is there any way I can do this?

    Edit: It seems I can browse through some of the game's files (audio and some pictures) but I can't find the files I'm actually looking for... I already know what format they should be in, but I can't find where they're placed
     
    Last edited by dj505, Jul 4, 2017
  2. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
    I need the name of the game and more details if you haven't figured it out yet.
     
  3. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    I think I've figured it out - looks like most of the game's data is in a psarc file. I've never looked at the contents of a PS3 game before (mostly just 3DS) so I had no clue where to start looking, but I think I found it.
     
  4. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
    Alright if you need anymore help just ask me. The thing about packing files and unpacking files for PS3 is that sometimes you don't get all the data when unpacking (most of the time you do), but packing usually crashes the game because the headers and other data is incorrect. So if you need help with that or modifying the files inside the psarc file I would love to try to help. Anyways good luck.
     
  5. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    Thanks! I'm not really trying to modify the file for use in the same game, but using a file of the same format and exporting it into a completely different game on a different coneole (sounds crazy, but I know it's possible). Looks like most of the (thousands of) files are in .farc format, how do I extract those?
     
  6. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
    This is a QuickBMS script made to unpack .farc for Little Big Planet 3, but it should work on other games. One fact about game modding is BMS is pretty bad so if you ever are going to program your own tools don't use BMS. Although in this situation it seems the best option.
     
  7. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    Awesome, thanks for your help! I'm a complete n00b at this, so it's greatly appreciated!
     
    Zero72463 likes this.
  8. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
  9. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    So, I open up the file in a hex editor (cuz there's some stuff I need to change in the header) and it looks encrypted or compressed or something. Is there a certain way I have to decompress/decrypt the file? I've worked with this specific filetype before and it's not supposed to look like that
     
    Last edited by dj505, Jul 5, 2017
  10. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
    If it's encrypted you might as well give up. Check out the quickbms page it will give info for running the script and unpacking the files. Like I said though if the game is ever encrypted its usually hard to unpack the files then repack them. If you want you can add me on Skype and we can talk a bit more about what exactly you want to do.
     
  11. godreborn

    godreborn GBAtemp Psycho!

    Member
    3,789
    694
    Oct 10, 2009
    United States
    a psarc is like a collection of files. there's an app to extract them, but I've forgotten the name of it. psarcs r not encrypted btw.
     
  12. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    I extracted the .psarc, it's the files inside that are encrypted unfortunately
     
  13. godreborn

    godreborn GBAtemp Psycho!

    Member
    3,789
    694
    Oct 10, 2009
    United States
    what files? afaik, the only encrypted files for the ps3 r self/sprx/edat/sdat/and eboot.bin. all other files r either normal, encoded, or compressed with zlib.
     
  14. Zero72463

    Zero72463 GBAtemp Maniac

    Member
    1,296
    650
    Jun 27, 2016
    United States
    I have seen developers encrypt their games files before. Sony doesn't require it, but developers have the option and some do.
     
  15. dj505
    OP

    dj505 Inexperienced Romhacker

    Member
    525
    119
    Oct 4, 2014
    Canada
    Most likely at the arcade
    If that's the case then it could be compressed.
    This is what the file looks like in a hex editor (starting from the beginning of the file):
    Warning: Spoilers inside!
     
  16. godreborn

    godreborn GBAtemp Psycho!

    Member
    3,789
    694
    Oct 10, 2009
    United States
    developers can choose to encrypt game data with the sdk, but I've never seen an encrypted file inside of a psarc file before, but I suppose it's possible. that file above is not compressed with zlib. zlib will start with 78 DA in hex which should kinda look an x and a u in the text field followed by the level of compression for the third byte. that's common for files in the flash at least, so I suspect compressed game files will use the same compression. it's hard to tell from that screenshot, but u can usually tell what kind of file it is by the beginning or the end of the file. image files will likely tell u at the end of the file (i.e. DDS or TRUEVISION - tga) in hex, but I've seen other like gtf (used with the coldboot) tell u at the beginning. there should be a table of contents for the psarc, so the names of files should be correct when extracted. I think psarc is meant to speed up load times btw which is y it's used. the wii u either uses psarc or a similar format to compress game content from what I remember.

    edit: btw, if it were encrypted, it would have a header with the firmware version written to it.