Web folder authentication

Web folder authentication

Old forum URL: forums.lhotka.net/forums/t/6050.aspx


griff posted on Wednesday, December 24, 2008

Hi

I have opted to use the PTMembership instead of the asp membership provider.  I have implemented all the members but I now notice that if I have a folder with its own web.config with...

configuration>

<system.web>

<authorization>

<deny users="?" />

<allow roles="rgsoftadmin" />

</authorization>

</system.web>

</configuration>

for instance this does not work (this does work with another web app I have that uses the asp membership provider).  It sort of makes sense to me but I can't quite think it through - how does this type of authentication work with PT membership - or rather not using the asp membership provider (I take it asp.net uses the provider to work the web.config?) - do I have to create my own Role membership for this to work etc. Anyone else come across this, has advice or even sample code!!  (on an earlier post I have mentioned that this code does not work - could this be a reason for the above.

If Csla.ApplicationContext.User.IsInRole("Unauthorised") Then

Return False

End If

Thanks

Richard

Copyright (c) Marimer LLC