cleaninty ctr EShopDelete -C soap_target.json
(first eshopregionchange had wrong file name) |
(MMM is dead, long live MM!) |
||
(6 intermediate revisions by 3 users not shown) | |||
Line 10: | Line 10: | ||
| forlinux = 1 | | forlinux = 1 | ||
}} | }} | ||
'''cleaninty''' is a PC tool used to communicate with Nintendo's [[wikipedia:SOAP|SOAP]] servers. For a 3DS, these servers deal with managing eShop accounts, downloading eShop titles, and system transfers. It is also the tool used for what is informally known as a "SOAP | '''cleaninty''' is a PC tool used to communicate with Nintendo's [[wikipedia:SOAP|SOAP]] servers. For a 3DS, these servers deal with managing eShop accounts, downloading eShop titles, and system transfers. It is also the tool used for what is informally known as a "SOAP transfer". | ||
== Overview == | == Overview == | ||
There are two | There are two pieces of data a 3DS that give it a unique ID to Nintendo's eShop servers: its serial number and its [[3DS:System files|<code>otp.bin</code>]]. If these are copied out of the console and used somewhere else, they can be used to imitate the console - meaning Nintendo's servers can act on commands without the console doing anything on its end.<br> | ||
However, the files cannot communicate on their own, and a connection to Nintendo's servers that acts identically to a console is still needed. | However, the files cannot communicate on their own, and a connection to Nintendo's servers that acts identically to a console is still needed. This part is where cleaninty comes in. | ||
The reason this allows for changing eShop regions easily, and at infinite range, are as follows: | The reason this allows for changing eShop regions easily, and at infinite range, are as follows: | ||
* '''Ease of Use''': Tickets for both system software & purchased apps are stored on Nintendo's servers, and some of these tickets are | * '''Ease of Use''': Tickets for both system software & purchased apps are stored on Nintendo's servers, and some of these tickets are region-locked - meaning their presence blocks the console from registering to any other eShop region. (The most common of these tickets are from preinstalled games and the [[3dbrew:StreetPass Mii Plaza|Mii Plaza 3.x]] update.) The only way to remove these tickets is to transfer them to another console, and cleaninty is able to move ''only'' the tickets with a single command. | ||
* '''Infinite Range:''' System transfers are effectively divided into two parts: the content transfer (done entirely on consoles), and the NNID/title transfer (done entirely on servers).<br>On an actual console, these two must be done at the same time - but if cleaninty sends the commands for a server transfer, the consoles | * '''Infinite Range:''' System transfers are effectively divided into two parts: the content transfer (done entirely on consoles), and the NNID/title transfer (done entirely on servers).<br>On an actual console, these two must be done at the same time - but if cleaninty sends the commands for a server transfer, it doesn't start a content transfer and thus the consoles do not have to be next to each other. (Technically, this also means a [[3DS:MM|Movable Moveover]] is the exact opposite of a SOAP transfer.) | ||
== Features == | == Features == | ||
When | When the required constants have been supplied through <code>SetupConstants</code> and you have the unique data (<code>otp.bin</code> and either <code>SecureInfo.bin</code> or the serial number) of a console, cleaninty can act as that console and do the following: | ||
* <code>GenJson</code>: Compiles the console's data into a single JSON file. This JSON is required for all other commands except <code>RecoverIVS</code>. | * <code>GenJson</code>: Compiles the console's data into a single JSON file. This JSON is required for all other commands except <code>RecoverIVS</code>. | ||
* <code>CheckReg</code>: Obtains the console's eShop status and any titles attached to its eShop account, then updates the JSON file if any differences in the data are found. | * <code>CheckReg</code>: Obtains the console's eShop status, eShop region, and any titles attached to its eShop account, then updates the JSON file if any differences in the data are found. | ||
* <code>SysTransfer</code>: Moves the eShop titles of the source console to the target console. This is the | * <code>SysTransfer</code>: Moves the eShop titles of the source console to the target console. This is the only part of a SOAP transfer if the console has region-locked tickets, as it will do an <code>EShopDelete</code> as part of the transfer. | ||
** A successful use of this command triggers a 7-day cooldown on system transfers for both consoles, the same as a full system transfer. | ** A successful use of this command triggers a 7-day cooldown on system transfers for both consoles, the same as a full system transfer. | ||
* <code>NNIDTransfer</code>: <u>(Still experimental. Use with caution.)</u> Moves only the NNIDs of the source console to the target console. This is not affected by system transfer cooldowns and does not trigger one. | * <code>NNIDTransfer</code>: <u>(Still experimental. Use with caution.)</u> Moves only the NNIDs of the source console to the target console. This is not affected by system transfer cooldowns and does not trigger one. | ||
* <code>LastTransfer</code>: Provides the date&time of the given console's last system transfer, the number of transfers it has ever done, and the time at which the current transfer cooldown will expire if there is one active. | * <code>LastTransfer</code>: Provides the date&time of the given console's last system transfer, the number of transfers it has ever done, and the time at which the current transfer cooldown will expire if there is one active. | ||
* <code>GetIVS</code>: | * <code>GetIVS</code>: Downloads the console's <code>movable.sed</code> from the SOAP servers, if the servers have a stored copy. | ||
* <code>SetIVS</code>: Uploads the chosen JSON's stored <code>movable.sed</code> to the SOAP servers. This will overwrite the current stored movable. | * <code>SetIVS</code>: Uploads the chosen JSON's stored <code>movable.sed</code> to the SOAP servers. This will overwrite the current stored movable. | ||
* <code>RecoverIVS</code>: Tries to recover a console's <code>movable.sed</code> from only its raw <code>otp.bin</code> and eShop region data. | * <code>RecoverIVS</code>: Tries to recover a console's <code>movable.sed</code> from only its raw <code>otp.bin</code> and eShop region data. | ||
* <code>EShopDelete</code>: Deletes the target console's eShop account. | * <code>EShopDelete</code>: Deletes the target console's eShop account. This is the secondary part of a SOAP transfer, as the console will then automatically register an account in the correct region when it next accesses the eShop. | ||
* <code>EShopRegionChange</code>: Attempts to delete and then recreate the target console's eShop account for the entered region. This is the main part of a | * <code>EShopRegionChange</code>: Attempts to delete and then recreate the target console's eShop account for the entered region. This is the main part of a SOAP transfer if the console has no region-locked tickets, but an <code>EShopDelete</code> should still be done afterward. | ||
* <code>ETickets</code>/<code>ETicketDownload</code>/<code>ETikTitleDownload</code>: Lists all owned eShop tickets / downloads all tickets / downloads the titles attached to all tickets, respectively, from the given console's eShop account. | * <code>ETickets</code>/<code>ETicketDownload</code>/<code>ETikTitleDownload</code>: Lists all owned eShop tickets / downloads all tickets / downloads the titles attached to all tickets, respectively, from the given console's eShop account. | ||
Line 44: | Line 44: | ||
Instructions for installation & setup are {{GitHub|luigoalma/cleaninty#Installing|on the GitHub page}}, but the installation instructions may need to be interpreted for your OS. | Instructions for installation & setup are {{GitHub|luigoalma/cleaninty#Installing|on the GitHub page}}, but the installation instructions may need to be interpreted for your OS. | ||
{{critical|The AES Constant, along with all other constants used by cleaninty, are copyrighted data. Obtaining them from your own console is fine, but '''do not''' share the constants with anyone else.}} | Regardless of your OS, you will need a 3DS with both custom firmware and [[3DS:GodMode9|GodMode9]] installed to dump all of the files required to do <code>SetupConstants</code>. The vast majority of them are dumped using [https://raw.githubusercontent.com/luigoalma/cleaninty/master/gm9scripts/ExtractSystemElements.gm9 ExtractSystemElements.gm9], but the the [[wikipedia:Advanced_Encryption_Standard|AES]] Constant "C" is found using the full set of instructions [https://3ds.goombi.fr/convertMii/0x31.html on this page]. | ||
{{critical|The AES Constant, along with all other constants used by cleaninty, are copyrighted data. Obtaining them from your own console(s) is fine, but '''do not''' share the constants with anyone else.}} | |||
{{info|These constants are the same on all consoles. Once one set is dumped, you will not need to redump in the future unless you lose access to them.}} | |||
=== Windows === | === Windows === | ||
Don't bother trying to | Don't bother trying to install cleaninty on Windows directly. Windows has OpenSSL disabled in its <code>curl.exe</code>, but cleaninty requires OpenSSL to function. Working around this issue manually is obnoxious and not worth the time spent. | ||
Instead, there are two options: | Instead, there are two options: | ||
# Install a Linux distro through [https://learn.microsoft.com/en-us/windows/wsl/install WSL] and then install cleaninty inside the WSL instance using the macOS/Linux instructions. | # Install a Linux distro through [https://learn.microsoft.com/en-us/windows/wsl/install WSL] and then install cleaninty inside the WSL instance using the macOS/Linux instructions. (This is the simpler path, and WSL is useful for many other things. If you choose this instead of msys2, it is recommended that you also install the {{GitHub|microsoft/terminal|Windows Terminal}}.) | ||
# Install [https://www.msys2.org/ msys2] and then install cleaninty inside the msys2 instance using the below instructions. | # Install [https://www.msys2.org/ msys2] and then install cleaninty inside the msys2 instance using the below instructions. | ||
Line 58: | Line 60: | ||
* <code>python -m pip install cleaninty</code> | * <code>python -m pip install cleaninty</code> | ||
Once this is completed, from here on out you will need to open the | Once this is completed, from here on out you will need to open the msys2 <code>mingw64.exe</code> terminal to use cleaninty. | ||
{{info|Be aware that when using cleaninty through msys2, the place it will look in to find <code>boot9.bin</code>, <code>SSLCertificates</code>, and <code>ctr_constants.json</code> is a folder named <code>3ds</code> inside your msys2 <code>home</code> folder.}} | {{info|Be aware that when using cleaninty through msys2, the place it will look in to find <code>boot9.bin</code>, <code>SSLCertificates</code>, and <code>ctr_constants.json</code> is a folder named <code>3ds</code> inside your msys2 <code>home</code> folder.}} | ||
Line 64: | Line 66: | ||
=== macOS and Linux === | === macOS and Linux === | ||
First, ensure you have | First, ensure you have Python 3.7 or newer. You can check if your Python version is new enough by opening a terminal and running the command <code>python3 --version</code>. If you do not, install a compatible version from either your package manager or [https://www.python.org/downloads/ the Python website]. | ||
Then, either install cleaninty directly from <code>pip</code> or clone its repo via the command <code>git clone https://github.com/luigoalma/cleaninty.git</code> and then run the <code>setup.py</code> script. | |||
== Usage == | |||
{{critical|Make sure the files for all consoles you compile into a json are accurate before using them in cleaninty, or else the commands may affect a different console than they "should be". | |||
The easiest way to do this is by checking the serial sticker(s) on the console against the copy of the serial in [[3dbrew:Nandrw/sys/SecureInfo_A|SecureInfo_A]].<br> | |||
If none of the stickers agree with the SecureInfo, also check against the copy in [[3dbrew:Twln/sys/log/inspect.log|inspect.log]] and make sure its listed MAC Address matches the one in '''System Settings -> Internet Settings -> Other Information -> Confirm MAC Address.'''}} | |||
There is no graphical interface for cleaninty. All commands are ran through the command line. | There is no graphical interface for cleaninty. All commands are ran through the command line. | ||
=== | === Manual command line === | ||
The commands are the same on all operating systems. Run <code>cleaninty ctr (command) --help</code> for information on an individual command's syntax. | The commands are the same on all operating systems. Run <code>cleaninty ctr (command) --help</code> for information on an individual command's syntax. | ||
Line 84: | Line 88: | ||
# <code>cleaninty ctr CheckReg -C soap_donor.json</code> | # <code>cleaninty ctr CheckReg -C soap_donor.json</code> | ||
# <code>cleaninty ctr CheckReg -C soap_target.json</code> | # <code>cleaninty ctr CheckReg -C soap_target.json</code> | ||
#* The CheckReg commands are not necessary if you are already certain the donor and target | #* The CheckReg commands are not necessary if you are already certain the donor and target have the same region. | ||
# <code>cleaninty ctr EShopRegionChange -C soap_target.json -r ( | # <code>cleaninty ctr EShopRegionChange -C soap_target.json -r (eShop region) -c (eShop country - not required if region is JPN/KOR/CHN)</code> | ||
#* | #* You can use any region/country for this command other than the one listed in the <code>soap_target.json</code>'s <code>CheckReg</code>. | ||
# Depending on whether the EShopRegionChange was successful or not, only do '''one''' of the following commands. | |||
<tabber> | |||
|-|Succeeded= | |||
<ol> | |||
<li value="7"><code>cleaninty ctr EShopDelete -C soap_target.json</code></li> | |||
</ol> | |||
|-|Failed= | |||
<ol> | |||
<li value="7"><code>cleaninty ctr SysTransfer -s soap_target.json -t soap_donor.json</code></li> | |||
</ol> | |||
</tabber> | |||
=== Autosoap script === | |||
If you are inexperienced with the command line or just don't want to type the commands manually every time, there is a {{GitHub|StarlitSkies/autosoap|SOAP bash script}} made by StarlitSkies that heavily simplifies the process. | |||
Read the instructions on its page for setup and usage. | |||
[[Category:Nintendo 3DS guides]] | [[Category:Nintendo 3DS guides]] |
Latest revision as of 01:27, 19 November 2024
Developer(s) | luigoalma |
---|---|
Platform | Microsoft Windows, macOS, Linux |
Version | 0.1.3 (March 18, 2023 | )
Links | |
GitHub | luigoalma/cleaninty |
Download | |
cleaninty is a PC tool used to communicate with Nintendo's SOAP servers. For a 3DS, these servers deal with managing eShop accounts, downloading eShop titles, and system transfers. It is also the tool used for what is informally known as a "SOAP transfer".
Overview
There are two pieces of data a 3DS that give it a unique ID to Nintendo's eShop servers: its serial number and its otp.bin
. If these are copied out of the console and used somewhere else, they can be used to imitate the console - meaning Nintendo's servers can act on commands without the console doing anything on its end.
However, the files cannot communicate on their own, and a connection to Nintendo's servers that acts identically to a console is still needed. This part is where cleaninty comes in.
The reason this allows for changing eShop regions easily, and at infinite range, are as follows:
- Ease of Use: Tickets for both system software & purchased apps are stored on Nintendo's servers, and some of these tickets are region-locked - meaning their presence blocks the console from registering to any other eShop region. (The most common of these tickets are from preinstalled games and the Mii Plaza 3.x update.) The only way to remove these tickets is to transfer them to another console, and cleaninty is able to move only the tickets with a single command.
- Infinite Range: System transfers are effectively divided into two parts: the content transfer (done entirely on consoles), and the NNID/title transfer (done entirely on servers).
On an actual console, these two must be done at the same time - but if cleaninty sends the commands for a server transfer, it doesn't start a content transfer and thus the consoles do not have to be next to each other. (Technically, this also means a Movable Moveover is the exact opposite of a SOAP transfer.)
Features
When the required constants have been supplied through SetupConstants
and you have the unique data (otp.bin
and either SecureInfo.bin
or the serial number) of a console, cleaninty can act as that console and do the following:
GenJson
: Compiles the console's data into a single JSON file. This JSON is required for all other commands exceptRecoverIVS
.CheckReg
: Obtains the console's eShop status, eShop region, and any titles attached to its eShop account, then updates the JSON file if any differences in the data are found.SysTransfer
: Moves the eShop titles of the source console to the target console. This is the only part of a SOAP transfer if the console has region-locked tickets, as it will do anEShopDelete
as part of the transfer.- A successful use of this command triggers a 7-day cooldown on system transfers for both consoles, the same as a full system transfer.
NNIDTransfer
: (Still experimental. Use with caution.) Moves only the NNIDs of the source console to the target console. This is not affected by system transfer cooldowns and does not trigger one.LastTransfer
: Provides the date&time of the given console's last system transfer, the number of transfers it has ever done, and the time at which the current transfer cooldown will expire if there is one active.GetIVS
: Downloads the console'smovable.sed
from the SOAP servers, if the servers have a stored copy.SetIVS
: Uploads the chosen JSON's storedmovable.sed
to the SOAP servers. This will overwrite the current stored movable.RecoverIVS
: Tries to recover a console'smovable.sed
from only its rawotp.bin
and eShop region data.EShopDelete
: Deletes the target console's eShop account. This is the secondary part of a SOAP transfer, as the console will then automatically register an account in the correct region when it next accesses the eShop.EShopRegionChange
: Attempts to delete and then recreate the target console's eShop account for the entered region. This is the main part of a SOAP transfer if the console has no region-locked tickets, but anEShopDelete
should still be done afterward.ETickets
/ETicketDownload
/ETikTitleDownload
: Lists all owned eShop tickets / downloads all tickets / downloads the titles attached to all tickets, respectively, from the given console's eShop account.
Installation
Instructions for installation & setup are on the GitHub page, but the installation instructions may need to be interpreted for your OS.
Regardless of your OS, you will need a 3DS with both custom firmware and GodMode9 installed to dump all of the files required to do SetupConstants
. The vast majority of them are dumped using ExtractSystemElements.gm9, but the the AES Constant "C" is found using the full set of instructions on this page.
The AES Constant, along with all other constants used by cleaninty, are copyrighted data. Obtaining them from your own console(s) is fine, but do not share the constants with anyone else. |
These constants are the same on all consoles. Once one set is dumped, you will not need to redump in the future unless you lose access to them. |
Windows
Don't bother trying to install cleaninty on Windows directly. Windows has OpenSSL disabled in its curl.exe
, but cleaninty requires OpenSSL to function. Working around this issue manually is obnoxious and not worth the time spent.
Instead, there are two options:
- Install a Linux distro through WSL and then install cleaninty inside the WSL instance using the macOS/Linux instructions. (This is the simpler path, and WSL is useful for many other things. If you choose this instead of msys2, it is recommended that you also install the Windows Terminal.)
- Install msys2 and then install cleaninty inside the msys2 instance using the below instructions.
To install cleaninty inside msys2, open the terminal mingw64.exe
that is inside the msys2 installation folder, then run the following two commands one at a time:
pacman -Syu mingw-w64-x86_64-python mingw-w64-x86_64-python-defusedxml mingw-w64-x86_64-python-cryptography mingw-w64-x86_64-python-pycurl
python -m pip install cleaninty
Once this is completed, from here on out you will need to open the msys2 mingw64.exe
terminal to use cleaninty.
Be aware that when using cleaninty through msys2, the place it will look in to find boot9.bin , SSLCertificates , and ctr_constants.json is a folder named 3ds inside your msys2 home folder. |
macOS and Linux
First, ensure you have Python 3.7 or newer. You can check if your Python version is new enough by opening a terminal and running the command python3 --version
. If you do not, install a compatible version from either your package manager or the Python website.
Then, either install cleaninty directly from pip
or clone its repo via the command git clone https://github.com/luigoalma/cleaninty.git
and then run the setup.py
script.
Usage
Make sure the files for all consoles you compile into a json are accurate before using them in cleaninty, or else the commands may affect a different console than they "should be".
The easiest way to do this is by checking the serial sticker(s) on the console against the copy of the serial in SecureInfo_A. |
There is no graphical interface for cleaninty. All commands are ran through the command line.
Manual command line
The commands are the same on all operating systems. Run cleaninty ctr (command) --help
for information on an individual command's syntax.
As an example, the minimum list of commands needed to set up two consoles' data and perform a SOAP transfer between them would be as follows:
cleaninty ctr GenJson --otp otp.bin --secureinfo secinfo.bin --out soap_donor.json
cleaninty ctr GenJson --otp otp1.bin --secureinfo secinfo1.bin --out soap_target.json
cleaninty ctr CheckReg -C soap_donor.json
cleaninty ctr CheckReg -C soap_target.json
- The CheckReg commands are not necessary if you are already certain the donor and target have the same region.
cleaninty ctr EShopRegionChange -C soap_target.json -r (eShop region) -c (eShop country - not required if region is JPN/KOR/CHN)
- You can use any region/country for this command other than the one listed in the
soap_target.json
'sCheckReg
.
- You can use any region/country for this command other than the one listed in the
- Depending on whether the EShopRegionChange was successful or not, only do one of the following commands.
cleaninty ctr SysTransfer -s soap_target.json -t soap_donor.json
Autosoap script
If you are inexperienced with the command line or just don't want to type the commands manually every time, there is a SOAP bash script made by StarlitSkies that heavily simplifies the process.
Read the instructions on its page for setup and usage.