Homebrew DSi Homebrew Channel (IDEA)

Status
Not open for further replies.

cornaljoe

Well-Known Member
Member
Joined
Jan 13, 2006
Messages
523
Trophies
0
Age
39
Website
Visit site
XP
357
Country
United States
I think there may be a way to do an exploit through the Sound Channel. Earlier today I was playing AAC's from the SD card while making a playlist. When I close the lid the DSi froze and holding the power wouldn't shut it off. I don't really know if this really is a way, just saying it's a possibility. Maybe a buffer overflow can be used in the Sound Channel to run external code.
 

darkriku2000

Well-Known Member
Member
Joined
Apr 13, 2009
Messages
247
Trophies
0
XP
334
Country
United States
cornaljoe said:
I think there may be a way to do an exploit through the Sound Channel. Earlier today I was playing AAC's from the SD card while making a playlist. When I close the lid the DSi froze and holding the power wouldn't shut it off. I don't really know if this really is a way, just saying it's a possibility. Maybe a buffer overflow can be used in the Sound Channel to run external code.

That is very interesting. From what I can tell most buffer overflows start with the system crashing, than they tell the system to pick up another code to keep it running.

Now I just have a few questions:
1) How did you get the system to freeze
2) Does it happen often
3) How did you manage to turn the system off after it froze
4) What songs/files where you playing
5) Did you try putting a .nds or .bin file anywhere on your sd card to see if you could invoke something

Hopefully, if we can cause a buffer overflow through the music player than we can find a place off the memory stick to run homebrew from, I wonder if we could get bushing and the twiizers on this, since they have a large amount of experience
 

Kingfield

Well-Known Member
Member
Joined
Nov 8, 2007
Messages
561
Trophies
0
XP
358
Country
darkriku2000 said:
cornaljoe said:
I think there may be a way to do an exploit through the Sound Channel. Earlier today I was playing AAC's from the SD card while making a playlist. When I close the lid the DSi froze and holding the power wouldn't shut it off. I don't really know if this really is a way, just saying it's a possibility. Maybe a buffer overflow can be used in the Sound Channel to run external code.

That is very interesting. From what I can tell most buffer overflows start with the system crashing, than they tell the system to pick up another code to keep it running.

Now I just have a few questions:
1) How did you get the system to freeze
2) Does it happen often
3) How did you manage to turn the system off after it froze
4) What songs/files where you playing
5) Did you try putting a .nds or .bin file anywhere on your sd card to see if you could invoke something

Hopefully, if we can cause a buffer overflow through the music player than we can find a place off the memory stick to run homebrew from, I wonder if we could get bushing and the twiizers on this, since they have a large amount of experience
If the DSi froze like that I would assume it was a one-off thing and will be hard/near impossible to replicate on a regular basis.
 

captainobvious5

New Member
Newbie
Joined
Apr 12, 2009
Messages
4
Trophies
0
XP
30
Country
United States
Well we were able to crash the DSi through it's browser, but there was no real find on anything for that. Also, this: http://secunia.com/advisories/34135/ looks very possible. It is a JPG exploit in the Opera browser that allows unsigned code to run. The only problem with that is that I am pretty sure the browser runs in a mode where it can't access system recourses. The best bet is a buffer overflow exploit using the photo channel. A JPG image with a custom header should be able to work, but we first have to get the images to display on the DS. Yasu's exploit was actually a buffer overflow through the photo channel, so we are in luck.

BTW here is the report from the browser crash if anyone can make a better understaning of it than I can. http://milw0rm.com/exploits/8320
 

houseonfire

Well-Known Member
Member
Joined
May 21, 2007
Messages
285
Trophies
0
XP
112
Country
United States
If someone could accurately and correctly decompile the .bin files that are produced from the channels; I have an idea. But I'd like to see a howto, or a rapidshare link to the files.



EDIT:
Along the lines of the system update. What if you disconnected your router from the internet, made your own hosted local website on your own network.
Then made a link that was the same exact link that the DSi connected to to get its new firmware.

Although I understand the multiple flaws and down points of this idea. Just a though.
 

Kingfield

Well-Known Member
Member
Joined
Nov 8, 2007
Messages
561
Trophies
0
XP
358
Country
houseonfire said:
If someone could accurately and correctly decompile the .bin files that are produced from the channels; I have an idea. But I'd like to see a howto, or a rapidshare link to the files.



EDIT:
Along the lines of the system update. What if you disconnected your router from the internet, made your own hosted local website on your own network.
Then made a link that was the same exact link that the DSi connected to to get its new firmware.

Although I understand the multiple flaws and down points of this idea. Just a though.

We can't do this until we actually manage to decompile/decrypt a firmware and build a new one.

We are nowhere near that point atm, so this wouldnt be possible.
 

SifJar

Not a pirate
Member
Joined
Apr 4, 2009
Messages
6,022
Trophies
0
Website
Visit site
XP
1,175
Country
Kingfield said:
MicShadow said:
You should really look at the twilight hack exploit. Bushing and co released full docs on it, or at least how it worked. Cant remember the link though
We can't do anything like this at least until DSi only games come out... or do DSiWare saves save into the SD card and can be transferred?

well, they dont have to be DSi only, just have DSi specific features. This way they will work in a regular DS, so we can use Rudolph's backup tools to transfer a hacked save on to them, then put them in the DSi, which will start them in DSi mode because they have DSi specific features, then the save will (hopefully) crash it allowing us to run unsigned code. Of course, this could be impossible, but it's an idea. I assume it'll use the same save weather in a DS or a DSi, but if it doesnt, i dont think this will work. I see no reason for it not to use the same save, just pointing out a possible flaw.
 

redact

‮҉
Member
Joined
Dec 2, 2007
Messages
3,161
Trophies
0
Location
-
XP
674
Country
Mauritania
Ichigo Kurosaki said:
And a Twilight Princess like save hack wouldn't work because saves aren't stored on the DSi's memory....

wrong, it doesn't matter where the saves are stored, the reason that a save exploit wouldn't do anything is that all current ds carts run in ds mode and dsiware exploit is not an option yet as nobody has managed to recover the dsi's common-key yet...
 

Kingfield

Well-Known Member
Member
Joined
Nov 8, 2007
Messages
561
Trophies
0
XP
358
Country
Ichigo Kurosaki said:
cornaljoe said:
I think there may be a way to do an exploit through the Sound Channel. Earlier today I was playing AAC's from the SD card while making a playlist. When I close the lid the DSi froze and holding the power wouldn't shut it off. I don't really know if this really is a way, just saying it's a possibility. Maybe a buffer overflow can be used in the Sound Channel to run external code.

I did the same when I was using WiFI Data Transfer on My DSi to my DSL, and, I turned off my DSL on accident and then in a few seconds, my DSi froze on me!!!!

The only way I could turn it off was by removing the battery!!

Don't think this could be used to exploit something though
unsure.gif
...


Mostly every feature of the DSi that uses the SD Card could be used for an exploit!

And a Twilight Princess like save hack wouldn't work because saves aren't stored on the DSi's memory....

Can't run an exploit through here because we cannot change the data that goes through.
 
L

lilkerv90210

Guest
<b>This was posted in another thread called DSi hacking.. i hope this helps</b>

<b>FAST6191 wrote</b>

Right the
back to the basics, also DS flash cart history 101.
I have a more general document about the following in the works but until then:

To build a flash cart you first have to know how the signals between the game cart and DS occur, this can be done in many ways (logic, logging, code injection, some other analysis, reading the hardware specifications*....). Once you have this you can start messing around with things.

*this need not be the same as reading the official SDK, many makers will hide information from their developers for various reasons.

In the case of the original DS there was protection on the DS carts hence your needing an original cart with the passme, the passme allowed the DS to authenticate the cart and then after that it abused the signals. Also there were already well developed GBA carts which could be read in the DS mode so people just jumped the reads to the GBA slot (this was the passme, a later revision of the DS blocked this but left the GBA SRAM accessible leading us to the passme2 which used the SRAM instead).
If you want to learn more about the passme then
<a href="http://nocash.emubase.de/gbatek.htm#dscart...ssmepassthrough" target="_blank">http://nocash.emubase.de/gbatek.htm#dscart...ssmepassthrough</a>
<a href="http://www.dspassme.com/docs.shtml" target="_blank">http://www.dspassme.com/docs.shtml</a>

As an aside along with this came flashme, the DS firmware is located on an unencrypted easily writeable chip; the wifi stuff was actually added on in a patch from Nintendo, many believe this was to avoid licensing the required standards in the event the DS failed (believe it not things were very touch and go for the first year or so). Flashme patched this firmware to, amongst other things, allow code to run from the GBA slot if necessary.

Now flash carts work by taking signals to the game cart and in turn interpreting them to help access the required section of the SD/CF/ms or other memory section and then sending the data back in the format required.
In the case of the GBA carts this meant a fairly radical shift from the existing format the games were hardcoded for and some fairly extensive patching was required for games to run and to save (some games that did not patch properly actually used the game in the passme).
For the record chips for consoles (looking mainly a CD/DVD media), the DVD makers will make their writers only able or unable as the case may be to to read and write certain sections that are then used to detect "official media" or hide date. The chip/hack then works around this and redirects to a section that can be read/written to by conventional hardware.

Some time later the DS encryption was broken (Martin Korth or NO$GBA and gbatek notoriety was the person responsible) and the first nopass was made (no more official game needed to launch code), a few minutes (or so it seemed) later many clones/tweaks were made by every flash cart maker out there.

A little while after that the first DS carts sprang up, they were a bit rough and ready (one even required flashme to dodge the inbuilt encryption) but they were refined.

Flash carts invariably have some onboard logic which allows it to initially boot up when it gets powered, such a piece of code is known as a bootstrap loader. Many cards can not update this in any meaningful way (namely via software) which is the reason we did not just see updates to many cards to simply add SDHC when it became available and more recently updates to allow them to work on the DSi (the DSi updated security to check for things normal carts did not do but flash carts do, I understand a similar method is used for piracy checks in the newer games).
This then loads another loader (some carts use another onboard section, others rely on the presence of the loader on a memory card).

Now to the DSi, as mentioned earlier the main way to get information on the hardware is reverse engineering. For the uninitiated reverse engineering is the act of taking a piece of hardware and applying all manner of techniques to figure out how it works, without the original plans and with a device as complex as the DS there is quite likely to be holes in the reverse engineered specification of the device. If you incorporate these holes into a new design then your device may not function as intended or indeed as was the case with the DSi can be detected (and blocked), there are other methods including whitelisting, blacklisting, greylisting, heuristics (a form of which were used here) based on file name, data within files (either hashing or signature analysis), actions of the device/code but going into that would be getting off track.

As for encryption, if done properly it works and works very well. However doing it properly (either the method can be faulty or the way you implement it can, some nice examples of both in the original xbox <a href="http://www.xbox-linux.org/wiki/17_Mistakes...em#Introduction" target="_blank">http://www.xbox-linux.org/wiki/17_Mistakes...em#Introduction</a> ) can be very difficult as the countless hacks across history have proven.
There are two main types of encryption called symmetric and asymmetric:
Symmetric uses the same key to encode and decode information meaning you have to protect your key very well.
Example, XOR encryption.
Some random data (actually it reads SDAT in ASCII)
0101 0011 0100 0100 0100 0001 0101 0100

XOR encryption, here the key is 8 bit (easily broken by normal methods but it will be used here).
Key used is "BB" (1011 1011). Remember for a “2 pin” XOR the output is only 1 if one of the inputs is 1 (none or both means 0). XOR encryption works in the principle that for every binary digit there are two possibilities meaning very quickly you are dealing with powers 2^1024 or 1.797693134862315907729305190789e+308 combinations for a single 128 byte file).

0101 0011 0100 0100 0100 0001 0101 0100
With XOR encryption
1110 1000 1111 1111 1111 1010 1110 1111

Asymmetric uses two different keys (one to encode and one to decode), it is usually marred by increased resources required (all encryption requires more resources but asymmetric tends to require more).
Example (basic RSA):
<a href="http://mathcircle.berkeley.edu/BMC3/rsa/node4.html" target="_blank">http://mathcircle.berkeley.edu/BMC3/rsa/node4.html</a>
The thing about these is you can give your public key to anyone out there without issue, in theory they can reverse the public key to get the private key but you are protected by maths. In most case this is the difficulty of taking a number and factoring it, RSA uses semiprime numbers for this (two prime* numbers multiplied together)
* for those just joining this maths game then prime numbers are numbers that only have themselves and one as factors (7, a prime, can only be made by multiplying 7 by 1 and 1 by 7). They are unpredictable (there is no pattern in primes) and the only way to test them is to try dividing by every number up to the halfway mark, there is no big list of prime numbers after a given point (any that exist are far behind the numbers being used for encryption).

Also important here is hashing, it works by taking the data and performing a mathematical operation upon it to give a number as an output (ideally it will be unique, unpredictable and unable to be reversed given present methods) the simplest hash is called parity or in normal numbers it is referred to as odd or even. That way if someone sends some something and also says it is odd but the message is even then something has gone wrong. Odd or even is useless for most things though as there are just as many odd numbers as even (failing the unique hash requirement), there are two grades of has as well: cryptographic and non-cryptographic. Simply put the requirements of "ideally it will be unique, unpredictable (you can not find a message and say aha that has a hash of [this] without first calculating it) and unable to be reversed with present methods"
More
<a href="http://unixwiz.net/techtips/iguide-crypto-hashes.html" target="_blank">http://unixwiz.net/techtips/iguide-crypto-hashes.html</a>
<a href="http://www.youdzone.com/signature.html" target="_blank">http://www.youdzone.com/signature.html</a>

The cousin of encryption and hashing is signing (so much so that you can turn any encryption method into a signing method), here the section you want signed is either
* encrypted and then data extracted from the encrypted data although this is rarely used because it has security issues, mainly when implementing it, and resource issues.
A variation on this is used in the GBA and DS carts in the form of the logo, it was thought by having a copyrighted/trademarked logo that it was "legally" safe. In the US a famous case between Sega and Accolade <a href="http://digital-law-online.info/cases/24PQ2D1561.htm" target="_blank">http://digital-law-online.info/cases/24PQ2D1561.htm</a> it was ruled against, Europe is not quite so lucky in many cases (there was something happening in France but I can not find a link right now). Naturally the law is not as simple as this and there are many things for and against it.

* Hashed with a normal hashing method and then the signature is the encryption of the hashes (you can not change the data without changing the hash which then changes the signature).
Again:
<a href="http://www.youdzone.com/signature.html" target="_blank">http://www.youdzone.com/signature.html</a>

You can sign your code (the wii discs: <a href="http://debugmo.de/?p=61" target="_blank">http://debugmo.de/?p=61</a> and <a href="http://hackmii.com/2008/04/keys-keys-keys/" target="_blank">http://hackmii.com/2008/04/keys-keys-keys/</a> ), you can encrypt your memory (the xbox 360: <a href="http://www.youtube.com/watch?v=uxjpmc8ZIxM&fmt=18" target="_blank">http://www.youtube.com/watch?v=uxjpmc8ZIxM&fmt=18</a> (I suggest watching this if you are at all interested in how this hardware hacking stuff works as it covers a lot of ground) ), you can encrypt your drive and other ways of storing inherently "random" data (the PS3 drive: <a href="http://www.haxnetwork.net/2009/03/ps3-hdd-...ypted-tutorial/" target="_blank">http://www.haxnetwork.net/2009/03/ps3-hdd-...ypted-tutorial/</a> )

Re: DSi mode. As many know the DSi has increased hardware capabilities yet retains compatibility with "older" games/hardware. When you emulate something you convert signals from their original form into one your hardware can use, if at some significant level your hardware happens to match the hardware being emulated you can use a thing called a hypervisor to simply pass signals to the appropriate hardware (you can also do minor conversions, the line where something becomes straight up emulation is tricky to define though).
It also doubles as a nice security feature by not allowing access to outside hardware/memory; on the wii the so called tweezer attack allowed the people doing it to use the gamecube hypervisor (we could run custom gamecube code on it) as it was then to shift the memory it could see around the wii's memory. The wii uses a symmetric key that was rather foolishly left in the memory (you should strive to have your keys in the memory for as small a time as possible when dealing with cryptography) which was promptly read and that then allowed further hacks to happen (it allowed more analysis of the internals which were all encrypted with this key, these had bugs which were then exploited).
All the current DSi carts do is emulate an original cart well enough to pass the DSi flash cart checks thus allowing "normal" DS games to run.

I think that just above covers the basics, next time reverse engineering for real.
 

desumodnoc

Member
OP
Newcomer
Joined
Apr 11, 2009
Messages
23
Trophies
0
XP
60
Country
United States
Awesome News!!!
I have just been contacted by CrashMan, one of the wii developers. He has agreed to help and we are currently looking for ways to find a DSi SD card exploit.
www.cashman-productions.fr.nf
his website.
 

MadClaw

Well-Known Member
Member
Joined
Oct 30, 2008
Messages
330
Trophies
1
Age
29
Location
Usa
XP
375
Country
United States
Great news! I've started coding in PAlib/c++/devkitarm/pro/ I'll be working hard on learning this, Few weeks from now i might be able to help you.

BTW: Since no one wants to help a guy, I'll just ask here, I just want to know what Backup launcher Gamma is coded in. Thanks.
 

darkriku2000

Well-Known Member
Member
Joined
Apr 13, 2009
Messages
247
Trophies
0
XP
334
Country
United States
I believe that it is coded in C++ have you tried actually contacting wiigator.

Also, no offense, but it might take a few weeks to be able to code an exploit, I believe that bushing said that he'd been coding for 8 years in fact
 

bushing

Well-Known Member
Newcomer
Joined
Feb 27, 2008
Messages
50
Trophies
0
XP
52
Country
United States
captainobvious5 said:
Well if it is any help an exploit has been found and homebrew has already been created and running.

Yup. It's a DS-mode savegame exploit. bLAStY has a roughly equivalent exploit (http://www.youtube.com/watch?v=7QHO7ctWuZ8), and I've even run it on my DSi. That puts you at ....

QUOTE(bushing @ Apr 13 2009, 07:02 AM)
  • Dec. 2006: First GameCube-mode code run on Wii via Action Replay. No real benefit to using Wii over GC.
[...]
So, on that timeline, you're at, oh, Jan-Feb. 2007. You're trying to jump ahead to April, 2008.
 
Status
Not open for further replies.

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Sonic Angel Knight @ Sonic Angel Knight: @_@