0

I am working on a MVC4 website and have been working to customize the out-of-the-box SimpleMembershipProvider and have a few questions that I wasn't able to track down in the documentation.

1) What kind of control can I have over the tables generated? For instance, is there anyway to prevent OAuth tables from being generated if you will never be using OAuth? Is it possible to simply have it work with a role field within the user table, rather than the default separate join tables?

2) Users will be authenticating via an external system. Is there anyway to override the Websecurity.Login(username, password) to simply be Webseurity.Login(username)?

Thanks in advance for any pointers or resources you can provide.

user823216
  • 23
  • 1
  • 5

1 Answers1

1

The only tables you can modify is the UserProfile. Here are instructions on how to customize UserProfile in SimpleMembership.

There is not a WebSecurity.Login method that only accepts the username. But you could get around this by just assigning everyone in the database the same internal password when you use WebSecurity.CreateUserAndAccount and then use that internal password when you use the Login method.

Kevin Junghans
  • 17,475
  • 4
  • 45
  • 62
  • Thanks Kevin. This is helpful, and you have already decided to go the route of using the same internal password for everyone. Are there any security concerns that you can think of going this route? I figure since the actual authentication is handled externally it shouldn't be a problem since there won't be any other way to login. – user823216 Jan 30 '13 at 20:52