Ryan
Ryan

Reputation: 4414

Why use ASP.NET membership provider when you can just use Repositories? Is it better security?

I just finished implementing a custom membership provider and after the whole thing was done I'm just wondering why is it nessesary?

In my project I'm using Open ID to authenticate and once I have the users Open ID I forward them right off the bat to get OAuth request/access token then log them in using forms authentication. I'm only ever using the CreateUser() and GetUser() from the membership provider.

Can I just use my own Repository to store all of the data I need (AccessToken, Username, OpenId, etc) or is there something I'm not seeing behind the scenes that I should be aware about?

Upvotes: 2

Views: 695

Answers (1)

Jonathan Wood
Jonathan Wood

Reputation: 67273

Yes, you can certainly use your own repository to store all the data you need. (In fact, you would use your own repository to store the information used by ASP.NET Membership.)

It's simply a matter of if you are willing and able to write your own code. Given that there are some security concerns, you should probably review your own design, if implemented, for security issues.

Upvotes: 2

Related Questions