#define DUMP_NSP_CRC_WAIT 5 // The user must wait for at least DUMP_NSP_CRC_WAIT seconds before the CRC32 checksum calculation process starts after the NSP dump process is finished
typedefstruct{
boolkeepCert;// Original value for the "Keep certificate" option. Overrides the selected setting in the current session
booltrimDump;// Original value for the "Trim output dump" option. Overrides the selected setting in the current session
u32certCrc;// CRC32 checksum accumulator (XCI with cert). Only used if calcCrc == true and keepCert == true
u32certlessCrc;// CRC32 checksum accumulator (certless XCI). Only used if calcCrc == true
}PACKEDsequentialXciCtx;
typedefstruct{
FsStorageIdstorageId;// Source storage from which the data is dumped
boolremoveConsoleData;// Original value for the "Remove console specific data" option. Overrides the selected setting in the current session
booltiklessDump;// Original value for the "Generate ticket-less dump" option. Overrides the selected setting in the current session. Ignored if removeConsoleData == false
Sha256ContexthashCtx;// Current NCA SHA-256 checksum context. Only used when dealing with the same NCA between different parts
u8programNcaHeaderMod[NCA_FULL_HEADER_LENGTH];// Modified + reencrypted Program NCA header. Only needed if the NPDM signature in the Program NCA header is replaced (it uses cryptographically secure random numbers). The RSA public key used in the ACID section from the main.npdm file is constant, so we don't need to keep track of that