How to get Switch Keys for Hactool/XCI Decrypting

Discussion in 'Switch - Tutorials' started by PRAGMA, Jun 10, 2018.

  1. Teclo

    Teclo Advanced Member

    Newcomer
    2
    Nov 14, 2008
    England
    Ah, I was sure I had but I checked again and it was "eMMC RAW GPP" that I backed up as well as the 0/1 option. Okay, thanks I'll do that now then.
     
  2. Bloodlust

    Bloodlust GBAtemp Maniac

    Member
    4
    May 25, 2006
    Hong Kong
    Will I be able to get Master Key 0-5 if I'm only on 5.1.0?
     
    Zaybokk likes this.
  3. Cencil

    Cencil GBAtemp Regular

    Member
    4
    Aug 24, 2016
    Canada
    There is no way around the error when trying to dump keys on a 6.2.0 switch?? Gotta be another way to get the keys on 6.2.0 to be able to install NSPs and XCI's by now...6.2.0 is cracked :/
     
  4. Blootor

    Blootor Newbie

    Newcomer
    1
    Dec 9, 2018
    Spain
    There is a way around it, I did it yesterday. You need to use ChoiDujourNX to downgrade your firmware to 6.1.0, then you can get your keys. Upgrade back to 6.2.0 after.
     
  5. Draxzelex

    Draxzelex GBAtemp Guru

    Member
    17
    Aug 6, 2017
    United States
    New York City
    Lockpick was released to not only replace kezplez, but can dump keys even on firmware 6.2
     
    datnodude likes this.
  6. Blootor

    Blootor Newbie

    Newcomer
    1
    Dec 9, 2018
    Spain
    Haha! about 6 hours after I did it through downgrading.
     
  7. chardido

    chardido Member

    Newcomer
    1
    Dec 10, 2018
    Italy
    Did you solved? I'm in the same situation :( My keys are correct, just checked
     
    Last edited by chardido, Dec 10, 2018
  8. thesjaakspoiler

    thesjaakspoiler Member

    Newcomer
    2
    Nov 20, 2018
    Afghanistan
    For one Switch (6.2.0) the keys.py script worked fine but for another Switch (also 6.2.0) also throws this error :
    Using BOOT0.bin to get keys from package1...
    Could not find keyblob_mac_key_source! Please check the integrity of the data used in the current stage!

    I tried to dumping all the secure_boot_key and tsec_key again with biskeydumpv7 but they are exactly the same.
    Also tried dumping Boot0+eMMC SYS again but they are aso exactly the same.
    No errors during the dumping process.

    The only difference I see between the 2 Switches is that 1 was upgraded from 4.1.0 to 6.2.0 and the one giving problem was upgraded from 6.1.0 to 6.2.0.

    Is there any way to verify the secure_boot_key , tsec_key and bin files are valid?
     
  9. thesjaakspoiler

    thesjaakspoiler Member

    Newcomer
    2
    Nov 20, 2018
    Afghanistan
    To follow up on my endevour to identify what caused the error "Could not find keyblob_mac_key_source!",
    I dumped my keys with the homebrew app Lockpick.
    Looking at the prod.keys, it turns out my tsec and sbk key were correctly dumped by Hekate.
    So that leaves either the BOOT0 dump, keys.py or hactool.
    I compiled hactool on another linux box and it threw the same error again.
    So that only leaves BOOT0.
    But package1.bin and package2.bin are correctly extracted by the keys.py script.
    So we're maybe looking at some weird border case....

    Anybody any idea to how to check if BOOT0, package1.bin and package2.bin are valid?
    I presume they are encrypted differently for each console.

    Is there any other tool around to dump BOOT0 besides Hekate?
     
  10. shchmue

    shchmue GBAtemp Advanced Fan

    Member
    6
    Dec 23, 2013
    United States
    I'm not going to update this script anymore as it's super outdated and shouldn't be used. Present, up-to-date recommendations here include Lockpick for homebrew and HACGUI for RCM. At time of writing, Lockpick is the only solution that will get 06-keys if you follow the instructions while on firmware 6.2.0. Equivalent support via HACGUI is on the way, but for now it works on < 6.2.0.
     
    chardido and Draxzelex like this.
  11. thesjaakspoiler

    thesjaakspoiler Member

    Newcomer
    2
    Nov 20, 2018
    Afghanistan
    @shchmue
    Thanks for pointing out to move to LockPick.
    That definitly worked great on my Switch of where the keys.py script didn't work.
    Thanks for all the hard work!
     
    datnodude likes this.
  12. chardido

    chardido Member

    Newcomer
    1
    Dec 10, 2018
    Italy
    I need the key for 6.2.0, cause my Switch is bricked (blue screen on boot).
    I must wait an update of Hacgui or there is another method to retrieve keys from switch?
     
  13. datnodude

    datnodude Member

    Newcomer
    2
    Jul 6, 2018
    United States
    dude thanks so much, i thought i was screwed when i updated to 6.2
     
  14. DaveSwitch

    DaveSwitch Member

    Newcomer
    2
    Jul 15, 2018
    Canada
    Hyrule Castle
    Help pls
     

    Attached Files:

    Mambitos likes this.
  15. shchmue

    shchmue GBAtemp Advanced Fan

    Member
    6
    Dec 23, 2013
    United States
    doesn't work on 6.2.0
     
  16. DaveSwitch

    DaveSwitch Member

    Newcomer
    2
    Jul 15, 2018
    Canada
    Hyrule Castle
    Well I tried to downgrade at 1.0 version and I can't boot ofw/cfw so is it like if I was on 6.2.0? (I need keys.txt file to upgrade my switch with choidujour)
     
  17. tommygunzs

    tommygunzs Newbie

    Newcomer
    1
    Oct 6, 2018
    United States
    Can use lockpick, it supports 6.2
    github. com/shchmue/Lockpick
     
  18. DaveSwitch

    DaveSwitch Member

    Newcomer
    2
    Jul 15, 2018
    Canada
    Hyrule Castle
    Can't access cfw/ofw
     
  19. shchmue

    shchmue GBAtemp Advanced Fan

    Member
    6
    Dec 23, 2013
    United States
    Draxzelex likes this.
  20. DaveSwitch

    DaveSwitch Member

    Newcomer
    2
    Jul 15, 2018
    Canada
    Hyrule Castle
Loading...