473,326 Members | 2,655 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,326 software developers and data experts.

questions about membetship and role

Jo
Hi,

I know how to create membership user and to define role via "Administer
website" in design mode of e.g. an ASP.NET login control.

My questions are:
1) how to create a membership user directly in web.config?
2) how to define a role directly in web.config?
3) how to assign a existing membership user to an existing role in
web.config?
4) how to assign a new created membeship (with createuserwizard control) to
an existing role programmatically (i mean: at the moment the new account is
created in the aspx page)?
Thanks
Jo
Apr 10 '07 #1
3 2634
Jo
I just read some stuffs about this, so:
1) not possibel, must be inputted in a table
2) same answer
3) not possible; must be done via Administrate website

But for 4) i couldn't find an answer, so if you know it ... thanks in
advance.
"Jo" <qs*@qcq.dcschreef in bericht
news:OO**************@TK2MSFTNGP04.phx.gbl...
Hi,

I know how to create membership user and to define role via "Administer
website" in design mode of e.g. an ASP.NET login control.

My questions are:
1) how to create a membership user directly in web.config?
2) how to define a role directly in web.config?
3) how to assign a existing membership user to an existing role in
web.config?
4) how to assign a new created membeship (with createuserwizard control)
to an existing role programmatically (i mean: at the moment the new
account is created in the aspx page)?
Thanks
Jo

Apr 10 '07 #2
The CreateUserWizard has an event UserCreated (or similar) - here you can
use the Roles class to add the user to a role

Roles.AddUserToRole(...);
-----
Dominick Baier (http://www.leastprivilege.com)

Developing More Secure Microsoft ASP.NET 2.0 Applications (http://www.microsoft.com/mspress/books/9989.asp)
I just read some stuffs about this, so:
1) not possibel, must be inputted in a table
2) same answer
3) not possible; must be done via Administrate website
But for 4) i couldn't find an answer, so if you know it ... thanks in
advance.

"Jo" <qs*@qcq.dcschreef in bericht
news:OO**************@TK2MSFTNGP04.phx.gbl...
>Hi,

I know how to create membership user and to define role via
"Administer website" in design mode of e.g. an ASP.NET login control.

My questions are:
1) how to create a membership user directly in web.config?
2) how to define a role directly in web.config?
3) how to assign a existing membership user to an existing role in
web.config?
4) how to assign a new created membeship (with createuserwizard
control)
to an existing role programmatically (i mean: at the moment the new
account is created in the aspx page)?
Thanks
Jo

Apr 10 '07 #3
Jo
Thanks

"Dominick Baier" <dbaier@pleasepleasenospam_leastprivilege.comschre ef in
bericht news:51*************************@news.microsoft.co m...
The CreateUserWizard has an event UserCreated (or similar) - here you can
use the Roles class to add the user to a role

Roles.AddUserToRole(...);
-----
Dominick Baier (http://www.leastprivilege.com)

Developing More Secure Microsoft ASP.NET 2.0 Applications
(http://www.microsoft.com/mspress/books/9989.asp)
>I just read some stuffs about this, so:
1) not possibel, must be inputted in a table
2) same answer
3) not possible; must be done via Administrate website
But for 4) i couldn't find an answer, so if you know it ... thanks in
advance.

"Jo" <qs*@qcq.dcschreef in bericht
news:OO**************@TK2MSFTNGP04.phx.gbl...
>>Hi,

I know how to create membership user and to define role via
"Administer website" in design mode of e.g. an ASP.NET login control.

My questions are:
1) how to create a membership user directly in web.config?
2) how to define a role directly in web.config?
3) how to assign a existing membership user to an existing role in
web.config?
4) how to assign a new created membeship (with createuserwizard
control)
to an existing role programmatically (i mean: at the moment the new
account is created in the aspx page)?
Thanks
Jo


Apr 10 '07 #4

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

Similar topics

2
by: Ken Varn | last post by:
I have a couple questions/comments concerning dot net and the future of dot net development. If someone could address these, please do so. First of all, with the advent of .net and the use of...
6
by: craig | last post by:
I have two questions that aren't necessarily C#-related, but I think there are many people in this forum who have some insight into these concepts, so I thought I would ask anyway: 1. Assume...
6
by: John Lee | last post by:
Hi, I was trying to find an elegant way of implementing/modelling the following scenario: student, borrower, reference and cosigner are all human beings - we would think to create a person...
1
by: Craig Buchanan | last post by:
I am using flag as the identifier for various security settings. For instance: Public Enum SecurityEnum Read=0 Write=1 Delete=2 ... End Enum
0
by: The Confessor | last post by:
I'm relatively new to using FileStreams, so bear with me. I'm trying to use the following code Dim MapGraphicsFileStream As New System.IO.FileStream(MapGraphicsFile, System.IO.FileMode.Create)...
4
by: cybertoast | last post by:
i seem to have some misunderstanding about how roles work in sql server 2005. i see that i can add a role to a database (dbname->->properties->permissions->. THis allows me to add either users or...
3
by: djc | last post by:
I have a couple questions about authentication and authorization in asp.net 2.0. 1) I see there are still the same authentication mode options as in 1.1 (windows, forms, or passport). However in...
22
by: gustum | last post by:
Im graduating in the coming december. Anyone pls guide me where i can get c++ interview questions. I shall be very thankful to you if you provide me good link so any stuff if you have regarding...
0
by: deshaipet | last post by:
Hi - We have primary and standby databases on different servers. Here is my /etc/service entry for HADR pair : On Primary : "vi /etc/services
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.