开发者

Mono, ASP.NET Membership provider and Guids

I want to build an ASP.NET site using Mono and a non SQL Server database like Postgres or MySQL. ASP.NET uses Guids in their membership providers for UserIds, and so forth, and Postgres/MySQL don't deal so well with Gu开发者_JAVA技巧ids.

What is the most common approach to dealing with Membership providers in Mono, so that user ids can be stored efficiently in the non SQL server database?


It is not a compulsion to to use Guid for userId in membership provider. You will be using official .Net providers. Both (Mysql and Postgres) have well maintained .Net providers. MySql provider has support for membership provider, so if you are using MySql you don't have to worry about Guid. I'm not sure about Postgres.

Anyway you can always implement your own membership provider, which I think is the best solution.


I'm not sure this is a common approach in Mono, but you might want to look at the Altairis Web Security Toolkit on CodePlex. It uses a simplified SQL model that doesn't include Guids. It should be easily adaptable to open source DB's such as MySQL and Postgres with its simple approach.

Altairis Web Security SQL Table Providers

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜