Skip to content

Add support for ECDSA signatures - #99

Open
tvdijen wants to merge 7 commits into
masterfrom
feature/ecdsa
Open

tvdijen wants to merge 7 commits into
masterfrom
feature/ecdsa

Conversation

@tvdijen

@tvdijen tvdijen commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

@codecov

codecov Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 60.00000% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.23%. Comparing base (1ccb48d) to head (c129980).

Additional details and impacted files
@@             Coverage Diff              @@
##             master      #99      +/-   ##
============================================
- Coverage     93.33%   93.23%   -0.11%     
- Complexity      908      915       +7     
============================================
  Files           133      134       +1     
  Lines          3287     3297      +10     
============================================
+ Hits           3068     3074       +6     
- Misses          219      223       +4     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@monkeyiq

monkeyiq commented Nov 3, 2026

Copy link
Copy Markdown

If we set C::SIG_ECDSA_SHA1 = 0 then we can directly pass $this->sig_padding to openssl_verify.

If we are wanting to retain that as null then perhaps setting a local $padding in src/Backend/OpenSSL methods to call openssl_verify et al would be better? I think having only one call to the openssl method with parameters that are setup beforehand is clearer than having two calls. There might be a PHP version thing that makes the current code cleaner that I have missed.

Sort of a nitpick but I like to try to make underlying API calls use parameters that are setup rather than having two code paths that might diverge.

I have tested the 0 way with

 phpunit -c phpunit.xml tests/XML/SignedElementTest.php --filter testSuccessfulVerifyingEcdsaSignature

and wider to all tests and it doesn't seem to break anything here.

@monkeyiq

This comment was marked as resolved.

@tvdijen

tvdijen commented Nov 3, 2026

Copy link
Copy Markdown
Member Author

Thanks @monkeyiq ! I didn't realize that worked. Much better now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants