feat(libSceLibreSsl3): implement SSL_CTX_set_timeout #16588

Merged
GalaxyGamingFR merged 1 commit from upstream-pr/16588 into main 2026-11-09 08:25:54 +00:00
GalaxyGamingFR commented 2026-11-07 07:35:44 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by GalaxyGamingFR on 2026-11-07T07:35:44Z.


What

Implement SSL_CTX_set_timeout (BBOgwZLvXHA) in libSceLibreSsl3, replacing its parameterless throwing placeholder in AdditionalExports.cpp.

  • Source: LibreSSL 4.0.0 at ce488b78, the revision the library's debt file already uses.
  • It stores the new timeout in sessionTimeout of the existing LibreSsl3SslCtx and returns the previous value. A null context returns 0 and changes nothing, as in LibreSSL. long is 64 bits on the guest, so both the argument and the result are std::int64_t.

The gap is recorded in docs/dev/debt/libSceLibreSsl3.md, and the export inventory is updated (144 exports, 134 named).

No title's trace or disassembly was used, and the export was not measured on a PS5.

Tested

Windows 11, MinGW-w64 GCC 15.2 (WinLibs), Release build. No title or homebrew, and not built on Linux or macOS.

  • guest_libressl3_ssl passes. The new CheckContextTimeout runs on a guarded LibreSsl3SslCtx and covers setting the same value, returning the previous value, a value above 32 bits, negative and zero values, and the null context. It also checks that no other byte of the context changes.
  • One deliberate bug, storing the old value instead of the new one, makes the test fail.
  • python tools/check_conventions.py --base origin/main passes.

I searched open and merged pull requests for SSL_CTX_set_timeout just before opening this one, and none implements it. #16586 changes the same export inventory count, so whichever lands second needs a one-line rebase.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5199527156 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/16588). Originally posted by [GalaxyGamingFR](https://github.com/GalaxyGamingFR) on 2026-11-07T07:35:44Z. --- ### What Implement `SSL_CTX_set_timeout` (`BBOgwZLvXHA`) in `libSceLibreSsl3`, replacing its parameterless throwing placeholder in `AdditionalExports.cpp`. - Source: LibreSSL 4.0.0 at [`ce488b78`](https://github.com/libressl/openbsd/blob/ce488b78e0bd994780569df718596b9776ff681a/src/lib/libssl/ssl_sess.c), the revision the library's debt file already uses. - It stores the new timeout in `sessionTimeout` of the existing `LibreSsl3SslCtx` and returns the previous value. A null context returns 0 and changes nothing, as in LibreSSL. `long` is 64 bits on the guest, so both the argument and the result are `std::int64_t`. The gap is recorded in `docs/dev/debt/libSceLibreSsl3.md`, and the export inventory is updated (144 exports, 134 named). No title's trace or disassembly was used, and the export was not measured on a PS5. ### Tested Windows 11, MinGW-w64 GCC 15.2 (WinLibs), Release build. No title or homebrew, and not built on Linux or macOS. - `guest_libressl3_ssl` passes. The new `CheckContextTimeout` runs on a guarded `LibreSsl3SslCtx` and covers setting the same value, returning the previous value, a value above 32 bits, negative and zero values, and the null context. It also checks that no other byte of the context changes. - One deliberate bug, storing the old value instead of the new one, makes the test fail. - `python tools/check_conventions.py --base origin/main` passes. I searched open and merged pull requests for `SSL_CTX_set_timeout` just before opening this one, and none implements it. #16586 changes the same export inventory count, so whichever lands second needs a one-line rebase. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
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!16588
No description provided.