IdentityModel icon indicating copy to clipboard operation
IdentityModel copied to clipboard

Update Nuget packages and implement new EdDsaSignatureProvider.Verify function

Open NzKyle opened this issue 2 years ago • 1 comments

This is a new version of #9.


This PR does a few things:

Updated all Nuget packages to their latest versions.

Implements a new Verify(byte[] input, int inputOffset, int inputLength, byte[] signature, int signatureOffset, int signatureLength) override in EdDsaSignatureProvider as well as a corresponding Verify function in EdDsa.

The new Verify function was added into Microsoft.IdentityModel.Tokens.SignatureProvider in the following PR - and was causing validation failures when validating signatures on tokens signed with EdDSA.

I also implemented some tests to confirm that new functionality is working as expected.

As a side note I noticed that 6 of the PasetoTestVectors.ValidateToken_ExpectCorrectResult tests are failing when I run them locally - these were failing before I upgraded any nuget packages - and continue to fail after the update - so I didn't make any changes to them.

image

NzKyle avatar Sep 16 '22 19:09 NzKyle

@scottbrady91 - with regards to your question on #9 - the new method in Microsoft.IdentityModel was added in version 6.23.0.

The tests that were failing on the v2 branch are also failing on the master branch.

NzKyle avatar Sep 16 '22 20:09 NzKyle

Hello, @NzKyle @scottbrady91 is there any way I could help pushing this further? Really looking forward to have this change merged :)

dandry avatar Oct 14 '22 06:10 dandry

Hi both, sorry for the delay. I'll merge this one in this weekend. Since this is a breaking change (it's not backward compatible with older versions of Microsoft.IdentityModel), I'll release a v3 of this library asap.

scottbrady91 avatar Oct 22 '22 10:10 scottbrady91