You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
waldekmastykarz
changed the title
[BUG]: JWT Token cannot be validated into an ASP.NET Core Web API.
JWT Token cannot be validated into an ASP.NET Core Web API.
Oct 16, 2024
Thanks for reaching out @congiuluc. That was by design, but I agree that it's a shortcoming. We've been thinking about exposing the random string, but your suggestion in #914 to let users specify the signing key is also a very nice idea. Let's go with it.
Description
The JWT Toke created to test an ASP.NET Core Web API cannot be validated by ASP.NET Core, always get error 401
Expected behaviour
The generated token should be verified by ASP.NET Core so that is possible to test an API endpoint that requires authentication and authorization
Actual behaviour
The token is signed using a random signing key
Steps to reproduce
Generate a JWT Token, create an ASP.NET Web Minimal API and add authentication using JWT Bearer
Dev Proxy Version
0.21.0
Operating system (environment)
Windows
Shell
PowerShell
Configuration file
Command line tool: devproxy.exe jwt create -k --name "Luca Congiu" --issuer "my-app" --audience "https://myserver.com" --roles "admin" --scopes "read" --scopes "write" --claims "custom:claim" --valid-for 120
Additional Info
No response
The text was updated successfully, but these errors were encountered: