Re: Help in forms authentication
From: Dominick Baier [DevelopMentor] (dbaier_at_pleasepleasenospamdevelop.com)
Date: 11/23/05
- Next message: Wizard!: "Passing user credentials to another server...?"
- Previous message: Dominick Baier [DevelopMentor]: "Re: Help in forms authentication"
- Maybe in reply to: Dominick Baier [DevelopMentor]: "Re: Help in forms authentication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Wed, 23 Nov 2005 08:39:57 -0800
Hello JessyEzzy,
do something like this:
<location path="SecuredPage.aspx">
<system.web>
<authorization>
<allow user="Alice" />
<deny users="*" />
</authorization>
</system.web>
</location>
Alice is not included in the ACLs for the rest your app..
---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com
> Ok, but how will I specify that the user with the specific credentials
> will only have access to one page of the web site.
> ===========================================
>
> "Dominick Baier [DevelopMentor]" wrote:
>
>> Hello JessyEzzy,
>>
>> you could use the <credential> element (a child of <forms>)
>>
>> in this element you can put usernames and passwords (you should use
>> hashed passwords)
>>
>> also look at FormsAuthentication.HashPasswordForStoringInConfigFile
>> and FormsAuthentication.Authenticate
>>
>> ---------------------------------------
>> Dominick Baier - DevelopMentor
>> http://www.leastprivilege.com
>>> I am using forms authentication against a database
>>>
>>> <authentication mode="Forms">
>>> <forms name="MyFormsAuthentication" loginUrl="login.aspx" path="/"
>>> protection="All" timeout="20" />
>>> </authentication>
>>> <authorization>
>>> <deny users="?" />
>>> </authorization>
>>> I have a requirment for a type of login where the account info, will
>>> be hard coded and don't come from the database, and that specific
>>> account will have access to only one page and won't be able to
>>> access
>>> any other page, how can I implement that?
>>> Thanks in advance.
>>>
- Next message: Wizard!: "Passing user credentials to another server...?"
- Previous message: Dominick Baier [DevelopMentor]: "Re: Help in forms authentication"
- Maybe in reply to: Dominick Baier [DevelopMentor]: "Re: Help in forms authentication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|