473,406 Members | 2,705 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Membership & Roles in 2.0

I have several questions regarding the Membership and Roles mechanism in
ASP.Net 2.0.

1. In the box, it comes with SqlMembershipProvider, which uses SQL Express
2005. What if I want it to use SQL Server 2005 Enterprise (not express)
instead? I'm really hoping I don't have to write my own MembershipProvider to
accomplish this.

2. My users have more information about them than the in the box data. For
example, I will need to know what jurisdiction a user belongs to, and of
course when they register they will pick from a list. There is much more than
that I need to store about my users that will affect their access to certain
resources (pages), etc. Gawd, I hope I don't have to write my own
MembershipProvider.

3. My last question is related to roles. I will need more information about
roles than is provided in the box. For example, a role may have to tell my
application to behave differently depending on some attribute of the role.
Jeeze, I hope I don't have to write my own MembershipProvider!

So can I do all these modifications with the "in the box" features?

--
-Demetri
May 18 '06 #1
2 1223
I'd suggest you review carefully, the information at this Scott Guthrie's blog entry:

http://weblogs.asp.net/scottgu/archi...24/438953.aspx

Your questions are answered in that blog entry.


Juan T. Llibre, asp.net MVP
aspnetfaq.com : http://www.aspnetfaq.com/
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
===================================
"Demetri" <De*****@discussions.microsoft.com> wrote in message
news:51**********************************@microsof t.com...
I have several questions regarding the Membership and Roles mechanism in
ASP.Net 2.0.

1. In the box, it comes with SqlMembershipProvider, which uses SQL Express
2005. What if I want it to use SQL Server 2005 Enterprise (not express)
instead? I'm really hoping I don't have to write my own MembershipProvider to
accomplish this.

2. My users have more information about them than the in the box data. For
example, I will need to know what jurisdiction a user belongs to, and of
course when they register they will pick from a list. There is much more than
that I need to store about my users that will affect their access to certain
resources (pages), etc. Gawd, I hope I don't have to write my own
MembershipProvider.

3. My last question is related to roles. I will need more information about
roles than is provided in the box. For example, a role may have to tell my
application to behave differently depending on some attribute of the role.
Jeeze, I hope I don't have to write my own MembershipProvider!

So can I do all these modifications with the "in the box" features?

--
-Demetri

May 18 '06 #2
A1.) The default SqlMembershipProvider is declared in machine.config. We
over-ride the default by declaration in web.config located in the root of
the application. Then we wire up a connection string and poof! It starts
working.

A2.) The same applies to using Profiles for persistant storage of user data
such as a jurisdiction. Profiles are implemented through Membership. The
method data is stored by default in aspnet_Profiles is not query friendly.
You're advised to study the Table Profile Provider which I've just learned
about myself.

A3.) We can create and assign a role such as A-1.0.2 and take each character
apart for introspection and applied semantics. If that's what you mean by
"attributes" applied to a role that is how I would think -- as if the name
of a role is structured like an alphanumeric part number -- but only if I
needed to forget to keep it simple stupid.

Don't fret about writing your own providers. Most of what you need to do is
read more like Juan suggested noting Gus blog contains a compendium of
related URL resources.

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/
"Demetri" <De*****@discussions.microsoft.com> wrote in message
news:51**********************************@microsof t.com...
I have several questions regarding the Membership and Roles mechanism in
ASP.Net 2.0.

1. In the box, it comes with SqlMembershipProvider, which uses SQL Express
2005. What if I want it to use SQL Server 2005 Enterprise (not express)
instead? I'm really hoping I don't have to write my own MembershipProvider
to
accomplish this.

2. My users have more information about them than the in the box data. For
example, I will need to know what jurisdiction a user belongs to, and of
course when they register they will pick from a list. There is much more
than
that I need to store about my users that will affect their access to
certain
resources (pages), etc. Gawd, I hope I don't have to write my own
MembershipProvider.

3. My last question is related to roles. I will need more information
about
roles than is provided in the box. For example, a role may have to tell my
application to behave differently depending on some attribute of the role.
Jeeze, I hope I don't have to write my own MembershipProvider!

So can I do all these modifications with the "in the box" features?

--
-Demetri

May 19 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: AC | last post by:
Hi there. My asp.net 2.0 development website uses roles to control access to sections of my site, configured using the asp.net configuration tool, which is great. Except that isn't available once...
3
by: Glenn | last post by:
My current classic-ASP site has users, projects, roles and the 2.0 membership looks like a perfect fit, but I'm having trouble finding examples of how to have users that belong to different...
1
by: =?Utf-8?B?ZVByaW50?= | last post by:
Asp.Net v2.0 I have created a web application and I am using it from a single website and database. The web application has different ‘portals’ – each independent and I am using the...
2
by: DanWeaver | last post by:
I am trying to use a MySQL db hosted on a shared server as an ASP.NET Membership Provider and .net framework 3.5 (visual studio 2008) I am new to a lot of this and have found the following websites...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.