Changes

Jump to navigation Jump to search
12,842 bytes added ,  20:22, 28 February 2020
Line 76: Line 76:  
| 9 || MoveApplicationEntity
 
| 9 || MoveApplicationEntity
 
|-
 
|-
| 11 || CalculateApplicationOccupiedSize
+
| 11 || [[#CalculateApplicationOccupiedSize]]
 
|-
 
|-
 
| 16 || PushApplicationRecord
 
| 16 || PushApplicationRecord
Line 122: Line 122:  
| 42 || CleanupSdCard
 
| 42 || CleanupSdCard
 
|-
 
|-
| 43 || CheckSdCardMountStatus
+
| 43 || [[#CheckSdCardMountStatus]]
 
|-
 
|-
 
| 44 || GetSdCardMountStatusChangedEvent
 
| 44 || GetSdCardMountStatusChangedEvent
Line 212: Line 212:  
| 504 || [2.0.0+] RequestRegisterGameCard
 
| 504 || [2.0.0+] RequestRegisterGameCard
 
|-
 
|-
| 600 || [2.0.0+] CountApplicationContentMeta
+
| 600 || [2.0.0+] [[#CountApplicationContentMeta]]
 
|-
 
|-
 
| 601 || [2.0.0+] [[#ListApplicationContentMetaStatus]]
 
| 601 || [2.0.0+] [[#ListApplicationContentMetaStatus]]
Line 226: Line 226:  
| 700 || [2.0.0+] PushDownloadTaskList
 
| 700 || [2.0.0+] PushDownloadTaskList
 
|-
 
|-
| 701 || [2.0.0+] ClearTaskStatusList
+
| 701 || [2.0.0+] [[#ClearTaskStatusList]]
 
|-
 
|-
| 702 || [2.0.0+] RequestDownloadTaskList
+
| 702 || [2.0.0+] [[#RequestDownloadTaskList]]
 
|-
 
|-
| 703 || [2.0.0+] RequestEnsureDownloadTask
+
| 703 || [2.0.0+] [[#RequestEnsureDownloadTask]]
 
|-
 
|-
| 704 || [2.0.0+] ListDownloadTaskStatus
+
| 704 || [2.0.0+] [[#ListDownloadTaskStatus]]
 
|-
 
|-
 
| 705 || [2.0.0+] RequestDownloadTaskListData
 
| 705 || [2.0.0+] RequestDownloadTaskListData
Line 479: Line 479:  
| 2 || [[#GetApplicationRecordUpdateSystemEvent]]
 
| 2 || [[#GetApplicationRecordUpdateSystemEvent]]
 
|-
 
|-
| 3 || GetApplicationViewDeprecated
+
| 3 || [[#GetApplicationViewDeprecated]]
 
|-
 
|-
 
| 4 || [[#DeleteApplicationEntity]]
 
| 4 || [[#DeleteApplicationEntity]]
Line 493: Line 493:  
| 9 || [[#MoveApplicationEntity]]
 
| 9 || [[#MoveApplicationEntity]]
 
|-
 
|-
| 11 || CalculateApplicationOccupiedSize
+
| 11 || [[#CalculateApplicationOccupiedSize]]
 
|-
 
|-
 
| 16 || PushApplicationRecord
 
| 16 || PushApplicationRecord
Line 535: Line 535:  
| 42 || [[#CleanupSdCard]]
 
| 42 || [[#CleanupSdCard]]
 
|-
 
|-
| 43 || CheckSdCardMountStatus
+
| 43 || [[#CheckSdCardMountStatus]]
 
|-
 
|-
 
| 44 || [[#GetSdCardMountStatusChangedEvent]]
 
| 44 || [[#GetSdCardMountStatusChangedEvent]]
Line 599: Line 599:  
| 84 || [4.0.0+] GetDynamicCommitEvent
 
| 84 || [4.0.0+] GetDynamicCommitEvent
 
|-
 
|-
| 85 || [4.0.0+] RequestUpdateApplication2
+
| 85 || [4.0.0+] [[#RequestUpdateApplication2]]
 
|-
 
|-
 
| 86 || [4.0.0+] EnableApplicationCrashReport
 
| 86 || [4.0.0+] EnableApplicationCrashReport
Line 625: Line 625:  
| 99 || [8.0.0+] [[#LaunchDevMenu]]
 
| 99 || [8.0.0+] [[#LaunchDevMenu]]
 
|-
 
|-
| 100 || ResetToFactorySettings
+
| 100 || [[#ResetToFactorySettings]]
 
|-
 
|-
| 101 || ResetToFactorySettingsWithoutUserSaveData
+
| 101 || [[#ResetToFactorySettingsWithoutUserSaveData]]
 
|-
 
|-
| 102 || ResetToFactorySettingsForRefurbishment
+
| 102 || [[#ResetToFactorySettingsForRefurbishment]]
 
|-
 
|-
| 103 || [9.1.0+] ResetToFactorySettingsWithPlatformRegion
+
| 103 || [9.1.0+] [[#ResetToFactorySettingsWithPlatformRegion]]
 
|-
 
|-
| 104 || [9.1.0+] ResetToFactorySettingsWithPlatformRegionAuthentication
+
| 104 || [9.1.0+] [[#ResetToFactorySettingsWithPlatformRegionAuthentication]]
 
|-
 
|-
 
| 200 || CalculateUserSaveDataStatistics
 
| 200 || CalculateUserSaveDataStatistics
 
|-
 
|-
| 201 || DeleteUserSaveDataAll
+
| 201 || [[#DeleteUserSaveDataAll]]
 
|-
 
|-
 
| 210 || [[#DeleteUserSystemSaveData]]
 
| 210 || [[#DeleteUserSystemSaveData]]
Line 667: Line 667:  
| 401 || InvalidateAllApplicationControlCache
 
| 401 || InvalidateAllApplicationControlCache
 
|-
 
|-
| 402 || RequestDownloadApplicationControlData
+
| 402 || [[#RequestDownloadApplicationControlData]]
 
|-
 
|-
 
| 403 || GetMaxApplicationControlCacheCount
 
| 403 || GetMaxApplicationControlCacheCount
Line 681: Line 681:  
| 408 || [8.0.0+] [[#ListApplicationIcon]]
 
| 408 || [8.0.0+] [[#ListApplicationIcon]]
 
|-
 
|-
| 502 || RequestCheckGameCardRegistration
+
| 502 || [[#RequestCheckGameCardRegistration]]
 
|-
 
|-
 
| 503 || [[#RequestGameCardRegistrationGoldPoint]]
 
| 503 || [[#RequestGameCardRegistrationGoldPoint]]
Line 699: Line 699:  
| 510 || [9.0.0+] [[#GetGameCardPlatformRegion]]
 
| 510 || [9.0.0+] [[#GetGameCardPlatformRegion]]
 
|-
 
|-
| 600 || CountApplicationContentMeta
+
| 600 || [[#CountApplicationContentMeta]]
 
|-
 
|-
 
| 601 || [[#ListApplicationContentMetaStatus]]
 
| 601 || [[#ListApplicationContentMetaStatus]]
Line 717: Line 717:  
| 700 || PushDownloadTaskList
 
| 700 || PushDownloadTaskList
 
|-
 
|-
| 701 || ClearTaskStatusList
+
| 701 || [[#ClearTaskStatusList]]
 
|-
 
|-
| 702 || RequestDownloadTaskList
+
| 702 || [[#RequestDownloadTaskList]]
 
|-
 
|-
| 703 || RequestEnsureDownloadTask
+
| 703 || [[#RequestEnsureDownloadTask]]
 
|-
 
|-
| 704 || ListDownloadTaskStatus
+
| 704 || [[#ListDownloadTaskStatus]]
 
|-
 
|-
 
| 705 || [[#RequestDownloadTaskListData]]
 
| 705 || [[#RequestDownloadTaskListData]]
Line 765: Line 765:  
| 915 || [9.0.0+] ShowApplicationRecord
 
| 915 || [9.0.0+] ShowApplicationRecord
 
|-
 
|-
| 1000 || RequestVerifyApplicationDeprecated
+
| 1000 || [[#RequestVerifyApplicationDeprecated]]
 
|-
 
|-
 
| 1001 || CorruptApplicationForDebug
 
| 1001 || CorruptApplicationForDebug
 
|-
 
|-
| 1002 || [3.0.0+] RequestVerifyAddOnContentsRights
+
| 1002 || [3.0.0+] [[#RequestVerifyAddOnContentsRights]]
 
|-
 
|-
 
| 1003 || [5.0.0+] [[#RequestVerifyApplication]]
 
| 1003 || [5.0.0+] [[#RequestVerifyApplication]]
Line 811: Line 811:  
| 1700 || ListApplicationDownloadingContentMeta
 
| 1700 || ListApplicationDownloadingContentMeta
 
|-
 
|-
| 1701 || [3.0.0+] GetApplicationView
+
| 1701 || [3.0.0+] [[#GetApplicationView]]
 
|-
 
|-
 
| 1702 || [3.0.0+] GetApplicationDownloadTaskStatus
 
| 1702 || [3.0.0+] GetApplicationDownloadTaskStatus
 
|-
 
|-
| 1703 || [4.0.0+] GetApplicationViewDownloadErrorContext
+
| 1703 || [4.0.0+] [[#GetApplicationViewDownloadErrorContext]]
 
|-
 
|-
| 1704 || [8.0.0+] GetApplicationViewWithPromotionInfo
+
| 1704 || [8.0.0+] [[#GetApplicationViewWithPromotionInfo]]
 
|-
 
|-
 
| 1800 || IsNotificationSetupCompleted
 
| 1800 || IsNotificationSetupCompleted
Line 829: Line 829:  
| 1900 || [3.0.0+] IsActiveAccount
 
| 1900 || [3.0.0+] IsActiveAccount
 
|-
 
|-
| 1901 || [4.0.0+] RequestDownloadApplicationPrepurchasedRights
+
| 1901 || [4.0.0+] [[#RequestDownloadApplicationPrepurchasedRights]]
 
|-
 
|-
 
| 1902 || [5.0.0+] GetApplicationTicketInfo
 
| 1902 || [5.0.0+] GetApplicationTicketInfo
Line 871: Line 871:  
| 2018 || [5.0.0+] [[#GetApplicationDeliveryInfoHash]]
 
| 2018 || [5.0.0+] [[#GetApplicationDeliveryInfoHash]]
 
|-
 
|-
| 2050 || [6.0.0+] GetApplicationRightsOnClient
+
| 2050 || [6.0.0+] [[#GetApplicationRightsOnClient]]
 
|-
 
|-
 
| 2051 || [9.0.0+] InvalidateRightsIdCache
 
| 2051 || [9.0.0+] InvalidateRightsIdCache
Line 925: Line 925:  
| 2352 || [9.0.0+] [[#RequestResolveNoDownloadRightsError]]
 
| 2352 || [9.0.0+] [[#RequestResolveNoDownloadRightsError]]
 
|-
 
|-
| 2400 || [8.0.0+] GetPromotionInfo
+
| 2400 || [8.0.0+] [[#GetPromotionInfo]]
 
|-
 
|-
 
| 2401 || [8.0.0+] CountPromotionInfo
 
| 2401 || [8.0.0+] CountPromotionInfo
Line 952: Line 952:  
==== GetApplicationRecordUpdateSystemEvent ====
 
==== GetApplicationRecordUpdateSystemEvent ====
 
No input, returns an output Event handle with EventClearMode=1.
 
No input, returns an output Event handle with EventClearMode=1.
 +
 +
==== GetApplicationViewDeprecated ====
 +
Takes a type-0x6 output buffer containing an array of [[#ApplicationViewDeprecated]], a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], no output.
 +
 +
On newer system-versions this is the same as [[#GetApplicationView]], except this converts the output from the func called in the loop from [[#ApplicationView]] to [[#ApplicationViewDeprecated]].
    
==== DeleteApplicationEntity ====
 
==== DeleteApplicationEntity ====
Line 972: Line 977:     
The data that can be read from the [[#IAsyncValue]] is [[#ApplicationUpdateInfo]].
 
The data that can be read from the [[#IAsyncValue]] is [[#ApplicationUpdateInfo]].
 +
 +
Before using the cmd, official sw uses [[Network_Interface_services#IsAnyInternetRequestAccepted|IsAnyInternetRequestAccepted]] with the output from [[#Network_Interface_services#GetClientId|GetClientId]], throwing an error when the returned bool is false.
    
==== CancelApplicationDownload ====
 
==== CancelApplicationDownload ====
Line 1,028: Line 1,035:     
This temporarily mounts the [[Filesystem_services#OpenContentStorageFileSystem|ContentStorage]] specified by the StorageId (must be BuiltInUser or SdCard). The two output s64s are the output from [[Filesystem_services#GetTotalSpaceSize|GetTotalSpaceSize]] and [[Filesystem_services#GetFreeSpaceSize|GetFreeSpaceSize]] with this ContentStorage, with it this being unmounted afterwards.
 
This temporarily mounts the [[Filesystem_services#OpenContentStorageFileSystem|ContentStorage]] specified by the StorageId (must be BuiltInUser or SdCard). The two output s64s are the output from [[Filesystem_services#GetTotalSpaceSize|GetTotalSpaceSize]] and [[Filesystem_services#GetFreeSpaceSize|GetFreeSpaceSize]] with this ContentStorage, with it this being unmounted afterwards.
 +
 +
==== RequestUpdateApplication2 ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== LaunchDevMenu ====
 
==== LaunchDevMenu ====
Line 1,039: Line 1,051:     
Then if the above succeeds, the above titles are launched with the above StorageId via [[Process_Manager_services|pmshell]] LaunchProgram, with a 0.5s sleep-thread afterwards on success.
 
Then if the above succeeds, the above titles are launched with the above StorageId via [[Process_Manager_services|pmshell]] LaunchProgram, with a 0.5s sleep-thread afterwards on success.
 +
 +
==== DeleteUserSaveDataAll ====
 +
Takes an input [[Account_services#Uid|Uid]], returns an output [[#IProgressMonitorForDeleteUserSaveDataAll]].
 +
 +
On success, [[#IProgressMonitorForDeleteUserSaveDataAll]] GetProgress is used with the output being copied into object state.
    
==== DeleteUserSystemSaveData ====
 
==== DeleteUserSystemSaveData ====
Line 1,051: Line 1,068:  
==== UnregisterNetworkServiceAccountWithUserSaveDataDeletion ====
 
==== UnregisterNetworkServiceAccountWithUserSaveDataDeletion ====
 
Takes an input [[Account_services#Uid|Uid]], no output.
 
Takes an input [[Account_services#Uid|Uid]], no output.
 +
 +
==== RequestDownloadApplicationControlData ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== ListApplicationTitle ====
 
==== ListApplicationTitle ====
Takes a total of 0x10-bytes of input, a type-0x5 input buffer, an input handle, returns an output Event handle and an [[#IAsyncValue]].
+
Takes an input TransferMemory handle, a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], an u8 [[#ApplicationControlSource]], an u64 size, returns an output Event handle and an [[#IAsyncValue]].
 +
 
 +
[[qlaunch]] uses value 0x1 for the u8.
 +
 
 +
The user-process creates the TransferMemory with permissions=R--.
 +
 
 +
The data available with [[#IAsyncValue]] Get is a s32 for the offset within the TransferMemory where the output data is located, GetSize returns the total byte-size of the data located here. The data located here is the [[NACP_Format|NACP]] title-entry for each specified ApplicationId.
 +
 
 +
The TransferMemory size must be at least: count*sizeof([[NACP_Format|title-entry]]) + count*sizeof(u64) + count*[[#GetApplicationControlData|0x24000]].
 +
 
 +
This is essentially an async wrapper for [[#GetApplicationControlData]], with support for multiple ApplicationIds.
    
==== ListApplicationIcon ====
 
==== ListApplicationIcon ====
Takes a total of 0x10-bytes of input, a type-0x5 input buffer, an input handle, returns an output Event handle and an [[#IAsyncValue]].
+
Takes an input TransferMemory handle, a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], an u8 [[#ApplicationControlSource]], an u64 size, returns an output Event handle and an [[#IAsyncValue]].
 +
 
 +
The user-process creates the TransferMemory with permissions=R--.
 +
 
 +
The data available with [[#IAsyncValue]] Get is a s32 for the offset within the TransferMemory where the output data is located, GetSize returns the total byte-size of the data located here. This data is: an u64 for total entries, an array of u64s for each icon size, then the icon JPEGs for the specified ApplicationIds.
 +
 
 +
The TransferMemory size must be at least: 0x4 + count*sizeof(u64) + count*[[#GetApplicationControlData|0x20000]] + count*sizeof(u64) + [[#GetApplicationControlData|0x24000]].
 +
 
 +
This is essentially an async wrapper for [[#GetApplicationControlData]], with support for multiple ApplicationIds.
 +
 
 +
==== RequestCheckGameCardRegistration ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== RequestGameCardRegistrationGoldPoint ====
 
==== RequestGameCardRegistrationGoldPoint ====
 
Takes an input [[Account_services#Uid|Uid]], an [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncValue]].
 
Takes an input [[Account_services#Uid|Uid]], an [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncValue]].
 +
 +
The data that can be read from the [[#IAsyncValue]] is 4-bytes.
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== RequestRegisterGameCard ====
 
==== RequestRegisterGameCard ====
 
Takes an input s32, an [[Account_services#Uid|Uid]], an [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 
Takes an input s32, an [[Account_services#Uid|Uid]], an [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== GetGameCardMountFailureEvent ====
 
==== GetGameCardMountFailureEvent ====
Line 1,097: Line 1,148:  
==== WithdrawApplicationUpdateRequest ====
 
==== WithdrawApplicationUpdateRequest ====
 
Takes an input [[NCM_services#ApplicationId|ApplicationId]], no output.
 
Takes an input [[NCM_services#ApplicationId|ApplicationId]], no output.
 +
 +
==== RequestVerifyApplicationDeprecated ====
 +
Takes an input TransferMemory handle, an [[NCM_services#ApplicationId|ApplicationId]], an u64 size, returns an output Event handle and an [[#IProgressAsyncResult]].
 +
 +
On newer system-versions this calls the same func as [[#RequestVerifyApplication]], with the u32 value set to 0x7.
 +
 +
==== RequestVerifyAddOnContentsRights ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IProgressAsyncResult]].
    
==== RequestVerifyApplication ====
 
==== RequestVerifyApplication ====
Takes an input TransferMemory handle, an u32, an [[NCM_services#ApplicationId|ApplicationId]], an u64 size, returns an output Event handle and an [[#IAsyncResult]].
+
Takes an input TransferMemory handle, an u32, an [[NCM_services#ApplicationId|ApplicationId]], an u64 size, returns an output Event handle and an [[#IProgressAsyncResult]].
    
Official sw creates the TransferMemory with an user-specified buffer with permissions=0. [[qlaunch]] uses buffer size 0x100000.
 
Official sw creates the TransferMemory with an user-specified buffer with permissions=0. [[qlaunch]] uses buffer size 0x100000.
Line 1,119: Line 1,178:  
==== GetLastSdCardFormatUnexpectedResult ====
 
==== GetLastSdCardFormatUnexpectedResult ====
 
No input/output.
 
No input/output.
 +
 +
==== GetApplicationView ====
 +
Takes a type-0x6 output buffer containing an array of [[#ApplicationView]], a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], no output.
 +
 +
==== GetApplicationViewDownloadErrorContext ====
 +
Takes a type-0x16 output buffer containg an [[Error_Applet#ErrorContext|ErrorContext]], an u64 [[NCM_services#ApplicationId|ApplicationId]], no output.
 +
 +
==== GetApplicationViewWithPromotionInfo ====
 +
Takes a type-0x6 output buffer containing an array of [[#ApplicationViewWithPromotionInfo]], a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], no output.
 +
 +
==== RequestDownloadApplicationPrepurchasedRights ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== GetSystemDeliveryInfo ====
 
==== GetSystemDeliveryInfo ====
Line 1,244: Line 1,317:     
This extracts data from the input array for hashing with SHA256, with validation being done when handling each entry.
 
This extracts data from the input array for hashing with SHA256, with validation being done when handling each entry.
 +
 +
==== GetApplicationRightsOnClient ====
 +
Takes a type-0x6 output buffer containing an array of [[#ApplicationRightsOnClient]], an input u32 flags, an [[NCM_services#ApplicationId|ApplicationId]], an [[Account_services#Uid|Uid]], returns 4-bytes of output for total output entries.
 +
 +
Official sw has at least two wrappers which use this cmd: one with an all-zero Uid, one with an user-specified Uid. With both of these, the passed flags are hard-coded to value 0x3.
 +
 +
For the output array count, [[qlaunch]] uses value 3.
    
==== GetApplicationTerminateResult ====
 
==== GetApplicationTerminateResult ====
Line 1,257: Line 1,337:     
The data that can be read from the [[#IAsyncValue]] is [[#NoDownloadRightsErrorResolution]].
 
The data that can be read from the [[#IAsyncValue]] is [[#NoDownloadRightsErrorResolution]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
    
==== RequestResolveNoDownloadRightsError ====
 
==== RequestResolveNoDownloadRightsError ====
Line 1,262: Line 1,344:     
The data that can be read from the [[#IAsyncValue]] is [[#NoDownloadRightsErrorResolution]].
 
The data that can be read from the [[#IAsyncValue]] is [[#NoDownloadRightsErrorResolution]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
 +
 +
==== GetPromotionInfo ====
 +
Takes a type-0x6 output buffer containing an array of [[#PromotionInfo]], a type-0x5 input buffer containing an array of u64 [[NCM_services#ApplicationId|ApplicationIds]], a type-0x5 input buffer containing an array of [[Account_services#Uid|Uids]], no output.
 +
 +
Official sw uses hard-coded value 1 for the count with each of these arrays.
    
==== ImportPromotionJsonForDebug ====
 
==== ImportPromotionJsonForDebug ====
Line 1,306: Line 1,395:  
| 10 || GetProgress
 
| 10 || GetProgress
 
|}
 
|}
 +
 +
When closing the object, official sw uses IsFinished first, asserting when the output bool is false.
 +
 +
* GetSystemEvent: No input, returns an output Event handle. [[qlaunch]] doesn't use this.
 +
 +
* IsFinished: No input, returns an output u8 bool.
 +
 +
* GetResult: No input/output.
 +
 +
* GetProgress: No input, returns an output [[#ProgressForDeleteUserSaveDataAll]]. Official sw writes this struct directly to object state.
    
=== IProgressAsyncResult ===
 
=== IProgressAsyncResult ===
Line 1,322: Line 1,421:  
| 3 || GetDetailResult
 
| 3 || GetDetailResult
 
|-
 
|-
| 4 || GetErrorContext
+
| 4 || [4.0.0+] GetErrorContext
 
|}
 
|}
   Line 1,358: Line 1,457:  
The data that can be read from the [[#IAsyncValue]] is [[#VersionListData]].
 
The data that can be read from the [[#IAsyncValue]] is [[#VersionListData]].
   −
=== IContentManagerInterface ===
+
=== IContentManagementInterface ===
 
This is "nn::ns::detail::IContentManagementInterface".
 
This is "nn::ns::detail::IContentManagementInterface".
   Line 1,365: Line 1,464:  
! Cmd || Name
 
! Cmd || Name
 
|-
 
|-
| 11 || CalculateApplicationOccupiedSize
+
| 11 || [[#CalculateApplicationOccupiedSize]]
 
|-
 
|-
| 43 || CheckSdCardMountStatus
+
| 43 || [[#CheckSdCardMountStatus]]
 
|-
 
|-
| 47 || GetTotalSpaceSize
+
| 47 || [[#GetTotalSpaceSize]]
 
|-
 
|-
| 48 || GetFreeSpaceSize
+
| 48 || [[#GetFreeSpaceSize]]
 
|-
 
|-
| 600 || CountApplicationContentMeta
+
| 600 || [[#CountApplicationContentMeta]]
 
|-
 
|-
| 601 || ListApplicationContentMetaStatus
+
| 601 || [[#ListApplicationContentMetaStatus]]
 
|-
 
|-
| 605 || ListApplicationContentMetaStatusWithRightsCheck
+
| 605 || [[#ListApplicationContentMetaStatusWithRightsCheck]]
 
|-
 
|-
| 607 || IsAnyApplicationRunning
+
| 607 || [[#IsAnyApplicationRunning]]
 
|}
 
|}
 +
 +
==== CalculateApplicationOccupiedSize ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output [[#ApplicationOccupiedSize]].
 +
 +
==== CheckSdCardMountStatus ====
 +
No input/output.
 +
 +
==== CountApplicationContentMeta ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output s32.
 +
 +
==== ListApplicationContentMetaStatusWithRightsCheck ====
 +
Same input/output as [[#ListApplicationContentMetaStatus]].
 +
 +
==== IsAnyApplicationRunning ====
 +
No input, returns an output u8 bool.
    
=== IDocumentInterface ===
 
=== IDocumentInterface ===
Line 1,403: Line 1,517:  
! Cmd || Name
 
! Cmd || Name
 
|-
 
|-
| 701 || ClearTaskStatusList
+
| 701 || [[#ClearTaskStatusList]]
 
|-
 
|-
| 702 || RequestDownloadTaskList
+
| 702 || [[#RequestDownloadTaskList]]
 
|-
 
|-
| 703 || RequestEnsureDownloadTask
+
| 703 || [[#RequestEnsureDownloadTask]]
 
|-
 
|-
| 704 || ListDownloadTaskStatus
+
| 704 || [[#ListDownloadTaskStatus]]
 
|-
 
|-
 
| 705 || [[#RequestDownloadTaskListData]]
 
| 705 || [[#RequestDownloadTaskListData]]
 
|-
 
|-
| 706 || [4.0.0+] TryCommitCurrentApplicationDownloadTask
+
| 706 || [4.0.0+] [[#TryCommitCurrentApplicationDownloadTask]]
 
|-
 
|-
| 707 || [4.0.0+] EnableAutoCommit
+
| 707 || [4.0.0+] [[#EnableAutoCommit]]
 
|-
 
|-
| 708 || [4.0.0+] DisableAutoCommit
+
| 708 || [4.0.0+] [[#DisableAutoCommit]]
 
|-
 
|-
| 709 || [4.0.0+] TriggerDynamicCommitEvent
+
| 709 || [4.0.0+] [[#TriggerDynamicCommitEvent]]
 
|}
 
|}
   −
=== IReadOnlyApplicationRecordInterface ===
+
==== ClearTaskStatusList ====
This is "nn::ns::detail::IReadOnlyApplicationRecordInterface".
+
No input/output.
 +
 
 +
==== RequestDownloadTaskList ====
 +
No input/output.
 +
 
 +
==== RequestEnsureDownloadTask ====
 +
No input, returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
==== ListDownloadTaskStatus ====
 +
Takes a type-0x6 output buffer containing an array of [[#DownloadTaskStatus]], returns an output s32 total_out.
 +
 
 +
A maximum of 0x100 tasks can be stored in state.
 +
 
 +
==== TryCommitCurrentApplicationDownloadTask ====
 +
No input/output.
 +
 
 +
==== EnableAutoCommit ====
 +
No input/output.
 +
 
 +
==== DisableAutoCommit ====
 +
No input/output.
 +
 
 +
==== TriggerDynamicCommitEvent ====
 +
No input/output.
 +
 
 +
=== IReadOnlyApplicationRecordInterface ===
 +
This is "nn::ns::detail::IReadOnlyApplicationRecordInterface".
    
This was added with [5.0.0+].
 
This was added with [5.0.0+].
Line 1,461: Line 1,601:  
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
! Cmd || Name || Notes
+
! Cmd || Name
 
|-
 
|-
| 0 || [[#RequestApplicationRightsOnServer]] ||
+
| 0 || [[#RequestApplicationRightsOnServer]]
 
|-
 
|-
| 1 || RequestAssignRights ||
+
| 1 || [[#RequestAssignRights]]
 
|-
 
|-
| 4 || DeprecatedRequestAssignRightsToResume ||
+
| 4 || [[#DeprecatedRequestAssignRightsToResume]]
 
|-
 
|-
| 5 || VerifyActivatedRightsOwners ||
+
| 5 || [[#VerifyActivatedRightsOwners]]
 
|-
 
|-
| 6 || DeprecatedGetApplicationRightsStatus ||
+
| 6 || [[#DeprecatedGetApplicationRightsStatus]]
 
|-
 
|-
| 7 || RequestPrefetchForDynamicRights ||
+
| 7 || [[#RequestPrefetchForDynamicRights]]
 
|-
 
|-
| 8 || GetDynamicRightsState ||
+
| 8 || [[#GetDynamicRightsState]]
 
|-
 
|-
| 9 || [7.0.0+] [[#RequestApplicationRightsOnServerToResume]] ||
+
| 9 || [7.0.0+] [[#RequestApplicationRightsOnServerToResume]]
 
|-
 
|-
| 10 || [7.0.0+] RequestAssignRightsToResume ||
+
| 10 || [7.0.0+] [[#RequestAssignRightsToResume]]
 
|-
 
|-
| 11 || [7.0.0+] GetActivatedRightsUsers ||
+
| 11 || [7.0.0+] [[#GetActivatedRightsUsers]]
 
|-
 
|-
| 12 || [8.0.0+] GetApplicationRightsStatus ||
+
| 12 || [8.0.0+] [[#GetApplicationRightsStatus]]
 
|-
 
|-
| 13 || [8.0.0+] GetRunningApplicationStatus ||
+
| 13 || [8.0.0+] [[#GetRunningApplicationStatus]]
 
|}
 
|}
    
==== RequestApplicationRightsOnServer ====
 
==== RequestApplicationRightsOnServer ====
Takes a total of 0x20-bytes of input, returns an output Event handle and an [[#IAsyncValue]].
+
Takes an input [[NCM_services#ApplicationId|ApplicationId]], an [[Account_services#Uid|Uid]] and an u32. Returns an output Event handle and an [[#IAsyncValue]].
 +
 
 +
==== RequestAssignRights ====
 +
Takes a type-0x5 input buffer containing an array of "nn::ns::ApplicationRightsOnServer". Returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
==== DeprecatedRequestAssignRightsToResume ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle" and an [[Account_services#Uid|Uid]]. Returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
==== VerifyActivatedRightsOwners ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle". No output.
 +
 
 +
==== DeprecatedGetApplicationRightsStatus ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle". Returns a bool "nn::ns::ApplicationRightsStatus".
 +
 
 +
==== RequestPrefetchForDynamicRights ====
 +
Takes an input [[Account_services#Uid|Uid]]. Returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
==== GetDynamicRightsState ====
 +
No input. Returns a bool "nn::ns::DynamicRightsState".
    
==== RequestApplicationRightsOnServerToResume ====
 
==== RequestApplicationRightsOnServerToResume ====
Takes a total of 8-bytes of input, returns an output Event handle and an [[#IAsyncValue]].
+
Takes an input u64 "nn::ns::RightsEnvironmentHandle". Returns an output Event handle and an [[#IAsyncValue]].
 +
 
 +
==== RequestAssignRightsToResume ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle". Returns an output Event handle and an [[#IAsyncResult]].
 +
 
 +
==== GetActivatedRightsUsers ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle". Returns a bool, an u32 and a type-0x6 output buffer containing an array of [[Account_services#Uid|Uid]].
 +
 
 +
==== GetApplicationRightsStatus ====
 +
Takes an input "nn::ns::RightsEnvironmentHandle". Returns 2 bools "nn::ns::ApplicationRightsStatus" and "nn::ns::ApplicationLicenseType".
 +
 
 +
==== GetRunningApplicationStatus ====
 +
Takes an input u64 "nn::ns::RightsEnvironmentHandle". Returns an u32 "nn::ns::RunningApplicationStatus".
    
=== IECommerceInterface===
 
=== IECommerceInterface===
Line 1,501: Line 1,671:  
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
! Cmd || Name || Notes
+
! Cmd || Name
 
|-
 
|-
| 0 || RequestLinkDevice || Takes a total of 0x10-bytes of input, returns an [[#IAsyncResult]].
+
| 0 || [[#RequestLinkDevice]]
 
|-
 
|-
| 1 || [6.0.0+] RequestCleanupAllPreInstalledApplications || No input, returns an [[#IAsyncResult]].
+
| 1 || [6.0.0+] [[#RequestCleanupAllPreInstalledApplications]]
 
|-
 
|-
| 2 || [6.0.0+] RequestCleanupPreInstalledApplication || Takes a total of 0x8-bytes of input, returns an [[#IAsyncResult]].
+
| 2 || [6.0.0+] [[#RequestCleanupPreInstalledApplication]]
 
|-
 
|-
| 3 || [6.0.0+] RequestSyncRights || No input, returns an [[#IAsyncResult]].
+
| 3 || [6.0.0+] [[#RequestSyncRights]]
 
|-
 
|-
| 4 || [6.0.0+] RequestUnlinkDevice || Takes a total of 0x10-bytes of input, returns an [[#IAsyncResult]].
+
| 4 || [6.0.0+] [[#RequestUnlinkDevice]]
 
|-
 
|-
| 5 || [6.1.0+] RequestRevokeAllELicense || Takes a total of 0x10-bytes of input, returns an [[#IAsyncResult]].
+
| 5 || [6.1.0+] [[#RequestRevokeAllELicense]]
 
|-
 
|-
| 6 || [9.0.0+] RequestSyncRightsBasedOnAssignedELicenses ||
+
| 6 || [9.0.0+] [[#RequestSyncRightsBasedOnAssignedELicenses]]
 
|}
 
|}
 +
 +
==== RequestLinkDevice ====
 +
Takes an input [[Account_services#Uid|Uid]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
 +
 +
==== RequestCleanupAllPreInstalledApplications ====
 +
No input, returns an output Event handle and an [[#IAsyncResult]].
 +
 +
==== RequestCleanupPreInstalledApplication ====
 +
Takes an input [[NCM_services#ApplicationId|ApplicationId]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
==== RequestSyncRights ====
 +
No input, returns an output Event handle and an [[#IAsyncResult]].
 +
 +
==== RequestUnlinkDevice ====
 +
Takes an input [[Account_services#Uid|Uid]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
See [[#RequestApplicationUpdateInfo]] regarding nifm.
 +
 +
==== RequestRevokeAllELicense ====
 +
Takes an input [[Account_services#Uid|Uid]], returns an output Event handle and an [[#IAsyncResult]].
 +
 +
==== RequestSyncRightsBasedOnAssignedELicenses ====
 +
No input, returns an output Event handle and an [[#IAsyncResult]].
    
=== IFactoryResetInterface ===
 
=== IFactoryResetInterface ===
Line 1,525: Line 1,720:  
! Cmd || Name
 
! Cmd || Name
 
|-
 
|-
| 100 || ResetToFactorySettings
+
| 100 || [[#ResetToFactorySettings]]
 
|-
 
|-
| 101 || ResetToFactorySettingsWithoutUserSaveData
+
| 101 || [[#ResetToFactorySettingsWithoutUserSaveData]]
 
|-
 
|-
| 102 || ResetToFactorySettingsForRefurbishment
+
| 102 || [[#ResetToFactorySettingsForRefurbishment]]
 
|-
 
|-
| 103 || [9.1.0+] ResetToFactorySettingsWithPlatformRegion
+
| 103 || [9.1.0+] [[#ResetToFactorySettingsWithPlatformRegion]]
 
|-
 
|-
| 104 || [9.1.0+] ResetToFactorySettingsWithPlatformRegionAuthentication
+
| 104 || [9.1.0+] [[#ResetToFactorySettingsWithPlatformRegionAuthentication]]
 
|}
 
|}
 +
 +
==== ResetToFactorySettings ====
 +
No input/output.
 +
 +
As of [9.1.0] this is the only [[#IFactoryResetInterface]] cmd used by [[qlaunch]].
 +
 +
==== ResetToFactorySettingsWithoutUserSaveData ====
 +
No input/output.
 +
 +
==== ResetToFactorySettingsForRefurbishment ====
 +
No input/output.
 +
 +
==== ResetToFactorySettingsWithPlatformRegion ====
 +
No input/output.
 +
 +
==== ResetToFactorySettingsWithPlatformRegionAuthentication ====
 +
No input/output.
    
=== IApplicationResource ===
 
=== IApplicationResource ===
Line 2,029: Line 2,241:  
This is "nn::ns::ApplicationUpdateInfo".
 
This is "nn::ns::ApplicationUpdateInfo".
   −
= NoDownloadRightsErrorResolution =
+
This is an u8. [[qlaunch]] just checks whether this is 0.
This is "nn::ns::NoDownloadRightsErrorResolution".
+
 
 +
= ApplicationOccupiedSize =
 +
This is "nn::ns::ApplicationOccupiedSize". This is a 0x80-byte struct.
 +
 
 +
= ProgressForDeleteUserSaveDataAll =
 +
This is "nn::ns::detail::ProgressForDeleteUserSaveDataAll". This is a 0x28-byte struct.
 +
 
 +
= ApplicationViewDeprecated =
 +
This is "nn::ns::ApplicationViewDeprecated". This is a 0x40-byte struct.
 +
 
 +
This is converted from [[#ApplicationView]] by [[#GetApplicationViewDeprecated]] on newer system-versions as follows:
   −
= BackgroundNetworkUpdateState =
   
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
! Value
+
! Offset
! Description
+
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x20 || Same as [[#ApplicationView]] +0x0.
 +
|-
 +
| 0x20 || 0x4 || Same as [[#ApplicationView]] +0x20.
 +
|-
 +
| 0x24 || 0x2 || Same as [[#ApplicationView]] +0x24.
 +
|-
 +
| 0x26 || 0x2 || Cleared to 0.
 +
|-
 +
| 0x28 || 0x10 || Same as [[#ApplicationView]] +0x30.
 +
|-
 +
| 0x38 || 0x4 || Same as [[#ApplicationView]] +0x40.
 
|-
 
|-
| 0 || No sysupdate task exists.
+
| 0x3C || 0x1 || Same as [[#ApplicationView]] +0x44.
 
|-
 
|-
| 1 || Sysupdate download in progress.
+
| 0x3D || 0x2 || Cleared to 0.
 
|-
 
|-
| 2 || Sysupdate ready, pending install.
+
| 0x3F || 0x1 || Cleared to 0.
 
|}
 
|}
   −
This is "nn::ns::BackgroundNetworkUpdateState". This is an u8.
+
= ApplicationView =
 +
This is "nn::ns::ApplicationView". This is a 0x50-byte struct.
   −
Similar to [[#HasDownloaded]], [[#GetBackgroundNetworkUpdateState]] uses [[NIM_services|nim]] ListSystemUpdateTask and [[NIM_services|nim]] GetSystemUpdateTaskInfo. When ListSystemUpdateTask successfully returns a task and GetSystemUpdateTaskInfo is successful, the output value is set to: <code>1 + *((u8*)(taskinfo+0) == 0x3</code>. Otherwise, value=0.
+
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x8 || [[NCM_services#ApplicationId|ApplicationId]]
 +
|-
 +
| 0x8 || 0x4 || ?
 +
|-
 +
| 0xC || 0x4 || Flags
 +
|-
 +
| 0x10 || 0x40 || ?
 +
|}
   −
[[#GetBackgroundNetworkUpdateState]] always returns Result 0, however this will assert if GetSystemUpdateTaskInfo fails with ret!=0x3C89.
+
= ApplicationViewWithPromotionInfo =
 +
This is a 0x70-byte struct.
   −
= SystemUpdateProgress =
   
{| class="wikitable" border="1"
 
{| class="wikitable" border="1"
 
|-
 
|-
Line 2,058: Line 2,306:  
! Description
 
! Description
 
|-
 
|-
| 0x0 || 0x8 || s64 Current size. This value can be larger than total_size when the async operation is finishing. When total_size is <=0, this current_size field may contain a progress value for when the total_size is not yet determined.
+
| 0x0 || 0x50 || [[#ApplicationView]]
 
|-
 
|-
| 0x8 || 0x8 || s64 Total size, this field is only valid when >0.
+
| 0x50 || 0x20 || [[#PromotionInfo]]
 
|}
 
|}
   −
This is "nn::ns::SystemUpdateProgress". This is a 0x10-byte struct.
+
= PromotionInfo =
 +
This is a 0x20-byte struct.
   −
Commands which have this as output will return 0 with the output cleared, when no task is available.
+
{| class="wikitable" border="1"
 
+
|-
= EulaDataPath =
+
! Offset
This is "nn::ns::detail::EulaDataPath". This is a 0x100-byte struct.
+
! Size
 
+
! Description
This contains a file path.
+
|-
 
+
| 0x0 || 0x8 || PosixTime start_timestamp.
= SystemDeliveryInfo =
+
|-
{| class="wikitable" border="1"
+
| 0x8 || 0x8 || PosixTime end_timestamp.
|-
+
|-
! Offset
+
| 0x10 || 0x8 || Remaining time until the promotion ends, in nanoseconds ({end_timestamp - current_time} converted to nanoseconds).
! Size
+
|-
! Description
+
| 0x18 || 0x4 || Not set, left at zero.
|-
+
|-
| 0x0 || 0x4 || SystemDeliveryProtocolVersion. Must be <= to and match [[System_Settings|system-setting]] <code>contents_delivery!system_delivery_protocol_version</code>.
+
| 0x1C || 0x1 || Flags. Bit0: whether the PromotionInfo is valid (including bit1). Bit1 clear: u64 +0x10 is set.
|-
+
|-
| 0x4 || 0x4 || ApplicationDeliveryProtocolVersion. Loaded from [[System_Settings|system-setting]] <code>contents_delivery!application_delivery_protocol_version</code>. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
+
| 0x1D || 0x3 || Padding
|-
+
|}
| 0x8 || 0x1 || HasExFat. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
+
 
|-
+
= NoDownloadRightsErrorResolution =
| 0x9 || 0x3 || Reserved.
+
This is "nn::ns::NoDownloadRightsErrorResolution".
|-
+
 
| 0xC || 0x4 || SystemUpdateMetaVersion.
+
= BackgroundNetworkUpdateState =
|-
+
{| class="wikitable" border="1"
| 0x10 || 0x8 || SystemUpdateMetaId.
+
|-
|-
+
!  Value
| 0x18 || 0x1 || FirmwareVariationId. Used by [[#RequestSendSystemUpdate]].
+
!  Description
|-
+
|-
| 0x19 || 0x1 || UpdatableFirmwareGroupId. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
+
| 0 || No sysupdate task exists.
|-
+
|-
| 0x1A || 0x1 || PlatformRegion (0x00 = Unknown, 0x01 = Global, 0x02 = China).
+
| 1 || Sysupdate download in progress.
|-
+
|-
| 0x1B || 0xC5 || Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
+
| 2 || Sysupdate ready, pending install.
|-
+
|}
| 0xE0 || 0x20 || HMAC-SHA256 over the previous 0xE0-bytes.
+
 
|}
+
This is "nn::ns::BackgroundNetworkUpdateState". This is an u8.
 
+
 
This is "nn::ns::SystemDeliveryInfo". This is a 0x100-byte struct.
+
Similar to [[#HasDownloaded]], [[#GetBackgroundNetworkUpdateState]] uses [[NIM_services|nim]] ListSystemUpdateTask and [[NIM_services|nim]] GetSystemUpdateTaskInfo. When ListSystemUpdateTask successfully returns a task and GetSystemUpdateTaskInfo is successful, the output value is set to: <code>1 + *((u8*)(taskinfo+0) == 0x3</code>. Otherwise, value=0.
 
+
 
= ApplicationDeliveryInfo =
+
[[#GetBackgroundNetworkUpdateState]] always returns Result 0, however this will assert if GetSystemUpdateTaskInfo fails with ret!=0x3C89.
{| class="wikitable" border="1"
+
 
|-
+
= SystemUpdateProgress =
! Offset
+
{| class="wikitable" border="1"
! Size
+
|-
! Description
+
! Offset
|-
+
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x8 || s64 Current size. This value can be larger than total_size when the async operation is finishing. When total_size is <=0, this current_size field may contain a progress value for when the total_size is not yet determined.
 +
|-
 +
| 0x8 || 0x8 || s64 Total size, this field is only valid when >0.
 +
|}
 +
 
 +
This is "nn::ns::SystemUpdateProgress". This is a 0x10-byte struct.
 +
 
 +
Commands which have this as output will return 0 with the output cleared, when no task is available.
 +
 
 +
= EulaDataPath =
 +
This is "nn::ns::detail::EulaDataPath". This is a 0x100-byte struct.
 +
 
 +
This contains a file path.
 +
 
 +
= SystemDeliveryInfo =
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x4 || SystemDeliveryProtocolVersion. Must be <= to and match [[System_Settings|system-setting]] <code>contents_delivery!system_delivery_protocol_version</code>.
 +
|-
 +
| 0x4 || 0x4 || ApplicationDeliveryProtocolVersion. Loaded from [[System_Settings|system-setting]] <code>contents_delivery!application_delivery_protocol_version</code>. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
 +
|-
 +
| 0x8 || 0x1 || HasExFat. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
 +
|-
 +
| 0x9 || 0x3 || Reserved.
 +
|-
 +
| 0xC || 0x4 || SystemUpdateMetaVersion.
 +
|-
 +
| 0x10 || 0x8 || SystemUpdateMetaId.
 +
|-
 +
| 0x18 || 0x1 || FirmwareVariationId. Used by [[#RequestSendSystemUpdate]].
 +
|-
 +
| 0x19 || 0x1 || UpdatableFirmwareGroupId. Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
 +
|-
 +
| 0x1A || 0x1 || PlatformRegion (0x00 = Unknown, 0x01 = Global, 0x02 = China).
 +
|-
 +
| 0x1B || 0xC5 || Unused by [[#RequestSendSystemUpdate]]/[[#RequestReceiveSystemUpdate]], besides HMAC validation.
 +
|-
 +
| 0xE0 || 0x20 || HMAC-SHA256 over the previous 0xE0-bytes.
 +
|}
 +
 
 +
This is "nn::ns::SystemDeliveryInfo". This is a 0x100-byte struct.
 +
 
 +
= ApplicationDeliveryInfo =
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 
| 0x0 || 0x8 || ?
 
| 0x0 || 0x8 || ?
 
|-
 
|-
Line 2,150: Line 2,454:  
= SendApplicationProgress =
 
= SendApplicationProgress =
 
This is "nn::ns::SendApplicationProgress". This is a 0x10-byte struct.
 
This is "nn::ns::SendApplicationProgress". This is a 0x10-byte struct.
 +
 +
= ApplicationRightsOnClient =
 +
This is a 0x20-byte struct.
 +
 +
[[qlaunch]] only uses +0x18/+0x19 in this struct.
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x8 || [[NCM_services#ApplicationId|ApplicationId]]
 +
|-
 +
| 0x8 || 0x10 || [[Account_services#Uid|Uid]]
 +
|-
 +
| 0x18 || 0x1 || Flags, [[qlaunch]] only uses bit0-bit4 and bit7.
 +
|-
 +
| 0x19 || 0x1 || Flags, [[qlaunch]] only uses bit0.
 +
|-
 +
| 0x1A || 0x6 || Unknown
 +
|}
 +
 +
= DownloadTaskStatus =
 +
This is "nn::ns::DownloadTaskStatus". This is a 0x20-byte struct.
    
[[Category:Services]]
 
[[Category:Services]]

Navigation menu