Not able to validate JSON Web Token with .NET – key too short

前端 未结 3 1018
清歌不尽
清歌不尽 2021-01-03 11:56

I have used JSONWebToken npm module to generate a jwt:

var jwt = require(\'jsonwebtoken\');

var payload = {
    \"iss\": \"https://secure.examp         


        
3条回答
  •  挽巷
    挽巷 (楼主)
    2021-01-03 12:27

    Correct about the key not being less that 128 bits, since support is only for AES that is the minimum.

    You can use your own SignatureProvider.

    I also think you are using older bits. Have a look at the latest. http://www.nuget.org/packages/System.IdentityModel.Tokens.Jwt/

    If you have any issues, let me know.

提交回复
热议问题