Commit Graph
41 Commits
Author SHA1 Message Date
DisasterandClaude Sonnet 5.5 0a520ced91 feat(libSceNpCommon): null-check sceNpGetSystemClockUsec
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-31 19:58:28 +01:00
AdriàandClaude Sonnet 5.5 3a8e811a96 fix(libSceNpCommon): cast the remaining const virtual table slots without casting away const
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-31 10:59:12 +01:00
Emanuele a73dbff3e8 fix(libSceNpCommon): cast the const virtual table slots without casting away const 2026-10-31 10:59:08 +01:00
hypermoistandClaude Opus 5.5 79624b828c feat(libSceNpCommon): implement sce::np::NpCommId and sceNpUtilParseTitleId
The constructors, destructors, Clear, IsEmpty, Equals, Parse, Build and the
comparison operators of sce::np::NpCommId, and the C export
sceNpUtilParseTitleId they use, follow libSceNpCommon.sprx of firmware
13.60, checked against 26,501 firmware results.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 23:08:07 +01:00
Adrià c84f79ed3b Merge pull request #13451 from BunnyFl/feat/libscenpcommon-json-parser
feat(libSceNpCommon): implement the JSON parser family
2026-10-30 22:56:24 +01:00
Adrià 140d55e6a0 Merge pull request #13431 from hypermoist/feat/np-ref-object
feat(libSceNpCommon): implement sce::np::RefObject
2026-10-30 22:42:10 +01:00
Adrià 54574150e5 Merge pull request #13453 from Celegans12/feat/npcommon-sandbox-inventory
feat(npcommon): add sandbox mode inventory exports
2026-10-30 22:28:23 +01:00
hypermoistandClaude Opus 5.5 c9e6fe5d17 feat(libSceNpCommon): implement sce::np::RefObject
The constructors, destructors, AddRef and Release of sce::np::RefObject
follow libSceNpCommon.sprx of firmware 13.60, checked against 7,200
firmware results.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 21:41:08 +01:00
hypermoistandClaude Opus 5.5 e8a765b48d feat(libSceNpCommon): implement the sce::np::StreamReader and StreamWriter helpers
Read, ReadAll, ReadData, SkipAll and SkipData on StreamReader, and Write,
WriteData and WriteFilledData on StreamWriter, with and without a StreamCtx,
follow libSceNpCommon.sprx of firmware 13.60, checked against 20,426
firmware results.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 18:27:47 +01:00
Celegans12 f9b776d5fb feat(npcommon): add sandbox mode inventory exports
Resolve two named firmware imports in the existing NP Common provider.
Match both identities to the pinned 13.60 inventory and rehashed NIDs.
Keep parameterless declarations as import-resolution placeholders only.
Throw immediately instead of guessing sandbox mode values or behavior.
Record the unknown signatures and behavior in per-library technical debt.
AI-assisted: yes
2026-10-30 15:55:22 +01:00
BunnyFlandClaude Opus 5.5 2087b15d4d feat(libscenpcommon): implement the JSON parser family
sceNpJsonParse, sceNpJsonParseBuf and sceNpJsonParseEx with their
Init calls, and the sceNpServerErrorJson exports, follow firmware
13.42: a resumable byte-by-byte parser that walks a rule table level
by level (member keys compared without case, array elements, keyless
wildcard entries until the first unmatched container, a descend flag)
and calls the caller's handler for each matched container, key and
value. The Buf form uses caller key and value buffers, and the Ex form
also reports the stream offset of each event, delivers long strings
and numbers in pieces and reports everything when no rules are given.
The server error calls read error.code (or a top-level code for the
Multi form) and fall back to the HTTP status.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 15:55:02 +01:00
hypermoist 93fbebef0a Merge remote-tracking branch 'upstream/main' into feat/np-memory-stream
# Conflicts:
#	core/libs/prx/libSceNpCommon/Runtime.cpp
#	core/libs/prx/libSceNpCommon/include/Api.hpp
#	core/libs/tests/GuestNpCommonRuntime.cpp
#	docs/dev/debt/libSceNpCommon.md
2026-10-31 01:27:48 +13:00
hypermoistandClaude Opus 5.5 38bd414bee feat(libSceNpCommon): implement sce::np::MemoryStreamReader and MemoryStreamWriter
Constructors, destructors, Read and Write follow libSceNpCommon.sprx of
firmware 13.60, checked against 13,400 firmware results.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-31 00:33:51 +13:00
hypermoist b7098523d0 Merge remote-tracking branch 'upstream/main' into feat/np-title-id-object 2026-10-30 23:12:19 +13:00
Dean 66d362c782 Merge pull request #12836 from hypermoist/feat/np-object-operators
feat(libSceNpCommon): implement the sce::np::Object new and delete operators
2026-10-30 22:49:46 +13:00
hypermoistandClaude Opus 5.5 67bab6bdfe fix(libSceNpCommon): store the high hex digit before checking the low one in sceNpStrParseHex
sceNpStrParseHex and sceNpStrnParseHex in firmware 13.60 write the high
nibble of each byte before they read the low digit, so a refused low digit
leaves that byte as the high nibble shifted left by four.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 03:10:33 +13:00
hypermoistandClaude Opus 5.5 949680de9a feat(libSceNpCommon): implement sce::np::NpTitleId
Implements the sce::np::NpTitleId constructors, destructors, assignment,
Clear, IsEmpty, Parse, ConstructFromTitleId, Build and comparisons from
libSceNpCommon.sprx of firmware 13.60. operator==(SceNpTitleId, NpTitleId)
stays a stub; #12866 implements it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 02:51:27 +13:00
hypermoistandClaude Opus 5.5 72cde05a64 feat(libSceNpCommon): implement the sce::np::Object new and delete operators
The ten operators allocate an object behind a 16-byte header that keeps its
allocator and free it through that allocator, as libSceNpCommon.sprx of
firmware 13.60 does (read from disassembly, not measured on a console). Five
were NotImplemented stubs; the other five were not exported.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 00:58:39 +13:00
MarcZX10 cefb89fceb fix(libSceNpCommon): let sceNpUtilJsonUnescape size a query with a null destination
The final room check ran even when dst was null, so a size query such as
(nullptr, 0, src, n, &length) returned NP_UTIL_ERROR_BUFFER_TOO_SMALL and never
wrote the required length, although the per-character checks in the same
function already skip the comparison for a null destination. The check now
applies only when there is a destination.
2026-10-28 04:24:44 +00:00
MarcZX10 79245feab9 fix(libSceNpCommon): require the second \u of a surrogate pair in sceNpUtilJsonGetOneChar
After a high surrogate, sceNpUtilJsonGetOneChar parsed four hex digits at offset
8 without checking that offsets 6 and 7 hold a backslash and a 'u'. The string
"\ud83dXXde00" decoded to U+1F600 and consumed 12 bytes, swallowing the two
unrelated characters. sceNpUtilJsonUnescape already makes that check. A high
surrogate not followed by \u now takes the same failure path as an invalid low
surrogate.
2026-10-28 04:24:44 +00:00
MarcZX10 7fae9a1656 fix(libSceNpCommon): count the text already in the buffer in sceNpUtilJsonEscape
sceNpUtilJsonEscape appends to the destination with strcat, but the room check
started its running length at 0 and ignored the text the buffer already held,
so escaping into a partly filled buffer wrote past its end:
sceNpUtilJsonEscape(buf, 16, "\n\n\n", 3) on a buffer holding ten characters
placed 16 characters and the terminator in 16 bytes.

The running length now starts at the length of the existing text, and a
destination that is already full returns NP_UTIL_ERROR_BUFFER_TOO_SMALL.
2026-10-28 04:24:43 +00:00
Dean 1068cd6b76 Merge pull request #7780 from savvaniss/fix/savedata-ps4-modules
fix(savedata): build libSceSaveData and libSceSaveDataDialog from the native sources
2026-10-28 13:48:05 +13:00
Dean Galvin 9c0445daae fix(libSceNpCommon): declare the salvaged exports in the public API 2026-10-27 19:57:19 +13:00
xdCloudy 90ac7f3100 feat(libSceNpCommon): declare 150 additional PS5 exports 2026-10-27 19:57:19 +13:00
milescovielloandClaude Opus 5.5 65abce99bb test(libSceNpCommon): cover the NP RTC conversion to POSIX time and RFC 3339 formatting
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-26 18:02:07 +00:00
Savvanis SpyrosandClaude Opus 5.5 7394d62549 Merge branch 'main' into fix/savedata-ps4-modules
main's canonical-header refactor (f38d29fd08) edited the old libSceSaveData and libSceSaveDataDialog sources this branch removes, and made EventFlag.cpp, libSceNpCommon's Runtime.cpp and GuestKernelErrors.cpp include the old SaveDataCore.hpp. Those three use nothing from it and build without it, so the include is dropped. SaveDataWriteReplacement.cpp takes main's canonical header and keeps only the native path.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-25 23:06:41 +02:00
Alexandre Figueiredo da3e88a21d feat(libSceNpCommon): forward sceNpCloseEventFlag to sceKernelCloseEventFlag 2026-10-25 00:10:14 +01:00
boykopovar f38d29fd08 refactor(sdk): add canonical headers for remaining libraries 2026-10-24 23:17:42 +03:00
boykopovar 35cf8d56cd refactor(sdk): add canonical headers for core libraries 2026-10-24 23:17:37 +03:00
hypermistandClaude Opus 5.5 702d85e0bc fix(libSceNpCommon): check for a queued callout before writing it
sceNpCalloutStartOnCtx64 cleared and filled the entry before looking for
it in the queue, so restarting a queued callout cut off every callout
queued after it and changed its deadline while the callout thread could
read it. The entry is now written only after the duplicate check under
the context mutex. sceNpArchInit and sceNpArchTerm now hold a lock, so a
second caller no longer returns before the global heap exists. Both
differences from the firmware are recorded in the debt document.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013XFS3FUfBtqCVfwmBrRQ6q
2026-10-24 00:57:29 +13:00
hypermist b98f2f82e1 Merge remote-tracking branch 'upstream/main' into feat/npcommon-runtime
# Conflicts:
#	core/libs/prx/libSceNpCommon/PendingExports.cpp
2026-10-22 21:27:04 +13:00
hypermistandClaude Opus 5.5 962b88a9e1 fix(libSceNpCommon): parse sceNpStrToInt32 through a 64-bit integer on every host
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RbLgECLQ2bpDM7oe2urGZK
2026-10-22 14:18:58 +13:00
Get-fix f04d16d702 feat: PS4 NpTrophy, save data v1, NpWebApi offline and Limbo's other imports
NpTrophy reads the trophy count and icons from the title's trophy
package (names are encrypted and stay not implemented), PS4 v1 save data
calls wrap the native v2/v3 ones, and NpWebApi library contexts, handles
and push event filters work offline (service filters fail without a
signed-in user). libSceAjm is built from the libSceAjm.native sources
for PS4 titles. Limbo's (CUSA01664) remaining PS4 imports, including the
synchronous PS4 TUS calls and the Facebook dialog calls next to the
existing libraries, are exported as not implemented.
2026-10-22 00:35:09 +03:00
hypermistandClaude Opus 5.5 736ee67caf feat(libSceNpCommon): implement 94 more of the module's exports
Builds on #9037. Adds threads, event flags, semaphores, atomics, heaps
and kernel memory, callout contexts, time and SDK version queries,
base64 and hex codecs, integer and string helpers, JSON escaping, URL
encoding, online id strings, language codes, title ids and debug output.
The behaviour follows libSceNpCommon.sprx from firmware 12.00, read
from disassembly.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RbLgECLQ2bpDM7oe2urGZK
2026-10-22 00:23:37 +13:00
Yossi Yadgar affc646ae7 feat(libSceNpCommon): wrap the condition, join, clock and version calls 2026-10-21 13:18:57 +03:00
Yossi Yadgar 6fdfa33e03 feat(libSceNpCommon): wrap the libkernel mutex calls 2026-10-21 13:18:56 +03:00
Yossi Yadgar 683fc312fa feat(libSceNpCommon): compare, order and validate online IDs and NpIds 2026-10-21 13:18:56 +03:00
xdCloudy 411a8e7711 fix(libSceNpCommon): include export ABI declarations 2026-10-21 09:49:31 +01:00
xdCloudy 8648287a23 feat(libSceNpCommon): isolate 150 pending exports 2026-10-21 09:49:31 +01:00
xdCloudy bb8b215939 feat(libSceNpManager): declare 150 pending exports 2026-10-21 09:49:31 +01:00
xdCloudy 3e12ba183f feat(libSceNpCommon): declare 150 pending exports 2026-10-21 09:49:31 +01:00