I have separated the Models into Specific project
After that MVC default [Authorize] attribute not working in my application
When i try to login the application it is not login the application nor it is redirecting to the specific page
Check if you have removed the forms authorization module. Some of the new templates remove forms authorization by default. If it has been removed, comment it out. It will look like this in your web.config:
<remove name="FormsAuthentication" />
I found this question looking for a very similar error, so I thought it would be good to post my solution.
Do you have something like this
<authentication mode="Forms">
<forms loginUrl="~/Account/Login" timeout="2880" />
</authentication>
in your web.config?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With