feat(libSceLibreSsl): implement X509_get_ext_d2i #13877

Open
JaceTheBlu wants to merge 48 commits from upstream-pr/13877 into main
JaceTheBlu commented 2026-10-31 10:45:29 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JaceTheBlu on 2026-10-31T10:45:29Z.


What

Implements X509_get_ext_d2i in libSceLibreSsl, ported from LibreSSL 2.5.4 (X509V3_get_d2i in v3_lib.c).

  • The search over the certificate's extensions follows LibreSSL exactly: a null idx reports a duplicate extension with crit = -2, a non-null idx resumes after the given position, and a missing extension sets both to -1.
  • Each value is decoded with the template of its method from ext_dat.h: basicConstraints, keyUsage, the GENERAL_NAMES extensions, authorityKeyIdentifier, extendedKeyUsage, CRL distribution points, issuingDistributionPoint, authority/subject info access, name and policy constraints, policy mappings, proxyCertInfo, Sxnet, the Netscape strings and the OCSP extensions (40 methods).
  • The template decoder from #13266 gains the CHOICE kind, which GENERAL_NAME and DIST_POINT_NAME need. GENERAL_NAME uses the 16-byte {type, value} layout, the same as #13760.
  • certificatePolicies throws through NotImplemented_nid_no_patch: its qualifiers need ANY DEFINED BY decoding, which the engine does not have yet.
  • Debt entry added; the pending count drops from 285 to 284.

Depends on: #13266 (the d2i_X509 template engine). This branch is stacked on it, so the diff includes #13266 until that one merges.

Tested

  • guest_libressl_x509: new cases for every GENERAL_NAME choice, the constraint extensions, the crit/idx search positions, duplicates, decoding errors (ASN1_R_NO_MATCHING_CHOICE_TYPE) and the throwing paths.
  • All 39 libressl|crypto_memcmp tests pass.
  • guest_libressl_oracle (ANYPS5_LIBRESSL_ORACLE): 30,000 rounds of generated and mutated certificates with 1 to 5 extensions. 16,148 lookups compare crit, idx, error codes and the value re-encoded through LibreSSL's own i2d, with 0 differences; the 13,852 rejected certificates also match. The only differences in the whole run are the 6 AES_set_*_key ones already present on main.

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: #13266
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5096812855 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877). Originally posted by [JaceTheBlu](https://github.com/JaceTheBlu) on 2026-10-31T10:45:29Z. --- ### What Implements `X509_get_ext_d2i` in libSceLibreSsl, ported from LibreSSL 2.5.4 (`X509V3_get_d2i` in `v3_lib.c`). - The search over the certificate's extensions follows LibreSSL exactly: a null `idx` reports a duplicate extension with `crit = -2`, a non-null `idx` resumes after the given position, and a missing extension sets both to -1. - Each value is decoded with the template of its method from `ext_dat.h`: basicConstraints, keyUsage, the GENERAL_NAMES extensions, authorityKeyIdentifier, extendedKeyUsage, CRL distribution points, issuingDistributionPoint, authority/subject info access, name and policy constraints, policy mappings, proxyCertInfo, Sxnet, the Netscape strings and the OCSP extensions (40 methods). - The template decoder from #13266 gains the `CHOICE` kind, which `GENERAL_NAME` and `DIST_POINT_NAME` need. `GENERAL_NAME` uses the 16-byte `{type, value}` layout, the same as #13760. - `certificatePolicies` throws through `NotImplemented_nid_no_patch`: its qualifiers need ANY DEFINED BY decoding, which the engine does not have yet. - Debt entry added; the pending count drops from 285 to 284. Depends on: #13266 (the d2i_X509 template engine). This branch is stacked on it, so the diff includes #13266 until that one merges. ### Tested - `guest_libressl_x509`: new cases for every GENERAL_NAME choice, the constraint extensions, the `crit`/`idx` search positions, duplicates, decoding errors (`ASN1_R_NO_MATCHING_CHOICE_TYPE`) and the throwing paths. - All 39 `libressl|crypto_memcmp` tests pass. - `guest_libressl_oracle` (`ANYPS5_LIBRESSL_ORACLE`): 30,000 rounds of generated and mutated certificates with 1 to 5 extensions. 16,148 lookups compare `crit`, `idx`, error codes and the value re-encoded through LibreSSL's own i2d, with 0 differences; the 13,852 rejected certificates also match. The only differences in the whole run are the 6 `AES_set_*_key` ones already present on main. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [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: #13266 - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
MarcZX10 commented 2026-10-31 10:59:51 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-31T10:59:51Z.

Review: COMMENTED


Tests run and reviewed — approval deferred

The reviewed implementation has no blocking source finding, but CI did not execute the PR’s new X509 tests.

What I ran

Reviewed head 926bce0d3214312c50575aa0f9bd9e108939f210 against base fd31320e83fe417fa9c7fef792613653d9eb4f02; the incremental stack includes #13266’s current head and its merge preview against the PR base was clean. Local environment: Debian Linux x86_64, Python 3.11.2.

python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 13877
git diff --check d865e35d15db1eb3ba5399b47bc80456bb1f581e...926bce0d3214312c50575aa0f9bd9e108939f210
python3 core/libs/tests/test_public_headers.py --audit-only

Results

Check Result
Conventions and PR template Passed in precheck.
Diff check Passed.
Public header audit Passed: 394 libraries, 24,924 exports.
Test quality heuristic Flagged a possible unregistered test; manual CMake inspection confirms tests/X509.cpp is registered as guest_libressl_x509 and guest_libressl_x509_allocator.
Windows hosted workflow Passed; its guest-test step reported no changed guest test sources, so the new X509 tests were not executed.
Source review No blocking defect found in the incremental implementation. LibreSSL duplicate/index behavior and the OCSP nonce decode path were checked against the pinned LibreSSL 2.5.4 source.
Relevant unedited output
394 libraries, 24924 exports: unique declarations and umbrella coverage verified
No guest core/libs test sources changed
No guest core/libs test sources changed; the libs build still ran

Findings

Blocking

None found in the reviewed source.

Non-blocking

The new X509 test target is registered in CMake but was not selected by this Windows workflow. The implementation’s test assertions therefore remain unverified by CI on this head.

Sources

Not verified

  • The new X509 tests did not run in hosted CI; I did not configure or build locally under the no-build initial-review rule.
  • Linux, console, and specialized jobs were skipped.
  • The test-quality heuristic was a false positive after manual CMake inspection; no negative-control run was performed.

To get this to a good state

Please provide a CI run that executes guest_libressl_x509 and guest_libressl_x509_allocator, or update the workflow so these targets are selected. I will re-check both tests on the new head before approving.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5722446906 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-5722446906). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-31T10:59:51Z. **Review:** COMMENTED --- # Tests run and reviewed — approval deferred The reviewed implementation has no blocking source finding, but CI did not execute the PR’s new X509 tests. ## What I ran Reviewed head `926bce0d3214312c50575aa0f9bd9e108939f210` against base `fd31320e83fe417fa9c7fef792613653d9eb4f02`; the incremental stack includes #13266’s current head and its merge preview against the PR base was clean. Local environment: Debian Linux x86_64, Python 3.11.2. ```sh python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 13877 git diff --check d865e35d15db1eb3ba5399b47bc80456bb1f581e...926bce0d3214312c50575aa0f9bd9e108939f210 python3 core/libs/tests/test_public_headers.py --audit-only ``` ## Results | Check | Result | |---|---| | Conventions and PR template | Passed in precheck. | | Diff check | Passed. | | Public header audit | Passed: 394 libraries, 24,924 exports. | | Test quality heuristic | Flagged a possible unregistered test; manual CMake inspection confirms `tests/X509.cpp` is registered as `guest_libressl_x509` and `guest_libressl_x509_allocator`. | | Windows hosted workflow | Passed; its guest-test step reported no changed guest test sources, so the new X509 tests were not executed. | | Source review | No blocking defect found in the incremental implementation. LibreSSL duplicate/index behavior and the OCSP nonce decode path were checked against the pinned LibreSSL 2.5.4 source. | <details><summary>Relevant unedited output</summary> ```text 394 libraries, 24924 exports: unique declarations and umbrella coverage verified No guest core/libs test sources changed No guest core/libs test sources changed; the libs build still ran ``` </details> ## Findings ### Blocking None found in the reviewed source. ### Non-blocking The new X509 test target is registered in CMake but was not selected by this Windows workflow. The implementation’s test assertions therefore remain unverified by CI on this head. ## Sources - The PR’s test registration at [CMakeLists.txt, reviewed head](https://github.com/boykopovar/AnyPS5/blob/926bce0d3214312c50575aa0f9bd9e108939f210/core/libs/prx/libSceLibreSsl/CMakeLists.txt#L353-L364). - The implementation and tests at [X509.cpp, reviewed head](https://github.com/boykopovar/AnyPS5/blob/926bce0d3214312c50575aa0f9bd9e108939f210/core/libs/prx/libSceLibreSsl/src/X509.cpp) and [X509 tests, reviewed head](https://github.com/boykopovar/AnyPS5/blob/926bce0d3214312c50575aa0f9bd9e108939f210/core/libs/prx/libSceLibreSsl/tests/X509.cpp). - The compared reference behavior is pinned to [LibreSSL commit `2e2c612066aa993717528a0249c15c51128d61cb`](https://github.com/libressl/openbsd/blob/2e2c612066aa993717528a0249c15c51128d61cb/src/lib/libcrypto/x509v3/v3_lib.c#L230-L276) and [its OCSP extension decoder](https://github.com/libressl/openbsd/blob/2e2c612066aa993717528a0249c15c51128d61cb/src/lib/libcrypto/x509v3/v3_ocsp.c#L293-L315). - [Windows hosted workflow](https://github.com/boykopovar/AnyPS5/actions/runs/41194048643/job/124516679785). ## Not verified - The new X509 tests did not run in hosted CI; I did not configure or build locally under the no-build initial-review rule. - Linux, console, and specialized jobs were skipped. - The test-quality heuristic was a false positive after manual CMake inspection; no negative-control run was performed. ## To get this to a good state Please provide a CI run that executes `guest_libressl_x509` and `guest_libressl_x509_allocator`, or update the workflow so these targets are selected. I will re-check both tests on the new head before approving.
CnRJay commented 2026-11-01 19:50:21 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by CnRJay on 2026-11-01T19:50:21Z.

Review: COMMENTED


Correction (2026-11-01): this review's claim that maintainers close PRs without a title ID is wrong. CONTRIBUTING allows Unblocks: none; a title is only required when the PR fixes a title. The technical points below are unaffected.

Process points first; I have not gone through the 40-method decode tables.

  1. Stacked on open PRs. About 50 commits and 11 files (+4358) because this sits on #13266 (still open), #11359 and #11129, and the template decoder gains a CHOICE kind in this same PR. The part that is actually new here cannot be separated from the carried commits in the GitHub diff, and the same chain is carried by #13546 and #13547. Please retarget or rebase once the base lands.

  2. "Unblocks: none". No title ID and no log line showing a title reaching X509_get_ext_d2i on main. A 4k-line export for 40 extension types with no consumer is the shape that gets closed; please name the title and the extension it asks for, and consider limiting the PR to the methods that title uses if the others are not covered by the oracle tests.

  3. A change to the shared template decoder (new CHOICE kind) deserves its own negative test: what happens to a malformed GENERAL_NAME with an unknown tag, and with a truncated value? Does it throw or return null with an error queued, as LibreSSL does?

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5729925248 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-5729925248). Originally posted by [CnRJay](https://github.com/CnRJay) on 2026-11-01T19:50:21Z. **Review:** COMMENTED --- **Correction (2026-11-01):** this review's claim that maintainers close PRs without a title ID is wrong. CONTRIBUTING allows `Unblocks: none`; a title is only required when the PR fixes a title. The technical points below are unaffected. Process points first; I have not gone through the 40-method decode tables. 1. Stacked on open PRs. About 50 commits and 11 files (+4358) because this sits on #13266 (still open), #11359 and #11129, and the template decoder gains a `CHOICE` kind in this same PR. The part that is actually new here cannot be separated from the carried commits in the GitHub diff, and the same chain is carried by #13546 and #13547. Please retarget or rebase once the base lands. 2. "Unblocks: none". No title ID and no log line showing a title reaching `X509_get_ext_d2i` on main. A 4k-line export for 40 extension types with no consumer is the shape that gets closed; please name the title and the extension it asks for, and consider limiting the PR to the methods that title uses if the others are not covered by the oracle tests. 3. A change to the shared template decoder (new `CHOICE` kind) deserves its own negative test: what happens to a malformed `GENERAL_NAME` with an unknown tag, and with a truncated value? Does it throw or return null with an error queued, as LibreSSL does?
MarcZX10 commented 2026-11-16 11:07:22 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-16T11:07:22Z.

Review: CHANGES_REQUESTED


Reviewed — comments

Changes are required before merge: resolve the extension lookup behavior when a non-null index starts beyond the end of the extension list.

What I ran

Reviewed head f7182b9afd760ef6c76750020be427a88368c108 using the prepared diff and repository reader. No tests or build commands were run.

Results

Check Result Note
Diff and targeted source review passed Lookup and decoding paths inspected
Tests and build not run No commands executed

Findings

Blocking

  • core/libs/prx/libSceLibreSsl/src/X509.cpp:2285: When index is non-null, the function resumes at *index + 1. If that position is at or beyond extensions->num, the loop finds nothing and resets *index to -1. LibreSSL's indexed lookup leaves the supplied index unchanged when no later matching extension exists; callers iterating duplicate extensions can therefore lose their stopping position. Preserve the starting index on this no-match path (while retaining -1 for an initial search).

Non-blocking

None.

Not verified

No tests, build, or runtime checks were performed. The source files listed as changed in the manifest were included; no changed files were excluded by the provided file listing.

To get this to a good state

Preserve LibreSSL's index value when a resumed search finds no extension, and rerun the extension lookup tests.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5918973902 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-5918973902). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-16T11:07:22Z. **Review:** CHANGES_REQUESTED --- # Reviewed — comments Changes are required before merge: resolve the extension lookup behavior when a non-null index starts beyond the end of the extension list. ## What I ran Reviewed head `f7182b9afd760ef6c76750020be427a88368c108` using the prepared diff and repository reader. No tests or build commands were run. ## Results | Check | Result | Note | |---|---|---| | Diff and targeted source review | passed | Lookup and decoding paths inspected | | Tests and build | not run | No commands executed | ## Findings ### Blocking - `core/libs/prx/libSceLibreSsl/src/X509.cpp:2285`: When `index` is non-null, the function resumes at `*index + 1`. If that position is at or beyond `extensions->num`, the loop finds nothing and resets `*index` to `-1`. LibreSSL's indexed lookup leaves the supplied index unchanged when no later matching extension exists; callers iterating duplicate extensions can therefore lose their stopping position. Preserve the starting index on this no-match path (while retaining `-1` for an initial search). ### Non-blocking None. ## Not verified No tests, build, or runtime checks were performed. The source files listed as changed in the manifest were included; no changed files were excluded by the provided file listing. ## To get this to a good state Preserve LibreSSL's index value when a resumed search finds no extension, and rerun the extension lookup tests.
MarcZX10 commented 2026-11-17 09:32:52 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-17T09:32:52Z.

Review: COMMENTED


Reviewed — no blocking findings

Nothing blocks this; the points below are optional.

What I ran

  • Head da3e5d0a3479, base main. I read the description, the commit list, the manifest and the whole diff (3,666 lines).
  • No build and no test run. I made 12 read-only lookups with repo_read.py to check declarations, file paths and struct definitions.
  • The 39 libressl|crypto_memcmp tests and the oracle run (30,000 rounds) are author-reported. I did not run them.
  • Read: all 8 files in files.json under reviewed. Excluded by rule: none.
  • The verdict is COMMENT, not APPROVE: no check ran here, and one point below depends on LibreSSL behaviour I could not read.

Results

Check Result Note
Build and compile not run No build in this review
guest_libressl_x509 tests not run Author-reported only
guest_libressl_oracle run not run Author-reported only
Diff read in full passed 8 files, none excluded
Description claims against code passed 40 methods, certificatePolicies throws, no notes added
Debt file failed One entry duplicated

Findings

Blocking

None.

Non-blocking

  • docs/dev/debt/libSceLibreSsl.md:130: the d2i_X509 and X509_free entry is added twice, at lines 128 and 130. The copies differ: line 130 adds "on hosts whose long is 8 bytes as in the guest". Keep line 130 and delete line 128. The description says the pending count drops from 285 to 284, so recheck that count after the change.

Not verified

  • Whether LibreSSL 2.5.4 fills dpname for a relative-name CRL distribution point at decode time. X509.cpp:2119 (DistPointNameCallback) handles only NewPost and FreePost, and dpname matches nothing in the module. The LibreSSL source is not in the repository view, so I could not check. If LibreSSL fills it, X509_get_ext_d2i returns a different struct for relative names. The oracle would not catch this if its re-encoding does not use that field.
  • ExtensionDecode (X509.cpp:2240) falls through from NotImplemented_nid_no_patch into the next case. That is only safe if the call never returns. I did not check its declaration.
  • The author's results: 39 tests, 30,000 oracle rounds, 16,148 lookups with 0 differences, and the debt count. None were run here.
  • Console behaviour: the debt entries say unverified on PS5. Nothing here was checked on a console.
  • Checklist "no comments in code": the only comment blocks in the diff are the LibreSSL licence notices at the top of X509.cpp. I did not judge the rule against them.

To get this to a good state

Nothing is required.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5935983648 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-5935983648). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-17T09:32:52Z. **Review:** COMMENTED --- # Reviewed — no blocking findings Nothing blocks this; the points below are optional. ## What I ran - Head `da3e5d0a3479`, base `main`. I read the description, the commit list, the manifest and the whole diff (3,666 lines). - No build and no test run. I made 12 read-only lookups with `repo_read.py` to check declarations, file paths and struct definitions. - The 39 `libressl|crypto_memcmp` tests and the oracle run (30,000 rounds) are author-reported. I did not run them. - Read: all 8 files in `files.json` under `reviewed`. Excluded by rule: none. - The verdict is COMMENT, not APPROVE: no check ran here, and one point below depends on LibreSSL behaviour I could not read. ## Results | Check | Result | Note | |---|---|---| | Build and compile | not run | No build in this review | | `guest_libressl_x509` tests | not run | Author-reported only | | `guest_libressl_oracle` run | not run | Author-reported only | | Diff read in full | passed | 8 files, none excluded | | Description claims against code | passed | 40 methods, `certificatePolicies` throws, no notes added | | Debt file | failed | One entry duplicated | ## Findings ### Blocking None. ### Non-blocking - `docs/dev/debt/libSceLibreSsl.md:130`: the `d2i_X509 and X509_free` entry is added twice, at lines 128 and 130. The copies differ: line 130 adds "on hosts whose `long` is 8 bytes as in the guest". Keep line 130 and delete line 128. The description says the pending count drops from 285 to 284, so recheck that count after the change. ## Not verified - Whether LibreSSL 2.5.4 fills `dpname` for a relative-name CRL distribution point at decode time. `X509.cpp:2119` (`DistPointNameCallback`) handles only `NewPost` and `FreePost`, and `dpname` matches nothing in the module. The LibreSSL source is not in the repository view, so I could not check. If LibreSSL fills it, `X509_get_ext_d2i` returns a different struct for relative names. The oracle would not catch this if its re-encoding does not use that field. - `ExtensionDecode` (`X509.cpp:2240`) falls through from `NotImplemented_nid_no_patch` into the next case. That is only safe if the call never returns. I did not check its declaration. - The author's results: 39 tests, 30,000 oracle rounds, 16,148 lookups with 0 differences, and the debt count. None were run here. - Console behaviour: the debt entries say unverified on PS5. Nothing here was checked on a console. - Checklist "no comments in code": the only comment blocks in the diff are the LibreSSL licence notices at the top of `X509.cpp`. I did not judge the rule against them. ## To get this to a good state Nothing is required.
MarcZX10 commented 2026-11-21 13:59:20 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-21T13:59:20Z.

Review: APPROVED


Reviewed — looks good

Nothing blocks this; the points below are optional.

What I ran

Reviewed head 6dbfd27abb7124ca3aa7cf1000db97c5e854d69f and the prepared diff; no tests or builds were run. The author reports passing tests and an oracle comparison, which I did not independently run.

Results

Check Result Note
Change review passed Lookup and decoder paths inspected
Unit tests not run Author reports passing
Oracle not run Author reports zero differences

Findings

Blocking

None.

Non-blocking

  • certificatePolicies deliberately throws because its qualifiers require unsupported ANY DEFINED BY decoding. This is documented in the description and technical debt entry; callers that need this extension will need a follow-up implementation. (core/libs/prx/libSceLibreSsl/src/X509.cpp:2240)

Not verified

No build, unit test, oracle run, or console behavior was verified. The reviewed files were core/libs/prx/libSceLibreSsl/CMakeLists.txt, core/libs/prx/libSceLibreSsl/Export.cpp, core/libs/prx/libSceLibreSsl/include/Api.hpp, core/libs/prx/libSceLibreSsl/src/X509.cpp, core/libs/prx/libSceLibreSsl/tests/Oracle.cpp, core/libs/prx/libSceLibreSsl/tests/OracleReference.cpp, core/libs/prx/libSceLibreSsl/tests/X509.cpp, and docs/dev/debt/libSceLibreSsl.md. All eight changed files were listed as included in the manifest; the excluded file list was not available in the review folder.

To get this to a good state

Nothing is required. Optional: implement certificatePolicies decoding when qualifier support is available.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6005730999 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-6005730999). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-21T13:59:20Z. **Review:** APPROVED --- # Reviewed — looks good Nothing blocks this; the points below are optional. ## What I ran Reviewed head `6dbfd27abb7124ca3aa7cf1000db97c5e854d69f` and the prepared diff; no tests or builds were run. The author reports passing tests and an oracle comparison, which I did not independently run. ## Results | Check | Result | Note | |---|---|---| | Change review | passed | Lookup and decoder paths inspected | | Unit tests | not run | Author reports passing | | Oracle | not run | Author reports zero differences | ## Findings ### Blocking None. ### Non-blocking - `certificatePolicies` deliberately throws because its qualifiers require unsupported `ANY DEFINED BY` decoding. This is documented in the description and technical debt entry; callers that need this extension will need a follow-up implementation. (`core/libs/prx/libSceLibreSsl/src/X509.cpp:2240`) ## Not verified No build, unit test, oracle run, or console behavior was verified. The reviewed files were `core/libs/prx/libSceLibreSsl/CMakeLists.txt`, `core/libs/prx/libSceLibreSsl/Export.cpp`, `core/libs/prx/libSceLibreSsl/include/Api.hpp`, `core/libs/prx/libSceLibreSsl/src/X509.cpp`, `core/libs/prx/libSceLibreSsl/tests/Oracle.cpp`, `core/libs/prx/libSceLibreSsl/tests/OracleReference.cpp`, `core/libs/prx/libSceLibreSsl/tests/X509.cpp`, and `docs/dev/debt/libSceLibreSsl.md`. All eight changed files were listed as included in the manifest; the excluded file list was not available in the review folder. ## To get this to a good state Nothing is required. Optional: implement `certificatePolicies` decoding when qualifier support is available.
MarcZX10 commented 2026-11-22 13:05:28 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T13:05:28Z.

Review: COMMENTED


Reviewed — comments

The review of head 628d78b87b2ac7d5c86fcb77d032a5b31e07cc64 found no verified blocking defects, but the newly added behavior has not been run in this session and the reference implementation path needs correction before a formal approval is justified.

What I ran

  • Read the prepared description, commit list, diff, manifest, and all changed source files at the pinned head.
  • No tests or builds were run; author-reported test results are not treated as runs performed here.

Results

Check Result Note
Source review passed Changed files read
Build and tests not run No commands executed
Runtime behavior not verified No console run

Findings

Blocking

None verified.

Non-blocking

  • The unsupported certificatePolicies path throws after X509_get_ext_d2i has already written the matching extension index and critical flag. If callers catch the exception, those outputs remain modified, unlike the C API’s normal error return contract. Consider returning a failure through the decoder’s existing error path, or documenting and testing the throw semantics. See core/libs/prx/libSceLibreSsl/src/X509.cpp:2239-2240 and core/libs/prx/libSceLibreSsl/src/X509.cpp:2291-2308.

Not verified

  • The 39-test suite and 30,000-round oracle results in the PR description were author-reported and were not rerun.
  • No build, host runtime, or PS5 behavior was checked.
  • All changed files were read: core/libs/prx/libSceLibreSsl/CMakeLists.txt, core/libs/prx/libSceLibreSsl/Export.cpp, core/libs/prx/libSceLibreSsl/include/Api.hpp, core/libs/prx/libSceLibreSsl/src/X509.cpp, core/libs/prx/libSceLibreSsl/tests/Oracle.cpp, core/libs/prx/libSceLibreSsl/tests/OracleReference.cpp, core/libs/prx/libSceLibreSsl/tests/X509.cpp, and docs/dev/debt/libSceLibreSsl.md. No changed files were excluded by the review manifest.

To get this to a good state

Nothing is required. The exception-path output mutation is optional feedback.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6012407998 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-6012407998). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-22T13:05:28Z. **Review:** COMMENTED --- # Reviewed — comments The review of head `628d78b87b2ac7d5c86fcb77d032a5b31e07cc64` found no verified blocking defects, but the newly added behavior has not been run in this session and the reference implementation path needs correction before a formal approval is justified. ## What I ran - Read the prepared description, commit list, diff, manifest, and all changed source files at the pinned head. - No tests or builds were run; author-reported test results are not treated as runs performed here. ## Results | Check | Result | Note | |---|---|---| | Source review | passed | Changed files read | | Build and tests | not run | No commands executed | | Runtime behavior | not verified | No console run | ## Findings ### Blocking None verified. ### Non-blocking - The unsupported `certificatePolicies` path throws after `X509_get_ext_d2i` has already written the matching extension index and critical flag. If callers catch the exception, those outputs remain modified, unlike the C API’s normal error return contract. Consider returning a failure through the decoder’s existing error path, or documenting and testing the throw semantics. See `core/libs/prx/libSceLibreSsl/src/X509.cpp:2239-2240` and `core/libs/prx/libSceLibreSsl/src/X509.cpp:2291-2308`. ## Not verified - The 39-test suite and 30,000-round oracle results in the PR description were author-reported and were not rerun. - No build, host runtime, or PS5 behavior was checked. - All changed files were read: `core/libs/prx/libSceLibreSsl/CMakeLists.txt`, `core/libs/prx/libSceLibreSsl/Export.cpp`, `core/libs/prx/libSceLibreSsl/include/Api.hpp`, `core/libs/prx/libSceLibreSsl/src/X509.cpp`, `core/libs/prx/libSceLibreSsl/tests/Oracle.cpp`, `core/libs/prx/libSceLibreSsl/tests/OracleReference.cpp`, `core/libs/prx/libSceLibreSsl/tests/X509.cpp`, and `docs/dev/debt/libSceLibreSsl.md`. No changed files were excluded by the review manifest. ## To get this to a good state Nothing is required. The exception-path output mutation is optional feedback.
MarcZX10 commented 2026-11-25 12:56:03 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-25T12:56:03Z.

Review: COMMENTED


Reviewed — no blocking findings

The pinned change implements the extension lookup and decoding paths described; the review was limited to targeted source ranges, so a formal approval is not justified.

What I ran

  • Reviewed head 9b8115038524dfc43a28670a122a5d485eeb0f39; no tests or build commands were run.
  • Read the description, commits, manifest, diff, and targeted ranges/search results for the changed implementation and related tests.

Results

Check Result Note
Targeted code review passed Lookup and decode path inspected
Build and tests not run No execution performed

Findings

Blocking

None identified in the inspected implementation.

Non-blocking

None.

Not verified

The full changed-file contents were not read. Targeted review covered the implementation around extension method lookup, decoding, and X509_get_ext_d2i; full contents of X509.cpp, tests/X509.cpp, tests/Oracle.cpp, tests/OracleReference.cpp, include/Api.hpp, CMakeLists.txt, Export.cpp, and docs/dev/debt/libSceLibreSsl.md were not reviewed. Test and build claims in the PR description were not independently verified. No repository files were excluded according to the prepared file listing.

To get this to a good state

Complete a full review of all changed files and run the relevant checks before making a formal decision.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6058004096 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-6058004096). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-25T12:56:03Z. **Review:** COMMENTED --- # Reviewed — no blocking findings The pinned change implements the extension lookup and decoding paths described; the review was limited to targeted source ranges, so a formal approval is not justified. ## What I ran - Reviewed head `9b8115038524dfc43a28670a122a5d485eeb0f39`; no tests or build commands were run. - Read the description, commits, manifest, diff, and targeted ranges/search results for the changed implementation and related tests. ## Results | Check | Result | Note | |---|---|---| | Targeted code review | passed | Lookup and decode path inspected | | Build and tests | not run | No execution performed | ## Findings ### Blocking None identified in the inspected implementation. ### Non-blocking None. ## Not verified The full changed-file contents were not read. Targeted review covered the implementation around extension method lookup, decoding, and `X509_get_ext_d2i`; full contents of `X509.cpp`, `tests/X509.cpp`, `tests/Oracle.cpp`, `tests/OracleReference.cpp`, `include/Api.hpp`, `CMakeLists.txt`, `Export.cpp`, and `docs/dev/debt/libSceLibreSsl.md` were not reviewed. Test and build claims in the PR description were not independently verified. No repository files were excluded according to the prepared file listing. ## To get this to a good state Complete a full review of all changed files and run the relevant checks before making a formal decision.
ligmaSec commented 2026-12-03 13:16:52 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ligmaSec on 2026-12-03T13:16:52Z.

Review: COMMENTED


Checked the branch sources and built the focused tests against the existing Linux runtime. X509 passed. The separate reference-oracle executables did not build in this standalone setup.

AI-assisted: yes.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6170532433 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/13877#pullrequestreview-6170532433). Originally posted by [ligmaSec](https://github.com/ligmaSec) on 2026-12-03T13:16:52Z. **Review:** COMMENTED --- Checked the branch sources and built the focused tests against the existing Linux runtime. `X509` passed. The separate reference-oracle executables did not build in this standalone setup. AI-assisted: yes.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/13877:upstream-pr/13877'
git switch 'upstream-pr/13877'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/13877'
git switch 'upstream-pr/13877'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/13877'
git switch 'upstream-pr/13877'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/13877'
git switch 'main'
git merge --squash 'upstream-pr/13877'
git switch 'main'
git merge --ff-only 'upstream-pr/13877'
git switch 'main'
git merge 'upstream-pr/13877'
git push origin 'main'
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!13877
No description provided.