Are powersave3DS save files encrypted to specific cartdrige?

Discussion in '3DS - Homebrew Development and Emulators' started by Phantom64, Jun 29, 2016.

  1. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    I mean, i have a reaaally old backup file from Pokémon X, but i don't longer own my old cartdrige. When i use my friends cartdrige to decrypt my old file, it shows as a corrupted save file. Is this because every savefile is encrypted with a specific key (or something else) linked with a specific cartdrige?

    I mean, do i need my FIRST original cartdrige?

    bumpity bump
     
  2. Drakia

    Drakia GBAtemp Maniac

    Member
    1,494
    1,746
    Mar 15, 2008
    Canada
    Bumping your own topic, especially within a few hours of posting, is totally against the rules.
     
  3. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    I know but I need an answer
     
  4. Drakia

    Drakia GBAtemp Maniac

    Member
    1,494
    1,746
    Mar 15, 2008
    Canada
    Saying you know you're breaking the rules isn't helping your case here...
     
    gnmmarechal likes this.
  5. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    Oh
     
  6. Nintendo Fanboy

    Nintendo Fanboy GBAtemp Maniac

    Member
    1,014
    388
    Mar 6, 2015
    United States
    In Los Santos, GTA: San Andreas.
    He just wants an answer.
    @Phantom64 Nope, you gotta have your original cart. :/
     
    Phantom64 likes this.
  7. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    Thank you so much, I didn't know that saves were cartridge encrypted
     
  8. Queno138

    Queno138 Ravens

    Member
    2,411
    782
    Sep 18, 2010
    Senegal
    Luigi's Dark Mansion
    Yes, encrypted to your own cartridge, however there are a few ways around decrypting it.

    Powersaves when it backs up your save, it also backs up the header, which is used to encrypt your save.

    So by getting a rom of Pokemon X,
    putting the header (obtained from the powersaves save) in the rom
    (same procedure to allow online play for roms),
    and injecting the save (minus all of powersave header junk) into the rom
    (cart2 type of save restore, goes into the rom),
    on Gateway3DS or sky3ds, you'll basically be playing a clone of your cartridge.
    (hence your save will be able to be decrypted)

    edit
    Also, read this:
    https://projectpokemon.org/forums/showthread.php?48767-Question-about-saves-and-Alpha-Sapphire
     
    Last edited by Queno138, Jun 30, 2016 - Reason: edited for clarity.
  9. Nintendo Fanboy

    Nintendo Fanboy GBAtemp Maniac

    Member
    1,014
    388
    Mar 6, 2015
    United States
    In Los Santos, GTA: San Andreas.
    No problem dude. I used to love action replays, but it turns out that their products are shit.
    They want your money, and they provide cheats.
    I wish we had a real cheat device for 3DS where we can ADD cheats. Like on DS, but it's no longer needed.
    We have NTR.
     
  10. Ericjwg

    Ericjwg Good

    Member
    2,827
    681
    Jul 2, 2015
    Canada
    you can decrypt the old PS save backup and use HB tools to import it back to new cartridge
     
  11. Nintendo Fanboy

    Nintendo Fanboy GBAtemp Maniac

    Member
    1,014
    388
    Mar 6, 2015
    United States
    In Los Santos, GTA: San Andreas.
    You can!?
     
  12. Queno138

    Queno138 Ravens

    Member
    2,411
    782
    Sep 18, 2010
    Senegal
    Luigi's Dark Mansion
    isn't that decryption only possible if the original cartridge is still around?

    edit:

    for OP:
    If you send your save to an user with gateway3DS,
    they may be able to help you
     
    Last edited by Queno138, Jun 30, 2016
    Phantom64 likes this.
  13. Ricken

    Ricken Crawling from Hell, Falling from Grace

    Member
    2,169
    2,297
    Jan 19, 2016
    United States
    Shibuya, The small one from Vegas
    Not all games are encrypted by cart... The most notable one that isn't is OOT

    But you're working with a game with per cart encryption (Pokemon X) so normally you would need the original cart...
    But the Gen 6 Pokemon games are exceptions. I am highly uneducated on how, but there's a way to decrypt Gen 6 Pokemon saves to be loaded in PKHeX. Instructions are on Project Pokemon iirc. If you were to decrypt the save and load it in PKHeX, you could export it as main, which would let you use the save after patching the secure value

    EDIT; I should mention that the saves CAN NOT be re-encrypted
     
    Phantom64 likes this.
  14. Queno138

    Queno138 Ravens

    Member
    2,411
    782
    Sep 18, 2010
    Senegal
    Luigi's Dark Mansion
    Talking strictly about XYORAS here,

    Okay, to decrypt Powersave save for Pokemon, you will need your original cart to decrypt, in order to obtain save1keystream.bin,
    so unless you already have that, you won't be able to decrypt a Powersaves save without it.
    (to get the keystream, need original cart, do a few things such as restart save and set a code to it etc)

    While it is normally impossible to decrypt a save without the cart,
    Powersaves save actually backup the private header of the cart.
    (and btw, Powersaves doesn't encrypt the save.
    The save is encrypted by the 3DS using the header, and powersaves simply dump it raw + header)

    Meaning if you:
    1. Inject the private header into a Rom (http://gbatemp.net/threads/tutorial...o-cia-plus-extracting-private-headers.432600/),
    2. Inject the encrypted save (minus Powersaves' own header from the save) into the ROM
    3. Place rom on red cart on Gateway3DS

    It should run, as you are basically emulating the cartridge.

    edit:
    I'm not entirely correct, it seems.
    Powersaves saves don't dump your header (they dump something else while writing a header into your save)

    So your only issue, is finding your private header.
     
    Last edited by Queno138, Jun 30, 2016
    Phantom64, Ericjwg and Ricken like this.
  15. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    Omg. Really, thank you so much guys, you helped me A LOT.
    Now I have just to get my old cartridge (it's not a problem to do that) and then just reinject the save in it and then extract the save in many possible ways. Thank you for all of your answers! (PS, only .cia here, so no flashcard)
     
    Ricken and Queno138 like this.
  16. Phantom64
    OP

    Phantom64 Banned

    Banned
    581
    460
    Aug 18, 2015
    Saint Kitts and Nevis
    Maybe it will be a problem get my Cartdrige back. Mh. If i get my header (I have it, it is somewhere on the HDD), and i send the savefile with the header to someone that has a gateway or a sky3ds, will i be able to decrypt my save?
     
    Queno138 likes this.