Can One Backup an Imported Seed?

Discussion in '3DS - Homebrew Development and Emulators' started by starburst, Jun 21, 2017.

  1. starburst
    OP

    starburst Member

    Newcomer
    23
    2
    Apr 15, 2017
    United States
    I am currently using Luma 7.1 and B9S on a N3DS XL with 11.0.0-33U firmware.

    During the last week, I have been using CIAngel to create pure CIAs and have a backup of the games, DLCs and updates. When installing these CIAs with FBI, I noticed that some recent titles (like FE Fates or FE Echoes) also require a seed to be playable, and this seed can be downloaded using FBI.
    This was the first time that I noticed this because, on my previous installations, I had installed the games directly with CIAngel or FreeShop (or FBI for CIAs from that ISO site.)

    Is it possible to re-download (or copy) and store those imported seeds, so that I can have a completely offline backup of games, DLCs and updates? Where are these seeds downloaded from, CDN? Are they stored somewhere on the system, or are they deleted after the validation?
     
  2. cearp

    cearp the ticket master

    Member
    7,406
    4,658
    May 26, 2008
    Tuvalu
    you can get them via http from cdn yes, no purchase necessary (strangely)
    as for any computer based tools that automate it... i'm not sure?
    but if not it's very possible :)


    the seeds are stored in the seed.db on the nand, they are not needed for installation of the cia, just the decryption on runtime
     
    Last edited by cearp, Jun 21, 2017
  3. starburst
    OP

    starburst Member

    Newcomer
    23
    2
    Apr 15, 2017
    United States
    I see. Well, hopefully someone will provide more information and point us into the right direction.
    As of now, my CIAngel-downloaded CIAs are useless offline, for they are unplayable without the seeds.

    I know that I could simply use other CIAs as my backup, but I am thinking ahead, when Nintendo finally (and sadly) abandons the 3DS (what will happen in the near future.)
    I like the idea of being able to store content that was downloaded directly from Nintendo servers, as one could attach a checksum to verify the data integrity and others would know that those CIAs are unmodified, direct versions of the game. For this to work, one would also need the corresponding seed (or a way to bypass the validation.)

    By the way, I am now checking your Funk*yCIA tools. That might be what I am looking for.
     
    Last edited by starburst, Jun 22, 2017
  4. pixelmasher

    pixelmasher Gaming Gamer

    Member
    1,597
    651
    Dec 12, 2016
    United States
    Near N3DS
    Why not just download the seeddb.bin from the title key site?
     
    cearp likes this.
  5. Drakia

    Drakia GBAtemp Maniac

    Member
    1,497
    1,749
    Mar 15, 2008
    Canada
    As pixelmasher said, the title key site has a seeddb with all of the titles seeds for titles on the site. The CIAs will also never be "clean" because we generate part of the ticket with junk data (ignored due to signature patching) where it would normally have signatures. My understanding is that currently the available tools generate a slightly different ticket from each other as a kind of watermark.
     
  6. starburst
    OP

    starburst Member

    Newcomer
    23
    2
    Apr 15, 2017
    United States
    Thank you both. I was actually reading about it on https://github.com/ihaveamac/3DS-rom-tools/wiki and realised that by using an already full Seed Database, one would not face this problem.

    One more question, though: If one creates a CIA of an installed title using GodMode9, will it need to be seed-validated (again) when it is installed on a new system?
    Having only one 3DS system makes testing this very time consuming, because if seeds are kept in the database after uninstalling a title, I would need to format the system before giving it a try.


    Thank you for telling me this; I will focus on what is achievable.
    I would still like to download content directly from Nintendo servers and create an offline installable backup. And that would be as clean as it gets. Too bad that the contents will not be verifiable in the future, when the original servers are down.
     
  7. Drakia

    Drakia GBAtemp Maniac

    Member
    1,497
    1,749
    Mar 15, 2008
    Canada
    I believe FBI has a way to remove seeds, though I'm not 100% sure on that. You would still need to install a seed even if you dump the installed title with GM9 though, as the seed is used during runtime, not install time.

    Yeah, there's no "agreed upon" standard for what should be placed in that location. Though I just checked, and FreeShop and CIAngel both use the same ticket header, so they should create matching output data I believe. The parts I could see differing between software (Based on the offsets on this wiki page: https://www.3dbrew.org/wiki/Ticket ) would be:
    Signature (We use D15EA5E0 repeating)
    ECC PublicKey (We use FEEDFACE repeating)
    ConsoleID (We use 0000)
    eShop Account ID (We use 0000)

    There may be other data that can be changed without breaking installation, but those are the dynamic values I see off the top of my head.
     
  8. cearp

    cearp the ticket master

    Member
    7,406
    4,658
    May 26, 2008
    Tuvalu
    the contents of the cia as in the actual application content files will be verifiable, the tmd (title metadata) in the cia has hashes of each content file.
    but yes the actual signature of the ticket - it HAS to be broken, apart from system and preinstalled cias.
    if
    the console id needs to be 000000, if not, the cia simply won't install.
    even if the ticket/cia is 100% legit and its your console!
    a mystery as to why... but yeah i could only get them to install when making the console id 0, thus breaking the signature.
    which means no perfect legit backups. :(
     
    Drakia likes this.
  9. key1340

    key1340 GBAtemp Regular

    Member
    139
    80
    Jul 6, 2015
    United States
    Yes you can download the game and seed for offline install.

    Download the game with FunKeyCIA. And download the seed with eseedgbr.

    Then open the seed with a hex editor and delete the titleid and the zero's before and after the seed so you are left with just the 32 character seed. Save that as titleid.dat with the titleid part being the games titleid.

    You can then install the game and seed with fbi.
     
  10. The Real Jdbye

    The Real Jdbye Always Remember 30/07/08

    Member
    GBAtemp Patron
    The Real Jdbye is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    11,461
    4,776
    Mar 17, 2010
    Norway
    Alola
    I think ConsoleID and Account ID will always be 0000, as I don't think CFW patches out the ConsoleID check (it at least didn't use to, since CIAs made with the "personal" option in FunkyCIA would not install on another 3DS IIRC), and changing the account ID would likely result in the games being deleted/disabled when you enter eShop (that's just a guess though based on what happens if you system transfer a 3DS to another, restore a NAND backup from before the transfer then try accessing eShop)
     
  11. cearp

    cearp the ticket master

    Member
    7,406
    4,658
    May 26, 2008
    Tuvalu
    the account id can have a value and still install, but i blanked it in FunkyCIA to remove any data that could tie the cia to the user (back when we were making good cias from real tickets, instead of just creating the ticket)
    @The Real Jdbye could be right about the guess, i have no idea
     
  12. Trojaner

    Trojaner GBAtemp Regular

    Member
    134
    37
    May 1, 2017
    Australia
    Moon
    few games need a Seed, but we have only one time need for the seed ... install game with the seed (seeddb.bin from that side doesn´t work on all games like Pokemon Moon/Sun can´t be decrypt for me atleast) ... build cia from installed game ... decrypt the game cia ... game work allways with this steps, reflashed my old Nand Backup and the Seed needed games still work
     
  13. starburst
    OP

    starburst Member

    Newcomer
    23
    2
    Apr 15, 2017
    United States
    I only have less than ten games installed, but two of them, FE Fates and FE Echoes, needed a seed. And they happen to be the ones I play the most.

    Using a full Seed Database has already been suggested, and I guess that it will be the easiest solution to my situation. This way, I will be able to backup content downloaded through CIAngel and install everything offline on a new system.