Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC

Activities of "kasem"

I was able to reproduce now. I launched the backend in debugging mode and I run frontend 32min later (npm start)

Hi @maliming

I can't reproduce in 30seconds. It takes more time and I don't know the exact time. I feel like 30+mins

Thank you for your feedback.

The problem that this exception doesn't only redirects to login. It requires resetting browser cache or closing the whole browser after re-executing app. It happens to me locally but my users in production reported the same case. App crashes for them when it's idle for sometime. I can't see this exception in log maybe because it's sort of an unhandled exception so it's swallowed up by the system.

Hi!

Sorry for the late reply. Attaching the requested

It turns out that this a very serious problem as it's related to many tickets I created here that haven't been closed yet. It wasn't clear that this problem is serious to that extent. The side-effect of this problem is seriously impacting my production app due to many related crashes happening everyday. I've recently discovered that crashes in production are happening with users leaving app idle for sometime (~30min) exactly as it happens to me in development mode. Appreciate your support to help fixing this urgently.

Stack trace: at Microsoft.IdentityModel.Tokens.Validators.ValidateLifetime(Nullable1 notBefore, Nullable1 expires, SecurityToken securityToken, TokenValidationParameters validationParameters) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateLifetime(Nullable1 notBefore, Nullable1 expires, JwtSecurityToken jwtToken, TokenValidationParameters validationParameters) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateTokenPayload(JwtSecurityToken jwtToken, TokenValidationParameters validationParameters) at System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ValidateToken(String token, TokenValidationParameters validationParameters, SecurityToken& validatedToken) at MyApp.Web.Authentication.JwtBearer.MyAppJwtSecurityTokenHandler.ValidateToken(String securityToken, TokenValidationParameters validationParameters, SecurityToken& validatedToken) in C:\code\MyApp\aspnet-core\src\MyApp.Web.Core\Authentication\JwtBearer\MyAppJwtSecurityTokenHandler.cs:line 40 at Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler.<HandleAuthenticateAsync>d__6.MoveNext()

AspNetCore + Angular v7.2.3

Thanks for your feedback.

I have the following values:

public static TimeSpan AccessTokenExpiration = TimeSpan.FromDays(1); public static TimeSpan RefreshTokenExpiration = TimeSpan.FromDays(365);

I'm getting this (in dev) multiple times a day. Fixing this requires closing browser and restarting app.

Note: I've been struggling a crash on production without any logs. Do you think this can be related?

Thanks a lot @ismcagdas for your great support!!

Thanks for your quick response.

The problem that app is working properly locally but corrupted when deploying the published version to production.

How can I identify the problem if everything is working fine locally?

Please note that I use same configuration file for the last version and it works fine

Also I can't find app.AddScope or app.AddSingleton in Startup file. Did I miss anything?

Note that the following configurations have been added to web.config:

  &lt;environmentVariables&gt;
    &lt;environmentVariable name=&quot;ASPNETCORE_ENVIRONMENT&quot; value=&quot;Development&quot; /&gt;
    &lt;environmentVariable name=&quot;COMPLUS_ForceENC&quot; value=&quot;1&quot; /&gt;
  &lt;/environmentVariables&gt;
  

I changed Development to Production in the deployed version. I also tried it with Development but got other errors related to corrupted appsettings I think.

Aha! Fixed now. I'll deploy soon and update you

Thanks a lot

Oh you are right! seems I missed the other code snippet that runs Swagger. Although the first statement made Swagger inaccessible in production the second if statement isn't available in my code yet. Do you think this is what causing that error?

Showing 21 to 30 of 80 entries