Homebrew Save Nintendo WiFi - A project to save online servers for DS (and Wii) games

Toad King

Well-Known Member
OP
Member
Joined
Aug 19, 2009
Messages
374
Trophies
0
XP
546
Country
United States
Just a heads up to people planning to use these scraper scripts: Try not to use my SSL tunnel and instead simply ignore invalid SSL certs. I don't want it getting blocked.
 

Pikachu025

Well-Known Member
Member
Joined
May 3, 2006
Messages
972
Trophies
0
Age
33
Location
Austria
XP
396
Country
Australia
Jam with the Band has a per game card unique key or something. From what I've read, each one is only allowed so many downloads.

I don't think this is correct as I just dumped my cartridge and it matches the no-intro datfile. It's probably handled by the save file in some way. I'll put up some packet dumps in a second.

Also, if anyone wants to help me save the DLC before the servers go down, I need the arm9.bin and/or overlay files from each rom (including different regions possibly). Please give the exact filename of the ROM it came from, and/or the unique game code (such as AJUJ for Jump Ultimate Stars).
Anything from this list would help: http://gbatemp.net/threads/preserving-ds-saves-with-the-dlc-flags-unlocked.362667/
What exactly do you need, something from this block of strings here?

046mzwy.png


I'm not exactly comfortable sending around executable DS code, but if that part is all you need I can scrape that from all my games.
 

Toad King

Well-Known Member
OP
Member
Joined
Aug 19, 2009
Messages
374
Trophies
0
XP
546
Country
United States
Also a note that not all games use the same request API. SSB:B has a separate list of parameters it needs to send. (I'm not sure how important they are for SSB:B but other Wii games probably do something similar.)
 

windwakr

Well-Known Member
Member
Joined
Sep 13, 2009
Messages
502
Trophies
1
Website
windwakr.github.io
XP
1,792
Country
United States
There is no real standardized way of how things are stored so you just have to find the wifi code. Searching for "/download" works well because that's the URL for want to use. If the ROM doesn't have "/download" in it anywhere, it most likely uses something different for DLC if it even has any at all. So you just have to recognize what the 4 letter game code is, and figure out what the 16 byte download key is. The game code near the secret key is not always the same as the game code at 0x0c, but they are related. Also, the secret key is not always near the game code, so you have to search around sometimes.

Seriously? I just finished a script to extract/decompress the arm9/overlays from ROMs and find the keys. But it only works for finding "0x00, gamecode, 0x00, 0x00, 0x00, 0x00, key". Ugh.


Also, I found one key that doesn't work for me. Could you take a look at it?
Code:
ABZE CYfEUP7gQSb9cZxN "Bleach - Dark Souls (U)"
It's in overlay 26.
 

Toad King

Well-Known Member
OP
Member
Joined
Aug 19, 2009
Messages
374
Trophies
0
XP
546
Country
United States
I'm pretty sure either I'm IP banned or my userid/passwd got banned because I haven't been able to download anything for a few hours, so I can't help you with that.
If you were using my SSL tunnel, I disabled it for the download server since I didn't want it banned. You should be able to do it without a tunnel, and just do it over HTTPS without verifying the certificate.
 

Pikachu025

Well-Known Member
Member
Joined
May 3, 2006
Messages
972
Trophies
0
Age
33
Location
Austria
XP
396
Country
Australia
After experimenting with this a bit, it seems actually more consistent to scrape for the gamecode without the last letter and check that your resulting string has four characters before the null byte, you'll get a couple of false positives but that's better than missing keys. The only ones I didn't catch with that are the Pokemon keys that use the other version's game code (well, as far as I know, at least).

I've kinda bastardized that SSL patcher from earlier (sorry!) for this but here you go, this searches the executable code for exactly what I mentioned, notifies you and halts when it finds it, and puts a decompressed file out for you to examine, then when you press anything in the program it proceeds.
 

Attachments

  • ScrapeNdsWifi.zip
    132.6 KB · Views: 263

Pikachu025

Well-Known Member
Member
Joined
May 3, 2006
Messages
972
Trophies
0
Age
33
Location
Austria
XP
396
Country
Australia
Alright, how about this instead? This just copies out the files it finds the gamecode in. So "ScrapeNdsWifi pokewhite.nds" copies out pokewhite_Overlay9_121.bin, pokewhite_Overlay9_123.bin and pokewhite_Overlay9_175.bin to look at.

e: See two posts below.
 

Pikachu025

Well-Known Member
Member
Joined
May 3, 2006
Messages
972
Trophies
0
Age
33
Location
Austria
XP
396
Country
Australia
A picky one, aren't we? Haha, nah, it's okay. This also fixes the exception that happens when running the program twice on the same file.
 

Attachments

  • ScrapeNdsWifi.zip
    132.8 KB · Views: 271
  • Like
Reactions: pleonex

Pikachu025

Well-Known Member
Member
Joined
May 3, 2006
Messages
972
Trophies
0
Age
33
Location
Austria
XP
396
Country
Australia
Also here's a modified downloader that can read that gamecode/key file format: http://pastebin.com/geYfa4h9
Put a nwfcdlc.txt containing the code/key data next to the python file, then run the file. Downloads everything from that file in order.

This also fixes a few errors I encountered, such as it downloading a maximum of 1024 files (Japanese WarioWare DIY has more, somehow) and it failing when a folder with 0 files is encountered (several Pokemon games, I assume they had data at some point).
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: Like for micro