question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could not load type 'System.Security.Cryptography.ECParameters'

See original GitHub issue

Hi,

When I update my app with IdentityModel.OidcClient with 3.1.2 version which is using .NET 4.6.1, I am able to login but after login I get this error:

Error validating identity token: System.TypeLoadException: Could not load type 'System.Security.Cryptography.ECParameters' from assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'.
   at IdentityModel.OidcClient.IdentityTokenValidator.ValidateSignature(String identityToken, JwtSecurityTokenHandler handler, TokenValidationParameters parameters)
   at IdentityModel.OidcClient.IdentityTokenValidator.<ValidateAsync>d__4.MoveNext()

Any thoughts on this? Let me know.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
leastprivilegecommented, May 21, 2020

Oh - and being said. Check out the latest preview. I separated JWT validation from the core OidcClient. IOW - you could plugin whatever crypto lib you want.

0reactions
github-actions[bot]commented, Feb 20, 2021

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Could not load type 'System.Security.Cryptography. ...
I'm Azure Functions for about an year, and today it started to give me the following error message: Could not load type 'System.Security....
Read more >
Could not load type 'System.Security.Cryptography. ...
When trying some simple tests I got the error message: Message: Test method (method name) threw exception: System.TypeLoadException: Could not ...
Read more >
Could not load type 'System.Security.Cryptography. ...
Message: System.TypeLoadException: Could not load type 'System.Security.Cryptography.IncrementalHash' from assembly 'System.Security.
Read more >
PowerShell 7.2.7 and Could not load type 'System.Security ...
When you have PowerShell 7.* installed and you want to install Azure AD module and connect to Azure AD, the install goes OK....
Read more >
CyberArk.AIM.NetPasswordSDK.Exceptions.PSDKException
CyberArk.AIM.NetPasswordSDK.Exceptions.PSDKException: Could not load type 'System.Security.Cryptography.SHA256Cng' from assembly 'System.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found