Decrypting DSiWare .cia?

Discussion in '3DS - Homebrew Development and Emulators' started by joesteve1914, Feb 16, 2016.

  1. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    With the recent TWL_FIRM patches that have been released, I decided I would look into translating a DSiWare game that I've always been interested in.
    Is there any way to extract a romfs from the cia file to edit? I've tried to decrypt the cia in Decrypt9, but it tells me it's already decrypted.
     
  2. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    .....Anyone?
     
  3. Xexyz

    Xexyz GBATemp's™ Official Xexyz

    Member
    1,393
    470
    Jul 29, 2013
    United States
    沖縄県
    Aren't DSiWare games just nds files inside CIA?
     
  4. cearp

    cearp the ticket master

    Member
    7,555
    4,819
    May 26, 2008
    Tuvalu
    first of all wait more than a few hours before bumping.
    maybe the cia is already decrypted. did you make it with FunkyCIA? did you find it online? maybe it still was made with FunkyCIA because unless it was converted from dsi format, if this was dumped from the eshop then yes it will be encrypted unless someone specially decrypted it

    so, decrypt it like any other eshop content... get the title key from the ticket, decrypt that, use it to decrypt the files... etc
     
  5. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    Oh, sorry about that. I noticed that it was on the second page and only had 1 view. I'll be more patient in the future.
    It was dumped with FUNKYCIA, but not by me. How would I obtain a ticket for it?
     
  6. cearp

    cearp the ticket master

    Member
    7,555
    4,819
    May 26, 2008
    Tuvalu
    the ticket is in the cia, and easy way would be to use FunkyCIA to dump the ticket, use the cia as input instead of a ticket.db use -noignore to stop ignoring the ticket because it would be ignored beccause it's not a legit ticket :)
     
    joesteve1914 likes this.
  7. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    Is the tmd file that FUNKYCIA generates the ticket?
     
  8. cearp

    cearp the ticket master

    Member
    7,555
    4,819
    May 26, 2008
    Tuvalu
    no tmd, you want the ticket.
    this dsiware may already exist in decrypted form somewhere, have you had a good look?
    you can tell us what game if you want, just no sharing of the files :)
     
    joesteve1914 likes this.
  9. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    Trust me, I have had a good look. The game isn't found anywhere, and i had no way of getting it since its jpn eshop only, and i have a us 3ds. Someone on reddit dumped it for me as a cia using FUNKYCIA.

    The game is Too Much Tingle Pack, if you were curious, but like I said I couldn't find a dump anywhere.

    How would I obtain the ticket then? I typed into cmd [FunkyCia2.py tp.cia -no ignore -type ALL]. Is that wrong? (I'm guessing it is.)
     
  10. cearp

    cearp the ticket master

    Member
    7,555
    4,819
    May 26, 2008
    Tuvalu
    sure that looks like it would work :)
    use -nodownload also, so that the files from cdn won't be downloaded, because all you want is the ticket
     
  11. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
    So the cetk file is the ticket?
    Edit - nvm, I've confirmed that the cetk file is the ticket. Would I use decrypt9 to decrypt the cia? How would I point it to the ticket?
     
    Last edited by joesteve1914, Feb 17, 2016
  12. cearp

    cearp the ticket master

    Member
    7,555
    4,819
    May 26, 2008
    Tuvalu
    use a hex editor and find the title key in the ticket.
    or just use this https://github.com/Relys/3DS_Multi_Decryptor
    it will help you decrypt from your ticket.db too
     
  13. joesteve1914
    OP

    joesteve1914 GBAtemp Fan

    Member
    352
    146
    Jul 31, 2012
    United States
  14. matt!

    matt! GBAtemp Regular

    Member
    251
    41
    Nov 20, 2009
    Can you describe your whole process to us? along with what happens after you've decrypted? Thanks