security & cache on web farm

Topics: Caching Application Block , Security Application Block
Nov 20, 2007 at 11:00 PM
I've a few questions. Pls help & suggest

- We can't see the authentication folder when configuring the Security Application Block in Enterprise Library 2007. Can't we extend the authenticationProvider in the EntLib 2007 anymore? Or something 's wrong with my VS2005?

- If we want to do authenticatation with LDAP (not Window AD), should we write MySelfAuthenticationProvider? Or should I use from any existing componenet (which I'm not aware of)

- Can we use the Security Cache on the web farm? I read on another discussion. It said that the Cache Application Block is not for sharing cache data on the different machines. From the example, it stores user token in the cache on one machine. If the request comes to the another machine, it would find the token in the cache. How do we resolve this problem?

(From the document)
ISecurityCacheProvider cache;
cache = SecurityCacheFactory.GetSecurityCacheProvider("Caching Store Provider");
IIdentity identity = null;
if (Membership.ValidateUser("username", "password"))
{
identity = new GenericIdentity("username", Membership.Provider.Name);
}
IToken token = null;
if (identity != null)
{
token = cache.SaveIdentity(identity);
}

-

Thank you for you help in advance.
Jake

Nov 22, 2007 at 11:28 AM
Hi,

Answers inline.


- We can't see the authentication folder when configuring the Security Application Block in Enterprise Library 2007. Can't we extend the authenticationProvider in the EntLib 2007 anymore? Or something 's wrong with my VS2005?

Authentication support has been removed from EntLib since the January 2006 release, as similar features are provided by the .NET platform. You can look at the "Design of the Security Application Block" (ms-help://ms.EntLib.2007May/EnterpriseLibrary/html/07-110-Design_of_the_Security_Application_Block.htm) for an overview. Note that while the authentication features are implemented in the System.Web assemblies, they can still be used on other apps; you can look at the security block's quickstarts for details.

- If we want to do authenticatation with LDAP (not Window AD), should we write MySelfAuthenticationProvider? Or should I use from any existing componenet (which I'm not aware of)?
You should learn how to do LDAP authentication with the membership mechanism. AFAIK there is not such ldap provider out of the box; you should try the asp.net forums.

- Can we use the Security Cache on the web farm? I read on another discussion. It said that the Cache Application Block is not for sharing cache data on the different machines. From the example, it stores user token in the cache on one machine. If the request comes to the another machine, it would find the token in the cache. How do we resolve this problem?

The caches are not distributed.

Fernando