I'm in the early stages of building an app with MVC 5. I haven't used this version of the framework yet, nor ASP.NET Identity (I'm not even sure if that's relevant to my problem). I want to temporarily, temporarily, hard code a user in the web.config as follows:
<authentication mode="Forms">
<forms loginUrl="~/Account/Login" timeout="2880">
<credentials passwordFormat="Clear">
<user name="name" password="password"/>
</credentials>
</forms>
</authentication>
I've used that previously, and it's worked as expected. In this app, however, it's not working. In AccountController.cs
, in the method Login()
, it appears that an object of type UserManager
can't find the user I specified in web.config, probably because that object isn't looking in web.config.
So, how I do re-enable using the user specified in web.config? Please provide steps.
I completely understand that this not a good practice. It's only temporary to get something else working.