feat(np): implement offline service-entitlement requests #1299

Closed
TibixDev wants to merge 1 commit from upstream-pr/1299 into main
TibixDev commented 2026-10-07 22:43:18 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TibixDev on 2026-10-07T22:43:18Z.


Status after review

Awaiting a title that needs request lifecycle handling.

Verified current main's request and poll exports: both return SCE_NP_ERROR_SIGNED_OUT from 530aa2088. The original Skyrim stop is already addressed. The current PR head also already removed the disputed SDK link and MinGW workaround; those do not need another fix.

The new main-based Skyrim test, using the experimental NGS reverb integration, progresses into graphics without this entitlement branch. That is not a trace proving every entitlement call occurred, and I have no failing request-ID/abort/delete call to show. I cannot substantiate a title need for the extra lifecycle or its unverified error codes. Keeping this open for an actual counterexample; not presenting its existing unit test as evidence of a title fix.

What

Implement service-entitlement request and poll calls for offline use. Requests receive distinct 64-bit IDs and report the signed-out error when polled. Abort checks the ID; delete removes it.

Tested

Earlier branch-specific tests and measurements remain in the discussion. They have not been rerun on a redesigned current-main version of this PR. The review audit and shared NGS-assisted title exploration do not establish that this head is merge-ready. No full Linux/Windows platform CI was dispatched in this pass.

Checklist

  • Current-main implementation and outstanding review requirements complete.
  • Isolated title benefit / reference validation established where required.
  • Depends on: none.
  • AI-assisted: yes.
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4779372328 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299). Originally posted by [TibixDev](https://github.com/TibixDev) on 2026-10-07T22:43:18Z. --- ### Status after review **Awaiting a title that needs request lifecycle handling.** Verified current main's request and poll exports: both return `SCE_NP_ERROR_SIGNED_OUT` from `530aa2088`. The original Skyrim stop is already addressed. The current PR head also already removed the disputed SDK link and MinGW workaround; those do not need another fix. The new main-based Skyrim test, using the experimental NGS reverb integration, progresses into graphics without this entitlement branch. That is not a trace proving every entitlement call occurred, and I have no failing request-ID/abort/delete call to show. I cannot substantiate a title need for the extra lifecycle or its unverified error codes. Keeping this open for an actual counterexample; not presenting its existing unit test as evidence of a title fix. ### What Implement service-entitlement request and poll calls for offline use. Requests receive distinct 64-bit IDs and report the signed-out error when polled. Abort checks the ID; delete removes it. ### Tested Earlier branch-specific tests and measurements remain in the discussion. They have not been rerun on a redesigned current-main version of this PR. The review audit and shared NGS-assisted title exploration do not establish that this head is merge-ready. No full Linux/Windows platform CI was dispatched in this pass. ### Checklist - [ ] Current-main implementation and outstanding review requirements complete. - [ ] Isolated title benefit / reference validation established where required. - [x] Depends on: none. - [x] AI-assisted: yes.
oneandonlydean commented 2026-10-08 03:26:09 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-08T03:26:09Z.


Which title reaches these service-entitlement calls on main? With the ID and the log line where it stops this can go in; otherwise it waits until one does. The same goes for #1320 and #1322: new library behaviour needs a title that reaches it on main.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6051543604 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6051543604). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-08T03:26:09Z. --- Which title reaches these service-entitlement calls on main? With the ID and the log line where it stops this can go in; otherwise it waits until one does. The same goes for #1320 and #1322: new library behaviour needs a title that reaches it on main.
TibixDev commented 2026-10-08 03:56:36 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TibixDev on 2026-10-08T03:56:36Z.


The title is Skyrim, PPSA03747, content version 01.001.010. I reproduced this on upstream a9ba39c927713cf294b8e1b7877ddb365d3a1d6f, using Linux and a GCC 16 Release build in Fedora 44.

There are two earlier loader blockers, so the exact test sequence matters:

  1. Unmodified upstream exits with undefined symbol: bcolXMmp6qQ (sceAppContentTemporaryDataUnmount, #1320).
  2. Upstream plus #1320 exits with undefined symbol: cRILAEvn+9M (sceNpUnregisterNpReachabilityStateCallback, #1322).
  3. Upstream plus #1320 and #1322 starts the guest, then aborts after about two seconds:
terminate called after throwing an instance of 'std::runtime_error'
  what():  sceNpEntitlementAccessRequestServiceEntitlementInfoList not implemented

This is an executed entitlement request, not only an import. Adding #1299 gets past it; the next abort is the separate NGS2: rack id 0x2001 is not implemented failure. No combined-fork graphics or audio changes were included, and all runs used the same freshly relinked executable.

The four app-content, NP manager, reachability and service-entitlement tests pass on this upstream-based branch. This demonstrates the title blocker and progress past it; it does not establish console-equivalent entitlement behavior.

AI-assisted investigation and reply.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6051863585 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6051863585). Originally posted by [TibixDev](https://github.com/TibixDev) on 2026-10-08T03:56:36Z. --- The title is **Skyrim, PPSA03747**, content version **01.001.010**. I reproduced this on upstream `a9ba39c927713cf294b8e1b7877ddb365d3a1d6f`, using Linux and a GCC 16 Release build in Fedora 44. There are two earlier loader blockers, so the exact test sequence matters: 1. Unmodified upstream exits with `undefined symbol: bcolXMmp6qQ` (`sceAppContentTemporaryDataUnmount`, #1320). 2. Upstream plus #1320 exits with `undefined symbol: cRILAEvn+9M` (`sceNpUnregisterNpReachabilityStateCallback`, #1322). 3. Upstream plus #1320 and #1322 starts the guest, then aborts after about two seconds: ```text terminate called after throwing an instance of 'std::runtime_error' what(): sceNpEntitlementAccessRequestServiceEntitlementInfoList not implemented ``` This is an executed entitlement request, not only an import. Adding #1299 gets past it; the next abort is the separate `NGS2: rack id 0x2001 is not implemented` failure. No combined-fork graphics or audio changes were included, and all runs used the same freshly relinked executable. The four app-content, NP manager, reachability and service-entitlement tests pass on this upstream-based branch. This demonstrates the title blocker and progress past it; it does not establish console-equivalent entitlement behavior. AI-assisted investigation and reply.
oneandonlydean commented 2026-10-08 05:12:47 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-08T05:12:47Z.


Two things before this can go in:

  • docs/dev/TechnicalDebt.md: please drop the link to the PS5 SDK reference (game.develop.playstation.net); the repo shouldn't point at licensed SDK documentation.
  • libSceNpEntitlementAccess/CMakeLists.txt: the MinGW static-flag block isn't needed, core/libs/CMakeLists.txt already strips those flags for every library (121d9332b).
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6052799967 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6052799967). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-08T05:12:47Z. --- Two things before this can go in: - `docs/dev/TechnicalDebt.md`: please drop the link to the PS5 SDK reference (game.develop.playstation.net); the repo shouldn't point at licensed SDK documentation. - `libSceNpEntitlementAccess/CMakeLists.txt`: the MinGW static-flag block isn't needed, `core/libs/CMakeLists.txt` already strips those flags for every library (121d9332b).
TibixDev commented 2026-10-08 05:22:02 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TibixDev on 2026-10-08T05:22:02Z.


Removed the SDK documentation link and the redundant MinGW flag block. The error values and console behavior remain marked as unverified on hardware.

Rebased on 5850a6cd. The Fedora 44 Release service-entitlement test passes. Windows was not tested.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6052937330 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6052937330). Originally posted by [TibixDev](https://github.com/TibixDev) on 2026-10-08T05:22:02Z. --- Removed the SDK documentation link and the redundant MinGW flag block. The error values and console behavior remain marked as unverified on hardware. Rebased on `5850a6cd`. The Fedora 44 Release service-entitlement test passes. Windows was not tested.
github-actions[bot] commented 2026-10-08 06:53:28 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-08T06:53:28Z.


Progress report (dad6e96 → e66af07)

📈 System libraries: 85.25% (+0.07%, +2 implemented functions)

✅ 2 implemented
Library Name
libSceNpEntitlementAccess sceNpEntitlementAccessPollServiceEntitlementInfoList
libSceNpEntitlementAccess sceNpEntitlementAccessRequestServiceEntitlementInfoList
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6054270465 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6054270465). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-08T06:53:28Z. --- <!-- progress-report --> ### Progress report (dad6e96 → e66af07) 📈 **System libraries**: 85.25% (+0.07%, +2 implemented functions) <details> <summary>✅ 2 implemented</summary> | Library | Name | | - | - | | libSceNpEntitlementAccess | `sceNpEntitlementAccessPollServiceEntitlementInfoList` | | libSceNpEntitlementAccess | `sceNpEntitlementAccessRequestServiceEntitlementInfoList` | </details>
oneandonlydean commented 2026-10-09 20:14:31 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-09T20:14:31Z.


Main now returns SCE_NP_ERROR_SIGNED_OUT from sceNpEntitlementAccessRequestServiceEntitlementInfoList and the poll (530aa2088b), so PPSA03747 no longer stops there. Does it still need the request IDs from this PR on current main? If it does, please rebase (it conflicts in Export.cpp) and add the log line where it stops; if not, this can be closed.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6088507476 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6088507476). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-09T20:14:31Z. --- Main now returns `SCE_NP_ERROR_SIGNED_OUT` from `sceNpEntitlementAccessRequestServiceEntitlementInfoList` and the poll (530aa2088b), so PPSA03747 no longer stops there. Does it still need the request IDs from this PR on current main? If it does, please rebase (it conflicts in `Export.cpp`) and add the log line where it stops; if not, this can be closed.
adriadam10 commented 2026-10-10 23:58:19 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-10T23:58:19Z.

Review: CHANGES_REQUESTED


Thanks for the update. Two things are needed before this can go in:

  • It conflicts with main in core/libs/prx/libSceNpEntitlementAccess/Export.cpp: 530aa2088 now makes sceNpEntitlementAccessRequestServiceEntitlementInfoList and the poll return SCE_NP_ERROR_SIGNED_OUT. Please rebase on current main.
  • As @oneandonlydean asked on 2026-10-09: on current main, PPSA03747 no longer stops at these calls. Please show, with a log line from the rebased PR, where the title stops without the request IDs / abort / delete handling and that it gets further with them. Without a title that reaches that behaviour, main's signed-out return is enough and this can be closed.

If a title does need it, keep the unverified abort/delete error values listed in TechnicalDebt.md as you have.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5481252562 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#pullrequestreview-5481252562). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-10T23:58:19Z. **Review:** CHANGES_REQUESTED --- Thanks for the update. Two things are needed before this can go in: - It conflicts with `main` in `core/libs/prx/libSceNpEntitlementAccess/Export.cpp`: 530aa2088 now makes `sceNpEntitlementAccessRequestServiceEntitlementInfoList` and the poll return `SCE_NP_ERROR_SIGNED_OUT`. Please rebase on current `main`. - As @oneandonlydean asked on 2026-10-09: on current `main`, PPSA03747 no longer stops at these calls. Please show, with a log line from the rebased PR, where the title stops without the request IDs / abort / delete handling and that it gets further with them. Without a title that reaches that behaviour, `main`'s signed-out return is enough and this can be closed. If a title does need it, keep the unverified abort/delete error values listed in `TechnicalDebt.md` as you have.
TibixDev commented 2026-10-12 04:51:53 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TibixDev on 2026-10-12T04:51:53Z.


Review-pass update:

Verified current main's request and poll exports: both return SCE_NP_ERROR_SIGNED_OUT from 530aa2088. The original Skyrim stop is already addressed. The current PR head also already removed the disputed SDK link and MinGW workaround; those do not need another fix.

The new main-based Skyrim test, using the experimental NGS reverb integration, progresses into graphics without this entitlement branch. That is not a trace proving every entitlement call occurred, and I have no failing request-ID/abort/delete call to show. I cannot substantiate a title need for the extra lifecycle or its unverified error codes. Keeping this open for an actual counterexample; not presenting its existing unit test as evidence of a title fix.

I have updated the PR description to match this status. The PR remains open; the outstanding review requirements are not being marked resolved. AI-assisted audit.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6117973509 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6117973509). Originally posted by [TibixDev](https://github.com/TibixDev) on 2026-10-12T04:51:53Z. --- Review-pass update: Verified current main's request and poll exports: both return `SCE_NP_ERROR_SIGNED_OUT` from `530aa2088`. The original Skyrim stop is already addressed. The current PR head also already removed the disputed SDK link and MinGW workaround; those do not need another fix. The new main-based Skyrim test, using the experimental NGS reverb integration, progresses into graphics without this entitlement branch. That is not a trace proving every entitlement call occurred, and I have no failing request-ID/abort/delete call to show. I cannot substantiate a title need for the extra lifecycle or its unverified error codes. Keeping this open for an actual counterexample; not presenting its existing unit test as evidence of a title fix. I have updated the PR description to match this status. The PR remains open; the outstanding review requirements are not being marked resolved. AI-assisted audit.
oneandonlydean commented 2026-10-14 05:08:58 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-14T05:08:58Z.


Closing for now: no title is known to reach these service-entitlement calls. With the queue this large we're closing stalled perf PRs that don't show a gain in a title; reopen it with before/after numbers from a title scene (the summary lines from the performance report form) if you pick it up again.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6161371374 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1299#issuecomment-6161371374). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-14T05:08:58Z. --- Closing for now: no title is known to reach these service-entitlement calls. With the queue this large we're closing stalled perf PRs that don't show a gain in a title; reopen it with before/after numbers from a title scene (the summary lines from the performance report form) if you pick it up again.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!1299
No description provided.