feat(libSceLibreSsl3): implement session time and version accessors #15119
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/15119"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by atharvjairath on 2026-11-02T17:23:27Z.
What
SSL_SESSION_get_timeout,SSL_SESSION_set_timeandSSL_SESSION_get_protocol_versionnow access the session fields directly. The timeout and time fields preserve signed 64-bit guest values on Windows as well as Linux. The setter writes eight bytes and returns the assigned value. A null timeout or set-time input returns zero. A null version input throws.The selected version, timeout and time offsets are 0, 168 and 176. LibreSSL 2.5.4 has different time-field offsets. BunnyFl reported matching accesses in firmware 13.42 disassembly. Session allocation, serialization, expiry and TLS resumption remain open integration questions. LibreSSL 4.0.0 accessors · Session layout · BunnyFl’s firmware evidence
The prior layout uses offsets 144 and 152 for timeout and time. The reported firmware entries are 0xf2130, 0xf2150 and 0xf2170 respectively. The reviewer also reported native Windows fixture results from an older integration. Contributor report
The source scanner classifies 23/276 bodies as implemented on main and 26/276 on this branch. The difference is the 3 exports above. The scanner classifies source bodies and does not measure firmware compatibility. The additional export inventory has 172 pending entries (162 named, 10 known only by NID).
Integration order is #14992 → #15031 → #15045 → #15119 → #15406. This branch is based directly on main
6d173c1a1978. Each branch keeps its own changes. The order allows the shared CMake registrations and debt counts to be reconciled after each merge.Tested
Validated head
1f3df99f818cagainst main6d173c1a1978.7ad9749ed0preserved the exact branch and upstream diffs. Runtime results above are pinned to the tested base.BunnyFl’s earlier review attributed native fixture results to an older commit. The current results above are from the local Linux and Windows PE runs.
Both loader runs printed
session metadata: 7296 cases, 80274 checks.Earlier validation on 521ec17923dd and the historical commits cited below
Current refreshed head
521ec17923ddf932adbdf44701e15c4d7553a61con frozen maind1ae628bc2f62459cce1e9872ba5632c938c71f2. Only debt documentation conflicted. Every original owned production/API/CMake/fixture addition and deletion is preserved; upstream ASN1_TIME_diff and all main unions remain intact. Prior reviews and CI are pinned to older heads below.-j1), 12/12 passed in 36.61s.d1ae628integration, with full dependency-input equality and hashes retained. They were not rebuilt separately for each of these four PRs. The separate signature integration ran 44 Linux and 14 focused Windows tests; those are not this PR’s suite counts. This refresh does not rerun the separate parent/error-string/packaged protocol-NID groups.These are focused module tests, not independent native Windows, full-product, packaged-module/NID, title/homebrew or physical-console validation. Known unrelated Wine limitations remain unresolved; no assertion, timeout, gate or runtime workaround changed. The default-off oracle was not enabled. Warnings remain. No new native CI result or current approval is inferred from older heads.
Historical native Windows CI job125440772243/run41490727885 audited on main
a4eca2a056bf3bbbec98ab42e9d28163e4ea9cb8plus OLD implementation headefef6f4e260633e683b66b4d7d35f6999af59910: 2,010 Passed / 957 Skipped / zero Failed across 2,967 unique rows, 141.61s; all 46 LibreSSL registrations including session metadata passed. Separate full-build/runtime/skip-audit/graph steps were skipped. This pinned native CI unit/runtime evidence does not validate the refreshed head. Original local Linux 43/43 and Windows PE 13/13 at efef/b28 and four rejected external mutation controls remain archived. BunnyFl’s later review approves OLD documentation headf3bbebc3e8629e114cbf61cc1bf44d322ef6f13eand confirms attribution wording/conventions; it is not approval of this rebase. The f3bb Windows check succeeded, but its logs were not audited here and no additional runtime coverage is claimed.Receipts:
/private/tmp/anyps5-advance-20261103-0127/conflict-refresh/15119and the sharedvalidation-evidence.tar.gz,common-input-equality.json,heads-rebased.json,manual-shared-review.txt,peers-finaland reproducible harness/scripts. Previous local/native evidence remains in the linked Nov2 receipts with its original pins.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Overlap report before the branch refresh was pushed
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
main)docs/dev/debt/libSceLibreSsl3.mdL35, L215docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35, L215docs/dev/debt/libSceLibreSsl3.mdL32, L35, L215SSL_SESSION_get_protocol_versionSSL_SESSION_get_timeoutSSL_SESSION_set_timecore/libs/prx/libSceLibreSsl3/src/SessionMetadata.cppcore/libs/prx/libSceLibreSsl3/tests/SessionMetadata.cppdocs/dev/debt/libSceLibreSsl3.mdL35core/libs/prx/libSceLibreSsl3/AdditionalExports.cppL218-225core/libs/prx/libSceLibreSsl3/include/Api.hppL183-184docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35, L215docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL31-32, L35docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35docs/dev/debt/libSceLibreSsl3.mdL35Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.
core/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mddocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppcore/libs/prx/libSceLibreSsl3/src/SessionMetadata.cppcore/libs/prx/libSceLibreSsl3/tests/SessionMetadata.cppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/AdditionalExports.cppcore/libs/prx/libSceLibreSsl3/CMakeLists.txtcore/libs/prx/libSceLibreSsl3/include/Api.hppdocs/dev/debt/libSceLibreSsl3.mdcore/libs/prx/libSceLibreSsl3/CMakeLists.txtImported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-02T19:26:49Z.
Review: APPROVED
Looks right, and the layout matches the PS5 module, not only LibreSSL 4.0.0. Firmware 13.42's
system/common/lib/libSceLibreSsl3.sprx(sha256ee2c529c87fe21b7ef1e5f13d10c47ee90944f52a1f848fe0995e031817c2c3a), disassembly only. These are the whole functions:So the offsets, the null results, the return of
set_timeand the 32-bit version read all match. The null protocol-version throw stands in for a console fault, as the entry says.Tested natively on Windows 11, WinLibs GCC 15.2.0 (not Wine), with this head merged onto
main:guest_libressl3_session_metadataandpublic_headerspass. Withmain'sAdditionalExports.cppandApi.hpp, the new test doesn't compile against the old parameterless stubs.Non-blocking: the debt entry says "console layout/revision ... are unverified". The listing above settles the three fields for 13.42, so that part could narrow to what's still open: lifecycle interoperability, resumption, serialization and expiry.
Imported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-02T20:37:47Z.
Review: APPROVED
Re-checked at
f3bbebc3e8: the only change is the debt wording, and the new "Session metadata fields" entry states my 13.42 reading correctly (0xf213064-bit read at 168 with null giving 0,0xf215064-bit store at 176 returning the time with null giving 0,0xf217032-bit read at 0 with no null check).check_conventions.pypasses at this head.