Homebrew [RELEASE]Corbenik CFW Updater

The Catboy

GBAtemp Official Catboy™: Boywife
Member
Joined
Sep 13, 2009
Messages
27,947
Trophies
4
Location
Making a non-binary fuss
XP
39,339
Country
Antarctica
why make it inside a folder? I currently download the file to the root of the card. Is there any issue with this? or is it all you want is for it to auto-remove itself?
An auto removal tool is what I am suggesting. It just seems cleaner to store unneeded files in a separate folder, then delete the folder afterwards. Although, you could still accomplish the same goal without doing that. :unsure:
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
An auto removal tool is what I am suggesting. It just seems cleaner to store unneeded files in a separate folder, then delete the folder afterwards. Although, you could still accomplish the same goal without doing that. :unsure:
Well, I've updated the script on github to remove the zip after installation, I'll make a CIA in a while, when I can.
 
Last edited by gnmmarechal,

The Catboy

GBAtemp Official Catboy™: Boywife
Member
Joined
Sep 13, 2009
Messages
27,947
Trophies
4
Location
Making a non-binary fuss
XP
39,339
Country
Antarctica
Well, I've updated the script on github to remove the zip after installation, I'll make a CIA in a while, when I can.
I will have to test it later since I am going to work soon.
 

Billy Acuña

Well-Known Member
Member
Joined
Oct 10, 2015
Messages
3,126
Trophies
1
Age
31
XP
3,701
Country
Mexico
This runs on LPP-3DS. It is based on my EasyRPG 3DS Updater: RE.


This tool allows you to download the latest version of Corbenik CFW to your 3DS directly.

It supports different payload paths than ARM9Loaderhax.bin. To do so, check the location of your payload (imagine it is SD:/somedirectory/somefile.bin).

Create a file on the root of the SD Card called "corbenik-updater.cfg" and write "/somedirectory/somefile.bin" without the quotes.

Download: http://gs2012.xyz


You can also download from Github. Link is on the page.

A CIA has been built. It can be found on the gs2012.xyz page for this project.

It seems to work.

Special thanks to:

@Rinnegatamante for Lua Player Plus 3DS

@Crystal the Glaceon for testing and screenshot :)

hni_0040-jpg.52669
Excuse me, but this conflicts with the TID of another homebrew (Organize3D).
Could you change the TID in the next release?
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
Excuse me, but this conflicts with the TID of another homebrew (Organize3D).
Could you change the TID in the next release?
Hum, ORGANIZ3D uses 0x1337. This uses 0x1540. How does it conflict?

EDIT: You're using an old version. Currently, the TID is not the same as ORGANIZ3D. Use 0.2.3 instead.
 
Last edited by gnmmarechal,
  • Like
Reactions: Billy Acuña

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
I will have to test it later since I am going to work soon.
Actually never mind the updater to the updater being the next feature. Apparently I already implemented that and forgot about it. lol.
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
Welp, I made some changes to how the update works, so... 0.3.0 will be the minimum version for auto-updating to work.

@Crystal the Glaceon could you give 0.3.0 a shot? Make a file named /corbenik-updater/useupdate on your SD Card, and see if it works properly, it should download and run the Lua script from a server. If you successfully get to the menu using 0.3.0 AND the "useupdate", it means it works.

Download 0.3.0
 

The Catboy

GBAtemp Official Catboy™: Boywife
Member
Joined
Sep 13, 2009
Messages
27,947
Trophies
4
Location
Making a non-binary fuss
XP
39,339
Country
Antarctica
Welp, I made some changes to how the update works, so... 0.3.0 will be the minimum version for auto-updating to work.

@Crystal the Glaceon could you give 0.3.0 a shot? Make a file named /corbenik-updater/useupdate on your SD Card, and see if it works properly, it should download and run the Lua script from a server. If you successfully get to the menu using 0.3.0 AND the "useupdate", it means it works.

Download 0.3.0
Sorry for the delay, testing it now

--------------------- MERGED ---------------------------

Code:
Error: [string "?"]:254: attempt to concatenate a nil value (global 'core versionstring')
 
  • Like
Reactions: gnmmarechal

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
Sorry for the delay, testing it now

--------------------- MERGED ---------------------------

Code:
Error: [string "?"]:254: attempt to concatenate a nil value (global 'core versionstring')
is that when the file /corbenik-updater/useupdate exists?
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
Yup, let me test it without the file
anyway, version 0.3.1 may come out if I find the issue. If it still doesn't work, I'll skip this issue of the auto-updating not working for now, and I'll make some server-side changes (more specifically, a script to download the latest version from Github every hour to my server, which should make it ok, since my server doesn't have SSL, so the updater should work properly. I've done something similar earlier today, because of EasyRPG changing servers for the build making the new server incompatible with LPP. I made a PHP script to download the files every hour to my server, and that seems to work well.).
 
  • Like
Reactions: The Catboy

chaoskagami

G̷̘̫̍̈́̊̓̈l̴̙͔̞͠i̵̳͊ţ̸̙͇͒̓c̵̬̪̯̥̳͒͌̚h̵̹̭͛̒̊̽̚
Developer
Joined
Mar 26, 2016
Messages
1,365
Trophies
1
Location
↑↑↓↓←→←→BA
Website
github.com
XP
2,287
Country
United States
anyway, version 0.3.1 may come out if I find the issue. If it still doesn't work, I'll skip this issue of the auto-updating not working for now, and I'll make some server-side changes (more specifically, a script to download the latest version from Github every hour to my server, which should make it ok, since my server doesn't have SSL, so the updater should work properly. I've done something similar earlier today, because of EasyRPG changing servers for the build making the new server incompatible with LPP. I made a PHP script to download the files every hour to my server, and that seems to work well.).

I'm going to add SHA512sums next release, FYI. I suggest you check them for sanity purposes both when mirroring and from Lua. That should cut down on errors.

I may attempt to make my own updater at some point to obsolete the need for Lua (no 302 support.) No offense intended if I do - it isn't happening anytime soon, at least. I have more important things to work on. :P
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
I'm going to add SHA512sums next release, FYI. I suggest you check them for sanity purposes both when mirroring and from Lua. That should cut down on errors.

I may attempt to make my own updater at some point to obsolete the need for Lua (no 302 support.) No offense intended if I do - it isn't happening anytime soon, at least. I have more important things to work on. :P
Don't worry, I won't feel offended, an official solution is always better imo.
 
  • Like
Reactions: chaoskagami

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
0.3.3 released!

Supports usage of arm9loaderhax.bin and arm9loaderhax_si.bin as default payloads (without setting a custom payload path) and allows for auto-updating and updating to the chainloader/no-chainloader versions of Corbenik.

Read the README for more information.


As always, a clean update is recommended when updating Corbenik CFW.

http://gs2012.xyz/3ds/corbenikupdater/
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
0.3.4 available!

Fixes an issue with Dirty Update, and supports BGMs (/corbenik-updater/bgm.wav, /corbenik-updater/bgm.ogg or /corbenik-updater/bgm.aiff).

There won't be an updated CIA for this. To use this update, please create a file named /corbenik-updater/useupdate on the SD card.
 

Spazturtle

Active Member
Newcomer
Joined
Jun 25, 2016
Messages
30
Trophies
0
Age
29
XP
174
Country
why make it inside a folder? I currently download the file to the root of the card. Is there any issue with this? or is it all you want is for it to auto-remove itself?

At the moment when using a custom path you backup the existing arm9loaderhax.bin and then overwrite it and then move the new arm9loaderhax.bin to the new path (and rename) and then restore the backup right?

But this means that if the update fails for some reason or I want to cancel it I can no longer boot my 3DS without downloading a new copy of my bootloader and placing it on the SD card.

If it was done in a tmp directory then there is no chance of messing anything up.
 

gnmmarechal

Well-Known Member
OP
Member
GBAtemp Patron
Joined
Jul 13, 2014
Messages
6,039
Trophies
2
Age
25
Location
https://gs2012.xyz
Website
gs2012.xyz
XP
5,990
Country
Portugal
At the moment when using a custom path you backup the existing arm9loaderhax.bin and then overwrite it and then move the new arm9loaderhax.bin to the new path (and rename) and then restore the backup right?

But this means that if the update fails for some reason or I want to cancel it I can no longer boot my 3DS without downloading a new copy of my bootloader and placing it on the SD card.

If it was done in a tmp directory then there is no chance of messing anything up.
If you get the latest A9LH you can boot without SD card to a Mini Luma CFW, making it possible to boot, rename the file, and reboot from the 3DS.

What I do is:

I download the ZIP. I rename the original payload to something else, I extract the ZIP, then the payload, and if you're using a custom path, I rename the original payload back. I don't overwrite any payload. If you're using a custom path, the payload at the root will be the same. If you're not, the old copy will be renamed to something else using time and date. Let's be honest. Any "failed update" is never good. Even with the official Nintendo updater, a failure can brick your device. Corbenik Updater simply renames stuff, it doesn't delete the old files unless they are on a custom path. I'm not sure if custom path bins are deleted, but if they are, I'll make it so they are renamed. I'm not entirely sure, actually.

The only thing I'd change would be to check the SHA512 hash of the file prior to installing, as to prevent failed updates. I'm still looking into using SHA512 with Lua, actually.

I don't see any point in a temp directory.

Now that I look at it, I might make some changes, the installation code looks weird.

--------------------- MERGED ---------------------------

I spotted some potential issues for people who use arm9loaderhax_si.bin as their main payload, although I've never encountered any issues.

Should be fixed in the latest OTA update.

efe202de59c48fae75b4e97baf46420c.png
 
Last edited by gnmmarechal,

chaoskagami

G̷̘̫̍̈́̊̓̈l̴̙͔̞͠i̵̳͊ţ̸̙͇͒̓c̵̬̪̯̥̳͒͌̚h̵̹̭͛̒̊̽̚
Developer
Joined
Mar 26, 2016
Messages
1,365
Trophies
1
Location
↑↑↓↓←→←→BA
Website
github.com
XP
2,287
Country
United States
The only thing I'd change would be to check the SHA512 hash of the file prior to installing, as to prevent failed updates. I'm still looking into using SHA512 with Lua, actually.

I'm aware that these are for a minecraft mod (OpenComputers) and one is a sha256 implementation, but some code in pure lua:

https://github.com/OpenPrograms/Pixel-Programs/blob/master/sha512.lua (no clear license)
https://github.com/OpenPrograms/Pixel-Programs/blob/master/bit64.lua (no clear license)

https://github.com/JustAPerson/LuaCrypt/blob/master/sha2.lua (sha256, but would be pretty easy to extend)
 
Last edited by chaoskagami,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    SylverReZ @ SylverReZ: https://www.youtube.com/watch?v=TKyNPg7UIIc