feat(libSceLibreSsl3): implement ECDSA_do_verify #19033
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/19033"
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 fishingpvalues on 2026-11-12T16:46:38Z.
What
ECDSA_do_verifyleaves the throwingAdditionalExports.cppstub and follows LibreSSL 4.0.0ecdsa.c/ecs_lib.c: it returns 1 for a valid signature, 0 for an invalid one, and -1 for an internal error or a key without a group or public key. A null key, which LibreSSL dereferences, throwsstd::invalid_argument; a missing signature component throws; an empty or negative component, or one outside [1, order-1], returns 0; a negative digest length returns -1 and a null digest with a positive length throws. The signature components are read from the module's guest Bignums as little-endian 64-bit limbs and verified with mbedtls against the key's public point. Error-queue entries for internal failures are not modelled, which the debt entry records.The test signs through the parent
ECDSA_signand decodes the DERSEQUENCE { r, s }, then checks the valid case, a different digest, a flipped component byte, empty and negative components, the missing-component throw, and the null, no-group and no-public-key contracts.Tested
Linux x86-64 (Debian 13, glibc 2.41, GCC 14.2.0), Release,
BUILD_TESTING=ON, basemainf9c2d92b91:cmake --build build --target guest_libressl3_ecdsa_do_verify_tests --parallel 8: passed.ctest --test-dir build -R '^guest_libressl3_ecdsa_do_verify$' --output-on-failure: 1/1 passed.python3 tools/check_conventions.py --base origin/main: all checks passed.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 repositoryImported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-20T13:31:05Z.
Review: APPROVED
Reviewed — looks good
Nothing blocks this change; the implementation and its focused test are consistent with the stated contract, and the author-reported Linux checks passed.
What I ran
Reviewed head
d4596f306f2c2e6a0022c21933ddd94f193b405fagainstmain. I inspected the prepared diff and changed code throughrepo_read.py; I did not run commands or tests. The author reports a successful test build, focused CTest run, and conventions check on Linux x86-64.Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
I read all seven changed files listed in the manifest:
core/libs/prx/libSceLibreSsl3/AdditionalExports.cpp,core/libs/prx/libSceLibreSsl3/CMakeLists.txt,core/libs/prx/libSceLibreSsl3/include/Api.hpp,core/libs/prx/libSceLibreSsl3/src/EcdsaDoVerify.cpp,core/libs/prx/libSceLibreSsl3/tests/EcdsaDoVerify.cpp,docs/dev/debt/changes/feat-libressl3-ecdsa-do-verify.md, anddocs/dev/debt/changes/libressl3-20171-inventory.md. I also read the relevant BIGNUM, EC key and signature type definitions and the existing LibreSSL debt entry. Windows behavior, console behavior, and title compatibility were not verified. No precheck, negative control, or tests were run by me.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by ligmaSec on 2026-12-03T11:54:16Z.
Review: COMMENTED
Compiled the changed ECDSA wrapper with the new
EcdsaDoVerifyfixture against the existing Linux PRXs. It passed valid signature, mismatch, and missing-argument cases and checked the three expected result classes.AI-assisted: yes.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.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.