← Back to ytps5
Technical overview

How ytps5 works

ytps5 is a runtime patch for the official PS5 video app. It does not modify the installed app package, does not use console keys, and does not distribute any app files.

Components

Flow

  1. The installer sends the proxy and injector to elfldr.
  2. The injector reads /data/ytps5-sponsorblock/config.txt and waits for the title named in patch_title (default PPSA01652; any PPSA0165x build works). PPSA01650/PPSA01651 are refused unless allow_y2jb=1.
  3. It attaches with libhijacker, finds HTMLScriptExecute, and makes the target page writable from the kernel side.
  4. It installs a scePadRead GOT trigger. On the next controller poll, the trigger applies the HTMLScriptExecute prologue patch from inside the app's own input loop, avoiding a race with a live script call.
  5. The HTMLScriptExecute hook calls a trampoline containing the original prologue, then calls the original function with a combined string:
<our JavaScript payload>
<the original script>
  1. The JavaScript runs in the page context and is idempotent. It filters ad objects from API responses, watches the video element, fetches SponsorBlock segments through the local proxy, and skips matching segments.
  2. The injector stays resident. When the app closes, it waits for the next launch and patches the new process.

App selection

On first run the injector writes /data/ytps5-sponsorblock/config.txt:

patch_title=PPSA01652   # PPSA01650 | PPSA01651 | PPSA01652 | AUTO
allow_y2jb=0            # 1 = allow patching PPSA01650/PPSA01651

The file is read once at startup. Restart ytps5.elf after editing it. The Y2JB daily drivers are refused unless allow_y2jb=1.

Settings

The app's settings response is patched lazily, only when the settings screen is opened. The “Premium” row becomes “ytps5 Settings”; the purchases/memberships row is removed. The native modal exposes Ad Block, SponsorBlock, category toggles, and the support QR.

Settings are currently per-session. A native persisted config is planned.

Update check

The proxy serves /update by fetching version.json from the repository. The payload compares it with CURRENT_VERSION and shows a toast when a newer version exists.

Limits

Source Markdown · Testing notes · Install ytps5