Hacking microSD management on homecreen and working on old3DS's too

daxtsu

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
5,627
Trophies
2
XP
5,194
Country
Antarctica
Child definitely looks to be DLC/Game patch type. Thanks. I might get my custom game patch repacked correctly now. :D

EDIT: What about "Category" under Title ID section? That one doesn't accept Child as the category type... I might try and pack it anyway with just the content type set to child and see if that works.

Looks to be Application, SystemApplication, Firmware, Base, DlpChild, Demo, Contents, SystemContents, AddonContents, Patch, AutoUpdateContents. I'm finding these in makerom's source btw. :P

Edit: You might need category flags too, unsure: Normal, DlpChild, Demo, Contents, AddonContents, Patch, CannotExecution, RequireBatchUpdate, NotRequireUserApproval, NotRequireRightForMount, CanSkipConvertJumpId.
 
  • Like
Reactions: Apache Thunder

gamesquest1

Nabnut
OP
Former Staff
Joined
Sep 23, 2013
Messages
15,153
Trophies
2
XP
12,247
yeah, but the only downfall is system applications cannot be uninstalled :P.....hmmm actually the browser is under the system category and can be uninstalled by dev menu.....probably some other flag too :huh:...oh well i guess there is a slim hope of getting it working perfect XD
 

Apache Thunder

I have cameras in your head!
Member
Joined
Oct 7, 2007
Messages
4,468
Trophies
3
Age
36
Location
Levelland, Texas
Website
www.mariopc.co.nr
XP
6,903
Country
United States
Setting "Catagory Type" under the title ID section to Patch in combination with ContentType to "Child" was enough to get my game patch CIA to be the correct type again. :D

So perhaps setting Content type to "SystemUpdate" and Category type to "SystemApplication" will make it install to NAND. ;)

You can also change Content Type to Application while leaving category type to System Application. Not all system apps likely use the system update flag I would guess. :P

I might experiment with my game patch RSF to see what would be enough to get it to show NAND as the type in DevMan. I won't actually attempt to install it though. :P
 

Searinox

"Dances" with Dragons
Member
Joined
Dec 16, 2007
Messages
2,073
Trophies
1
Age
36
Location
Bucharest
XP
2,203
Country
Romania
Likely the reason for the freeze on new app launch is that the app releases the lock on all microSD files including needed system ones, and since settings were never designed to be able to go back out again without reset, it never restores them on close.
 
  • Like
Reactions: piratesephiroth

piratesephiroth

I wish I could read
Member
Joined
Sep 5, 2013
Messages
3,453
Trophies
2
Age
103
XP
3,234
Country
Brazil
Likely the reason for the freeze on new app launch is that the app releases the lock on all microSD files including needed system ones, and since settings were never designed to be able to go back out again without reset, it never restores them on close.
Nah, I built one myself and other games don't crash at all. It shows that error message but I can run any games ater I use it.

Bye bye, FTP homebrew.
 
  • Like
Reactions: gamesquest1

Apache Thunder

I have cameras in your head!
Member
Joined
Oct 7, 2007
Messages
4,468
Trophies
3
Age
36
Location
Levelland, Texas
Website
www.mariopc.co.nr
XP
6,903
Country
United States
Nah, I built one myself and other games don't crash at all. It shows that error message but I can run any games ater I use it.

Bye bye, FTP homebrew.

Any chance you can PM me the rsf file you used? I want to build one as one as well. What change to the icon file did you have to make?
 

Shadowtrance

Well-Known Member
Member
Joined
May 9, 2014
Messages
2,493
Trophies
0
Location
Hervey Bay, Queensland
XP
1,807
Country
Any chance you can PM me the rsf file you used? I want to build one as one as well. What change to the icon file did you have to make?

Also interested in knowing how to build a working (EUR) version ^^^ :)

Because lets face it, the Ftp homebrews aren't great (not that i can do any better), and it saves the poor sd slot, oh the punishment it takes. haha

Still dunno why nintendo just didn't add it to the old 3ds as well. Or put it on the homescreen by default. Then again why does nintendo do half the things they do? :glare:
 

MattKimura

3DS & WiiU Enthusiast
Member
Joined
Jun 30, 2014
Messages
2,137
Trophies
1
XP
2,939
Country
United States
I hope this works with Chromebook's ChromeOS, Or Ubuntu at least. This has been said a few times before, but goodbye FTPBrony!
If it doesn't work with anything BUT windows, then I'll sadly have to keep using FTPBRony :c
 

Apache Thunder

I have cameras in your head!
Member
Joined
Oct 7, 2007
Messages
4,468
Trophies
3
Age
36
Location
Levelland, Texas
Website
www.mariopc.co.nr
XP
6,903
Country
United States
Here's the details on how I did it:



First I decrypted it. I got the original US cia I downloaded from the other thread from a certain website that already had the icon modified. I converted it to 3DS using Makerom.(use -ciatocci command). Then generate a ncchinfo.bin file for it and generate xorpads using rxTools/Decrypt9 (or the older multitool one for 4.x users). Note that it will bug out and only create a file called "s". This was the romfs xorpad. I'm not sure why this happens but seems to be a bug with system apps.

After that I then decrypt the 3DS file using rxtools title decrypter. This is not the same as generating xorpads. This decrypts everything in the 3DS except the romfs. For some reason romfs on most system apps won't get decrypted correctly. Thats why I created the xorpad. Fortunately, the exheader and exefs are decrypted properly at this stage, so the only xorpad that is generated happens to be the one we need.

I then extract everything from the decrypted 3DS file (I use ctrtool as I don't trust 3DSExplorer to extract the exheader correctly. :P ). Then use padxorer to decrypt the romfs.bin with the xorpad I created. I finally have a decrypted romfs to go along with everything else. You also need to extract the exefs file using ctrtool.

Code:
ctrtool.exe -t exefs --exefsdir=./ExtractedExeFs ExeFS.bin
(make sure you correct the paths if your files are named as something else)


I then used this rsf file I heavily modified for use with this app:

Code:
BasicInfo:
  Title                  : "mcopy000"
  CompanyCode            : "01"
  ProductCode            : "CTR-N-HAJE"
  ContentType            : Application
  Logo                    : Nintendo
 
TitleInfo:
  UniqueId                : 0x200241
  Category                : Application
 
CardInfo:
  MediaSize              : 128MB
  MediaType              : Card1
  CardDevice              : NorFlash
 
Option:
  UseOnSD                : true
  FreeProductCode        : true
  MediaFootPadding        : true
  EnableCrypt            : true
  EnableCompress          : false
 
ExeFs:
  ReadOnly:
  - .rodata
  - RO
  ReadWrite:
  - .data
  - RO
  Text:
  - .init
  - .text
  - STUP_ENTRY
 
PlainRegion:
- .module_id
 
AccessControlInfo:
  ExtSaveDataId: 0x010200241
  SystemSaveDataId1: 0x00000000
  SystemSaveDataId2: 0x00000000
  OtherUserSaveDataId1: 0x00000
  OtherUserSaveDataId2: 0x00000
  OtherUserSaveDataId3: 0x00000
  UseOtherVariationSaveData : false
 
  FileSystemAccess:
    - Debug
    - DirectSdmc
    - DirectSdmcWrite
  IdealProcessor                : 0
  AffinityMask                  : 1
  Priority                      : 16
 
  SystemCallAccess:
    ArbitrateAddress: 34
    Break: 60
    CancelTimer: 28
    ClearEvent: 25
    ClearTimer: 29
    CloseHandle: 35
    ConnectToPort: 45
    ControlMemory: 1
    CreateAddressArbiter: 33
    CreateEvent: 23
    CreateMemoryBlock: 30
    CreateMutex: 19
    CreateSemaphore: 21
    CreateThread: 8
    CreateTimer: 26
    DuplicateHandle: 39
    ExitProcess: 3
    ExitThread: 9
    GetCurrentProcessorNumber: 17
    GetHandleInfo: 41
    GetProcessId: 53
    GetProcessIdOfThread: 54
    GetProcessIdealProcessor: 6
    GetProcessInfo: 43
    GetResourceLimit: 56
    GetResourceLimitCurrentValues: 58
    GetResourceLimitLimitValues: 57
    GetSystemInfo: 42
    GetSystemTick: 40
    GetThreadContext: 59
    GetThreadId: 55
    GetThreadIdealProcessor: 15
    GetThreadInfo: 44
    GetThreadPriority: 11
    MapMemoryBlock: 31
    OutputDebugString: 61
    QueryMemory: 2
    ReleaseMutex: 20
    ReleaseSemaphore: 22
    SendSyncRequest1: 46
    SendSyncRequest2: 47
    SendSyncRequest3: 48
    SendSyncRequest4: 49
    SendSyncRequest: 50
    SetThreadPriority: 12
    SetTimer: 27
    SignalEvent: 24
    SleepThread: 10
    UnmapMemoryBlock: 32
    WaitSynchronization1: 36
    WaitSynchronizationN: 37
  InterruptNumbers:
  ServiceAccessControl:
  - $hioFIO
  - $hostio0
  - $hostio1
  - cfg:u
  - fs:USER
  - gsp::Gpu
  - hid:USER
  - ndm:u
  - pxi:dev
  - APT:A
  - ac:i
  - dsp::DSP
  - ptm:u
  - soc:U
  - ssl:C
 
SystemControlInfo:
  SaveDataSize: 256KB
  RemasterVersion: 0000
  StackSize: 0x000004000

Then I used this command to pack the CXI file. Do NOT try and pack direct to CIA. I used make_cia to pack at a later stage and you need to reinject the exheader on the rebuilt CXI:

Code:
makerom -f ncch -target g -rsf mCopy2.rsf -desc app:7 -exefslogo -romfs mCopy\romfs.bin -exheader mCopy\exheader.bin -code mCopy\code.bin -icon mCopy\icon.bin -banner mCopy\banner.bin -logo mCopy\logo.bin -alignwr -o mCopy.cxi

Change paths to match where you extracted your files.

Then the important part. You need to reinject the exheader.bin file into the new CXI file using ExInjector! If you don't do this, it will freeze if you try to boot it once you have it installed.
wink.png


Once that's done, it's ready to be built as a CIA. Built it with make_cia using this command:

Code:
make_cia -o mSDManagement_US.cia --major=0 --minor=0 --micro=5 --content0=mCopy.cxi --id_0=375c5171

id_0 should be changed to match the file name the .app file has when you installed the original version from your region (minus the .app part). The USA one gets installed to a file with that ID on my SD card, so I chose to use that to make sure everything matched up. But other regions might use different IDs. Just go to your SD card and find where you had the original installed to see what the filename is. That will be the ID you pack it as with make_cia. This probably doesn't matter and you can just set it to 00000000, but I did this to make sure everythine was 1:1 with the way the original one was installed. Of coarse you need to uninstall the original before you can install the new one.

That's it. You now repacked your customize version of MicroSD Management. I can't do this banner mod to the other region CIAs because I don't have other region consoles to test them on. This app is picky and won't run on the region it wasn't designed for. So US version will only boot on US consoles and the same applies to Japan/Europe versions.


Perhaps someone can also tweak the code.bin file so it doesn't crash when you exit it.
wink.png


I invite others to extract the banner and use it on the two other region CIAs currently available.
wink.png
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • K3Nv2 @ K3Nv2:
    why
  • Xdqwerty @ Xdqwerty:
    @K3Nv2, it's not funny
  • K3Nv2 @ K3Nv2:
    ok
  • BigOnYa @ BigOnYa:
    Wut?
  • K3Nv2 @ K3Nv2:
    That's not funny
    +2
  • Psionic Roshambo @ Psionic Roshambo:
    So two cannibals where eating a clown and one says to the other. Hey does this taste funny to you?
    +2
  • K3Nv2 @ K3Nv2:
    What do you call a slow car? Retired
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    Did you hear about the police car that someone stole the wheels off of? The police are working tirelessly to find the thieves.
    +2
  • K3Nv2 @ K3Nv2:
    A firefighter got arrested for assault his main claim was what I was told he was on fire
    +2
  • BigOnYa @ BigOnYa:
    What do you call a hooker with a runny nose? Full
    +2
  • Psionic Roshambo @ Psionic Roshambo:
    What do you tell a woman with two black eyes? Nothing you already told her twice!
  • K3Nv2 @ K3Nv2:
    Diddy also works
  • K3Nv2 @ K3Nv2:
    A scientist heard the word batman so he put a naked lady in a cage with a bat
  • Psionic Roshambo @ Psionic Roshambo:
    Chuck Norris won a staring contest, with the sun.
  • K3Nv2 @ K3Nv2:
    A vampires favorite thing to do is moon you
  • BigOnYa @ BigOnYa:
    What's the difference between an airplane, and Ken's mom? Not everyone has been in an airplane.
  • K3Nv2 @ K3Nv2:
    What's the difference between @BigOnYa and his wife? Nothing both want to bone me
    +3
  • RedColoredStars @ RedColoredStars:
    How much wood could a wood chuck chuck if a wood chuck could chuck norris
    +1
  • BakerMan @ BakerMan:
    how do i know? you're a guy, and he wants to bone every guy on this site (maybe, idk)
    +1
  • K3Nv2 @ K3Nv2:
    He wants to bone anything with a dick
    +1
  • Xdqwerty @ Xdqwerty:
    Good night
    +1
  • BigOnYa @ BigOnYa:
    Nighty night, big day tomorrow. Congrats.
    K3Nv2 @ K3Nv2: https://www.instagram.com/reel/C7iLZ35NrQt/?igsh=MWd2Z3U0dmNlMmNxcw==