Hacking Discussion Info on SHA-256 hashes on FS patches

impeeza

¡Kabito!
Member
Joined
Apr 5, 2011
Messages
6,393
Trophies
3
Age
46
Location
At my chair.
XP
18,867
Country
Colombia
I've already fixed this, I'm adding/chaging some stuff and will upload a fixed version when I am done. Also if you look at the github page, I've updated the code with this problem fixed, so you can compile it yourself in the meantime if you have visual studio installed.
will give a shot, but I haven't set a Visual Studio environment before, so will learn how to :D regards buddy.
 
  • Like
Reactions: mrdude

HalfScoper

Well-Known Member
Member
Joined
Apr 16, 2021
Messages
552
Trophies
0
Age
84
XP
1,494
Country
Germany
Hi I ran into some issues and I hope you can help out or maybe fix it, depending on whether I'm just stupid or there is actually an issue.

First off I did extensive testing with my own device and a friend that was willing to help out, I might have set things the wrong way or something but I really did my best to debug the issue.

Since the Lockpick_RCM version was released after FW 15.0.1, I today attempted to update my sysNAND to 15.0.1, extract keys via Lockpick and use your latest version of the Patch Creator to make patches out of 15.0.1 keys and firmware files.

I placed my prod.keys in tools and renamed them, started your exe and chose default settings.
The processes all were "green" so I assume ok per se, however while using them there are some issues.
I proceeded to make a new 15.0.1 emuNAND and installed title backups via DBI without issues, also could boot them just fine.
I gave those patches to a friend to test them the same way and they also succeeded at first, however when they wanted to launch Tinfoil it did not work, even though DBI and backups did just fine.

It might be worth of notice that they used 15.0.0 instead of .1 like me, and I also did not install Tinfoil to my newly created emuNAND because I just avoid that in general.
When they added back the patches from the dedicated thread of ShadowOne, Tinfoil worked again so it has to relate to my patches.
I also tried redoing the ES patches with the 2nd method, but it didn't change the result.

Is there a way I can get in touch with you to work this out in detail?
Of course you are free to just reply here if that's sufficient because I am overlooking something (like the tool maybe needing an update for 15.0.1).
In any case thanks for reading.
 
  • Like
Reactions: impeeza

mrdude

Developer
Developer
Joined
Dec 11, 2015
Messages
3,071
Trophies
1
Age
56
XP
8,227
Hi I ran into some issues and I hope you can help out or maybe fix it, depending on whether I'm just stupid or there is actually an issue.

First off I did extensive testing with my own device and a friend that was willing to help out, I might have set things the wrong way or something but I really did my best to debug the issue.

Since the Lockpick_RCM version was released after FW 15.0.1, I today attempted to update my sysNAND to 15.0.1, extract keys via Lockpick and use your latest version of the Patch Creator to make patches out of 15.0.1 keys and firmware files.

I placed my prod.keys in tools and renamed them, started your exe and chose default settings.
The processes all were "green" so I assume ok per se, however while using them there are some issues.
I proceeded to make a new 15.0.1 emuNAND and installed title backups via DBI without issues, also could boot them just fine.
I gave those patches to a friend to test them the same way and they also succeeded at first, however when they wanted to launch Tinfoil it did not work, even though DBI and backups did just fine.

It might be worth of notice that they used 15.0.0 instead of .1 like me, and I also did not install Tinfoil to my newly created emuNAND because I just avoid that in general.
When they added back the patches from the dedicated thread of ShadowOne, Tinfoil worked again so it has to relate to my patches.
I also tried redoing the ES patches with the 2nd method, but it didn't change the result.

Is there a way I can get in touch with you to work this out in detail?
Of course you are free to just reply here if that's sufficient because I am overlooking something (like the tool maybe needing an update for 15.0.1).
In any case thanks for reading.
Just compare the patches with a hex editor with the ones you downloaded that work. you will be able to see if they are different or not.
 

HalfScoper

Well-Known Member
Member
Joined
Apr 16, 2021
Messages
552
Trophies
0
Age
84
XP
1,494
Country
Germany
Thanks for answering.
I compared the newly created files with the ones from the GBAtemp archive and they are exactly the same when inspecting with HxD, but I had success in a different way.

What I did to make them work for the other person was:
First I just used newly created 15.0.1 patches, no older ones, so I :
- used the latest TotalJustice ones as base (AMS 1.3.2 and FW 14.1.0+)
- put my new ones ontop (15.0.1 only)
- added the loader patch for 1.4.0 pre from the GBAtemp archive since it was missing on my side
- edited the patches.ini file of the base to add the loader entry for 1.4.0 pre aswell as the newly made entries from my own attempt
- and finally I changed the names and orders to match the names of previous comments and also that FS patches of 15.0.0 appear before the loader patches for 1.4.0 pre and master.

Guess I had to include the old patches aswell, it was my first attempt of creating those patches after all.
 

mrdude

Developer
Developer
Joined
Dec 11, 2015
Messages
3,071
Trophies
1
Age
56
XP
8,227
Thanks for answering.
I compared the newly created files with the ones from the GBAtemp archive and they are exactly the same when inspecting with HxD, but I had success in a different way.

What I did to make them work for the other person was:
First I just used newly created 15.0.1 patches, no older ones, so I :
- used the latest TotalJustice ones as base (AMS 1.3.2 and FW 14.1.0+)
- put my new ones ontop (15.0.1 only)
- added the loader patch for 1.4.0 pre from the GBAtemp archive since it was missing on my side
- edited the patches.ini file of the base to add the loader entry for 1.4.0 pre aswell as the newly made entries from my own attempt
- and finally I changed the names and orders to match the names of previous comments and also that FS patches of 15.0.0 appear before the loader patches for 1.4.0 pre and master.

Guess I had to include the old patches aswell, it was my first attempt of creating those patches after all.
Well take note of your firmware version in future, and generate patches based on that firmware. There's no need for any patches that don't match the firmware you are using as they don't do anything apart from take up space on your sd card.
 

HalfScoper

Well-Known Member
Member
Joined
Apr 16, 2021
Messages
552
Trophies
0
Age
84
XP
1,494
Country
Germany
Well take note of your firmware version in future, and generate patches based on that firmware. There's no need for any patches that don't match the firmware you are using as they don't do anything apart from take up space on your sd card.
Well I have to take the word of the person with whom I tested, but fact is that only 15.0.1 patches didn't work on 15.0.0 (+ AMS 1.4.0-master) the way they should whereas combining them with older patches did the trick, I personally doubt adding the missing 1.4.0-pre loader patch was necessary because the person used 1.4.0-master.

In any case I am just glad it's resolved, thanks for your time and I hope I don't run into similar issues.
 

mrdude

Developer
Developer
Joined
Dec 11, 2015
Messages
3,071
Trophies
1
Age
56
XP
8,227
Well I have to take the word of the person with whom I tested, but fact is that only 15.0.1 patches didn't work on 15.0.0 (+ AMS 1.4.0-master) the way they should whereas combining them with older patches did the trick, I personally doubt adding the missing 1.4.0-pre loader patch was necessary because the person used 1.4.0-master.

In any case I am just glad it's resolved, thanks for your time and I hope I don't run into similar issues.
15.0.0 and 15.0.1 patches are the exact same. So you must have done something wrong. Also Loader patches are required for NRO forwarders and XCI games to work. If you didn't generate the correct patches for the Atmosphere version you were using, and you installed Tinfoil that uses a NRO forwarder to launch from the switch main menu, that would be your issue.
 

HalfScoper

Well-Known Member
Member
Joined
Apr 16, 2021
Messages
552
Trophies
0
Age
84
XP
1,494
Country
Germany
15.0.0 and 15.0.1 patches are the exact same.
Yes, I also realised that comparing them with the archive found on ShadowOnes thread which hasnt been updated since 15.0.0

Again, I am relying on another persons word, I myself had no similar issue but our setups differ a bit.

If you didn't generate the correct patches for the Atmosphere version you were using, and you installed Tinfoil that uses a NRO forwarder to launch from the switch main menu, that would be your issue.
I created them from 1.4.0-master, same version that was being used from both sides, anyhow Tinfoil indeed was installed the way you described.


I think you understand me wrong in the way that I definitely don't want to blame you for issues, I am fully aware (especially now after all is done) that the issue was on my side, I might explain it too vague to make sense, I am more than thankful for your tool just so that this is clear!
 

impeeza

¡Kabito!
Member
Joined
Apr 5, 2011
Messages
6,393
Trophies
3
Age
46
Location
At my chair.
XP
18,867
Country
Colombia
I think, you problem was the lack of the Atmosphère patches.

For all working system you need firmware and loader patches.

The file patches.ini is needed for Hekate, as Hekate replace the first part of boot loader and make "on the fly" changes to the Atmosphère code, that changes are read from patches.ini.

The IPS files are loaded by Atmosphère it self and change the way of content is loaded on HOS.

ES and ES2 patches are basically the same, just two different ways of doing the same, so what of them use is more a manner of taste.

On the past was 3 or 4 set of sigpatches flying around and some of them have combined patches between ES and ES2 for different firmwares, so no problem on using one or another.

You always need boot firmware and loader patches, that's why if you compile Atmosphère by your self you need to generate a new set of patches for that compiled version (even if the version number remains the same)
 

HalfScoper

Well-Known Member
Member
Joined
Apr 16, 2021
Messages
552
Trophies
0
Age
84
XP
1,494
Country
Germany
I think, you problem was the lack of the Atmosphère patches.
No man, as stated in the first message to that matter I made the patches from designated firmware and keys, I clicked through all the tabs and created every necessary patch, I even compared them to existing and working patches and they were exactly the same.

The end result would be to blame the other person that tested with me for not communicating properly, but I don't want that and rather settle with (what I also said before) that there was an issue on my end that's resolved now.

If it helps, I am willing to share my initial "experiment" for you or others to judge If they were correct but since I am very keen on researching and following tutorials, I can say with confidence I followed this matter when there wasnt even a tool and since then I kept up with what to do before I finally attempted it myself after new Lockpick released.

Last but not least I wanna state again that my intentions never were to come here and blame the author.
 
  • Like
Reactions: mrdude and impeeza

mrdude

Developer
Developer
Joined
Dec 11, 2015
Messages
3,071
Trophies
1
Age
56
XP
8,227
nah, we are here to help, and to improve all. sorry I didn't understand from start.
Exactly, this was the entire point of the thread, so we could all learn from each other to find out how to make patches, what they were for, and to help other people understand how firmware is hashed, decompiled etc . It's not a thread for help on setting up a switch - it's just for learning about patches and that's all.
 

elcallejongamer

Member
Newcomer
Joined
Dec 2, 2021
Messages
22
Trophies
0
Age
31
XP
642
Country
Mexico
Try Create ES and ES2 PATCHES in 17.0.0
All keys are updated

Unable to decrypt, did you update your keys?

Try adjusting the ES size limits in the config settings if firmware is greater than 15.0.0.
 

BeckysFootSlave

Well-Known Member
Newcomer
Joined
Jan 4, 2022
Messages
52
Trophies
0
Age
50
XP
671
Country
Germany
First: thanks to @mrdude for the app!

Now I have a question about your python script: is it still possible to make all the patches you need today?

The program is great no question, but what is the solution for making sigpatches on Linux?
And because python should work everywhere I would use your script from post #205!

Or is there any other way to create them on Linux systems?
Post automatically merged:

Yeah the HACTOOL seems to needed to be updated.
Oh no, hactool is also making problems 🙄!

EDIT: even saw that SciresM is also working on that!
extkeys.c, kip.c and other files were changed on hactool github!
 
Last edited by BeckysFootSlave,
  • Like
Reactions: impeeza

juanguib7

New Member
Newbie
Joined
Jul 18, 2018
Messages
3
Trophies
0
Age
58
XP
59
Country
Colombia
you DON'T NEED TO CREATE you just download the file on the OP and extract to the root of your SD.
i did tried allready with severals, including this ones: Hekate+AMS-package3-sigpatches-1.6.2-cfw-17.0.0, no luck...any suggestions?...thanks for your help.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    BakerMan @ BakerMan: