9.4 KiB
libSceNpUniversalDataSystem technical debt
Silent stubs
- sceNpUniversalDataSystemRegisterContext (libSceNpUniversalDataSystem) - returns
SCE_NP_UNIVERSAL_DATA_SYSTEM_OKwithout checking the context or handle and without recording anything.sceNpUniversalDataSystemPostEventuses only its context and ignores the handle, so nothing depends on the registration. All ten titles in my set call it. - sceNpUniversalDataSystemDestroyHandle and sceNpUniversalDataSystemAbortHandle (libSceNpUniversalDataSystem) - return
SCE_NP_UNIVERSAL_DATA_SYSTEM_OKwithout checking the handle.sceNpUniversalDataSystemCreateHandlealways hands out the same handle and keeps no state, so there is nothing to tear down. All ten titles in my set callsceNpUniversalDataSystemDestroyHandle; Metal Gear Solid 4 (PPSA18194) also callssceNpUniversalDataSystemAbortHandle.
Unknown function info
- libSceNpUniversalDataSystem additional exports - these name/NID pairs are present in the 13.60 export inventory. Parameter lists, return types and behavior are unverified. Parameterless
intdeclarations are import-resolution placeholders, not verified ABI prototypes; every entry throws throughNotImplemented_nid_no_patch. No runtime functionality is implemented.
| Name | NID |
|---|---|
sceNpUniversalDataSystemIntCloseStream |
pSyd06cKZVk |
sceNpUniversalDataSystemIntDeleteUserData |
IiSeRSN++Mc |
sceNpUniversalDataSystemIntGetNpCommIdByNpTitleId |
ONOoGEhy+mg |
sceNpUniversalDataSystemIntGetNpTitleIdListByNpCommId |
FgmhJGcGztU |
sceNpUniversalDataSystemIntGetObjectState |
KSHif9MWQjQ |
sceNpUniversalDataSystemIntOpenObjectsDefinitionConfStream |
O5enyfsJoK0 |
sceNpUniversalDataSystemIntOpenObjectsDefinitionConfStreamByObjectId |
vOdDBWSu-Gk |
sceNpUniversalDataSystemIntOpenStreamByUri |
tkUOy4Ag4wo |
sceNpUniversalDataSystemIntReadStream |
ABFxQ2B50RA |
-
sceNpUniversalDataSystemIntPostRecordData (libSceNpUniversalDataSystem) - declared without parameters only to resolve the known import; its signature and behaviour are unverified and it throws through
NotImplemented_nid_no_patch. -
Events:
sceNpUniversalDataSystemCreateEventcopiespropand returns the event's own property object throughprop_ptr, as KytyPS5 does;sceNpUniversalDataSystemEventPropertyObjectSetObject,SetArrayand the array setters for objects and arrays store a copy ofvalueand return the stored copy throughvalue_ptr. Destroying a property object or array that its Create function did not return (an event's property object or a stored copy) does nothing, as its owner frees it. These ownership rules are not verified on a console, nor is the text ofsceNpUniversalDataSystemEventToString(a debug rendering of the event, not the console's format) and the size thatsceNpUniversalDataSystemEventEstimateSizereturns (a MessagePack size model, not measured). -
sceNpUniversalDataSystemCreateContext and sceNpUniversalDataSystemCreateHandle (libSceNpUniversalDataSystem) - native return codes for null output pointers (
context == nullptrandhandle == nullptr) are unresolved and unverified on a console. The reimplementation in KytyPS5 returns0x80553102(SCE_NP_UNIVERSAL_DATA_SYSTEM_ERROR_INVALID_ARGUMENT), but this error return is unverified against native hardware; host paths continue to throwstd::invalid_argumentuntil the native contract is established. No call that could be decoded in the titles checked passes a constant null pointer to either function. -
sceNpUniversalDataSystemIntAbortHandle, sceNpUniversalDataSystemIntCheckNetSyncTitles, sceNpUniversalDataSystemIntCreateContext, sceNpUniversalDataSystemIntCreateHandle, sceNpUniversalDataSystemIntDeleteAllData and sceNpUniversalDataSystemIntDeleteUserDataWithServerData (libSceNpUniversalDataSystem) - names and NIDs are present in the PS5 3.20 export inventory, but no credible prototypes were found. They are declared without parameters solely to resolve known imports; this is not an ABI claim, and each throws until its signature is verified
-
sceNpUniversalDataSystemIntDestroyContext, sceNpUniversalDataSystemIntDestroyHandle, sceNpUniversalDataSystemIntInitialize, sceNpUniversalDataSystemIntNetSyncTitles and sceNpUniversalDataSystemIntTerminate (libSceNpUniversalDataSystem) - names and NIDs are present in the PS5 3.20 export inventory, but no credible prototypes were found. They are declared without parameters solely to resolve known imports; this is not an ABI claim, and each throws until its signature is verified
Functional
- Record builders (libSceNpUniversalDataSystem) - the signatures come from the 11.00 wrappers:
IntInitializetakes a 16-byte{size, memory}parameter and rejects another size with0x80553112; the create, destroy and setter functions use the confirmed0x80553101,0x80553102,0x8055310D,0x80553114,0x80553115,0x80553119and0x8055311Acodes. The host models record arrays and objects with the event property array and object types: arrays append typed values, objects set keys, nested values are cloned and the stored copy is returned throughvalue_ptr; a returned child stays usable while its owner is alive and its owner's destruction invalidates it. Lifecycle and record operations share one lock, andIntInitializeuses a compare-exchange.IntCreateRecordDatastores the validated type inrecordTypeand an emptycontextobject. The console's record store, serialization and estimate are not measured: the 11.00 module calls itsSceNpUdsimports for them (IntInitializeat0x8640,IntGetMemoryStatat0x8670andIntRecordDataEstimateSizeat0x138), and the host does not reproduce that allocator or size contract.IntGetMemoryStatandIntRecordDataEstimateSizetherefore throw after their argument checks, and the memory pool passed toIntInitializeis ignored. - Trophy events:
sceNpUniversalDataSystemPostEventstores an_UnlockTrophyevent with an int32_trophy_idof 0 or more as an unlock for the user and service label of its context, as KytyPS5 does, except an id that libSceNpTrophy2 refuses when the title's trophy data is loaded (one not in the data, a platinum or a progressive trophy)._UpdateTrophyProgressgoes through the title's statistic rules like any other event (below). A context need not be registered, and every post of an event thatsceNpUniversalDataSystemCreateEventreturned and that is not yet destroyed returns success (a null or any other event pointer stops the game): KytyPS5's errors for an unknown or unregistered context and for a malformed unlock are not verified. The storage statistics stay zero. - Statistics: every other event goes through the title's rules in
sce_sys/uds/udsNN.ucp, which libSceNpTrophy2 reads. Only"aggregation":"latest"and"max"statistics ofdataTypeuint32,uint64orint32are kept; no public source documents the other aggregations (such ascount,collectionandeachLatest) or types, so their definitions and rules are skipped. Only rules whose input is a$.namepath (dotted for nested objects) are applied. A value is used when it is an integer of any width that is not negative and fits the statistic's type andminValue/maxValue; KytyPS5 requires the statistic's exact width, and whether the console converts, clamps or rejects other values is not known. Statistics are stored per user and service label, and every trophy'sunlockConditionis compared after each event that sets one. - Event checks: before
sceNpUniversalDataSystemInitializethe 13.42 module returns 0x80553117 from the event and property functions (creating, setting, destroying, sizing and describing), even for null arguments; these functions keep no initialized state and run normally. The module'ssceNpUniversalDataSystemCreateEventalso compares packed sizes with 0x5000 bytes whenpropis given (read from its disassembly, not measured); this one does not.sceNpUniversalDataSystemEventToStringwrites NaN and infinite properties asstd::to_charsdoes; the console's text for them is not measured.