Ask a Question related to ASP.NET Security, Design and Development.
-
alexb #1
IsInRole doesn't works correctly
In my ASP.NET Application i check whether user that opens application is a
member of my created Windows Group(Managers).
if (Context.User.IsInRol(@"MyCompName\Managers"))
{
TextBox1.Text="OK";
}
If i use Integrated Windows Authentication in IIS all OK but with Basic
Authentication i have a problem.
What is a problem:
When i first time open my application, the Basic Authentication Form is
appear.
I enter login and password of user that in my "Managers" local windows group
and IsInRol works correctly.
I close Internet Explorer. Remove this user from my "Managers" group and try
again to open my application in hope
to get IsInRol=False, but i get True.
Only after restart IIS I get correctly result.
Why it's works so and how can i resolve this problem because i need use
Basic Authentication
Thanks.
alexb Guest
-
Progressbar works, loaded movie fails to run correctly.
Hi, Maybe this is a noob problem but here it goes anyway: I'm using a loader movie (load.swf) to load my main moviefile.(main.swf) (with a... -
isInrole
I am using isInRole function to check if a user is in a group. It works ok except it will suddenly stop working and I will have to reboot to get it... -
Problems with IsInRole
I'm having problems with WindowsPrincipal.IsInRole. It's returning false when it should return true. I've written some test code that uses... -
isInRole doesn't work for one user, but works for everyone else
I have an ASP.NET/C# application in which I verify that the current user is a member of a list of roles before giving them access to particular... -
Help with IsInRole
Hi, I am using windows integrated authentication aon my intranet. How do I check if a user is a member of a group in active directory. I have the... -
Alek Davis #2
Re: IsInRole doesn't works correctly
Alex,
There seems to be a problem (and possibly not one) with IsInRole
functionality.Check this thread:
[url]http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=O1wmwtE7CHA.2156%40TK2MSFTNGP12.phx.gbl& rnum=1&prev=/groups%3Fhl%3Den%26lr%3D%26ie%3DUTF-8%26oe%3DUTF-8%26selm%3DO1wmwtE7CHA.2156%2540TK2MSFTNGP12.phx.g bl%26rnum%3D1[/url]
(or [url]http://tinyurl.com/2e2lm[/url]). I am not sure if I understand this correctly,
but it seems to me that Basic Authentication is prone to caching problems.
For example, if you call a Web Service programmatically passing valid basic
credentials (which will establish a connection), the close the connection,
and try the exactly same operation using wrong credentials, the operation
will not fail (it will fail after a 30-minute - or so - timeout, though).
See if Keith Brown's approach helps you (please post the solution if you
find one).
Alek
"alexb" <alexb@ness-isi.com> wrote in message
news:eqKbMipNEHA.3988@TK2MSFTNGP09.phx.gbl...group> In my ASP.NET Application i check whether user that opens application is a
> member of my created Windows Group(Managers).
>
> if (Context.User.IsInRol(@"MyCompName\Managers"))
> {
> TextBox1.Text="OK";
> }
>
> If i use Integrated Windows Authentication in IIS all OK but with Basic
> Authentication i have a problem.
> What is a problem:
> When i first time open my application, the Basic Authentication Form is
> appear.
> I enter login and password of user that in my "Managers" local windowstry> and IsInRol works correctly.
>
> I close Internet Explorer. Remove this user from my "Managers" group and> again to open my application in hope
> to get IsInRol=False, but i get True.
>
> Only after restart IIS I get correctly result.
>
> Why it's works so and how can i resolve this problem because i need use
> Basic Authentication
>
> Thanks.
>
>
Alek Davis Guest
-
alexb #3
Re: IsInRole doesn't works correctly
You understand me correctly.
If i remove user from windows group after first logon to my site, IsInRole
works not correctly because Basic Authentication is prone to caching user
token data.
"Alek Davis" <alek_xDOTx_davis_xATx_intel_xDOTx_com> wrote in message
news:eUf1umeOEHA.1340@TK2MSFTNGP12.phx.gbl...[url]http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=O1wmwtE7CHA.2156%40TK2MSFTNGP12.phx.gbl& rnum=1&prev=/groups%3Fhl%3Den%26lr%3D%26ie%3DUTF-8%26oe%3DUTF-8%26selm%3DO1wmwtE7CHA.2156%2540TK2MSFTNGP12.phx.g bl%26rnum%3D1[/url]> Alex,
>
> There seems to be a problem (and possibly not one) with IsInRole
> functionality.Check this thread:
>correctly,> (or [url]http://tinyurl.com/2e2lm[/url]). I am not sure if I understand thisbasic> but it seems to me that Basic Authentication is prone to caching problems.
> For example, if you call a Web Service programmatically passing valida> credentials (which will establish a connection), the close the connection,
> and try the exactly same operation using wrong credentials, the operation
> will not fail (it will fail after a 30-minute - or so - timeout, though).
> See if Keith Brown's approach helps you (please post the solution if you
> find one).
>
> Alek
>
> "alexb" <alexb@ness-isi.com> wrote in message
> news:eqKbMipNEHA.3988@TK2MSFTNGP09.phx.gbl...> > In my ASP.NET Application i check whether user that opens application is> group> > member of my created Windows Group(Managers).
> >
> > if (Context.User.IsInRol(@"MyCompName\Managers"))
> > {
> > TextBox1.Text="OK";
> > }
> >
> > If i use Integrated Windows Authentication in IIS all OK but with Basic
> > Authentication i have a problem.
> > What is a problem:
> > When i first time open my application, the Basic Authentication Form is
> > appear.
> > I enter login and password of user that in my "Managers" local windows> try> > and IsInRol works correctly.
> >
> > I close Internet Explorer. Remove this user from my "Managers" group and>> > again to open my application in hope
> > to get IsInRol=False, but i get True.
> >
> > Only after restart IIS I get correctly result.
> >
> > Why it's works so and how can i resolve this problem because i need use
> > Basic Authentication
> >
> > Thanks.
> >
> >
>
alexb Guest



Reply With Quote

