Last post Mar 31, 2014 09:41 PM by danielnbarros
Mar 29, 2014 05:35 PM|danielnbarros|LINK
Hi, I created new website using ASP.NET MVC5 using Invidual User Accounts authentication and it works fine when running on IIS Express (VS2013) but when i publish it, the user gets logged out after 5 minutes away.
I've tested, and it's not about running on debug or release, locally it works fine for both.
To test, I created a test project with this configurations and only changed the web.config to use Full Trust, but that was all i changed.
I'm hosting this website at GoDaddys.
I've tried changing the ExpirationTime, but it didnt make any difference.
BTW, I'm not using External Authentication.
Does anyone have any clue what could I try to fix it?
Mar 29, 2014 06:01 PM|BrockAllen|LINK
Do you have a <machineKey> set in the .config? The reason I ask is that perhaps in that hosted environment you're getting an app domain recycle after the inactivity and then a new app domain with a new auto generated machine key when you make your next request
and then the validation of the cookie fails.
Just a guess and worth testing out.
Mar 31, 2014 09:41 PM|danielnbarros|LINK
That fixed the problem!!!