Starts in:
1 DAY
15 HRS
27 MIN
16 SEC
Starts in:
1 D
15 H
27 M
16 S
Open Closed

.Net nd ABP.IO upgrade - IDX10225: Lifetime validation failed. The token is missing an Expiration Time #7929


User avatar
0
hariom.mall@tasconnect.com created

After upgrading the application to .net 8 and ABP.IO 8.2 we are getting following error. Can you please review and help us on this.

  • ABP Framework version: v8.2.2

  • UI Type: Angular

  • Database System: EF Core (PostgreSQL, etc..)

  • Tiered (for MVC) or Auth Server Separated (for Angular): yes

  • Exception message and full stack trace: Microsoft.IdentityModel.Tokens.SecurityTokenNoExpirationException: IDX10225: Lifetime validation failed. The token is missing an Expiration Time. Tokentype: 'System.IdentityModel.Tokens.Jwt.JwtSecurityToken'. at Microsoft.IdentityModel.Tokens.ValidatorUtilities.ValidateLifetime(Nullable1 notBefore, Nullable1 expires, SecurityToken securityToken, TokenValidationParameters validationParameters) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateTokenPayload(JwtSecurityToken jwtToken, TokenValidationParameters validationParameters, BaseConfiguration configuration) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateJWS(String token, TokenValidationParameters validationParameters, BaseConfiguration currentConfiguration, SecurityToken& signatureValidatedToken, ExceptionDispatchInfo& exceptionThrown) --- End of stack trace from previous location --- at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateToken(String token, JwtSecurityToken outerToken, TokenValidationParameters validationParameters, SecurityToken& signatureValidatedToken) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateToken(String token, TokenValidationParameters validationParameters, SecurityToken& validatedToken) at Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler.HandleAuthenticateAsync()

  • Steps to reproduce the issue:


1 Answer(s)
  • User Avatar
    0
    Anjali_Musmade created
    Support Team Support Team Member

    Hello,

    Please use the latest IdentityModel packages in the HttpApi.Host project.

    <PackageReference Include="Microsoft.IdentityModel.Protocols.OpenIdConnect" Version="7.5.1" /> <PackageReference Include="Microsoft.IdentityModel.Tokens" Version="7.5.1" /> <PackageReference Include="Microsoft.IdentityModel.JsonWebTokens" Version="7.5.1" />

    Thanks,

Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06