n-tier Architecture and IIS

  • Thread starter Thread starter Curt
  • Start date Start date
C

Curt

I'm trying to set up Single Sign On authentication between several web
apps on our site. I'm thinking of doing this in an n-tier design with
some kind of COM object keeping track of session information, etc.

If I were to use a COM object that resided in IIS outside of my web
apps, how would I do that and/or where would I put it?

In other words, let's say I write a COM object that does all the
authentication I was talking about. I'd want to instantiate it at the
top of every page of my web apps in both .NET and Cold Fusion. Where
would that object reside and how would I point to it in my code?
 
Curt said:
I'm trying to set up Single Sign On authentication between several web
apps on our site. I'm thinking of doing this in an n-tier design with
some kind of COM object keeping track of session information, etc.

If I were to use a COM object that resided in IIS outside of my web
apps, how would I do that and/or where would I put it?

In other words, let's say I write a COM object that does all the
authentication I was talking about. I'd want to instantiate it at the
top of every page of my web apps in both .NET and Cold Fusion. Where
would that object reside and how would I point to it in my code?

By default the COM object would be instantiated in the calling process. For
..NET this is ASPNET_WP and for ColdFusion (assuming ColdFusion runs as an
ISAPI extension) either in inetinfo.exe or a dllhost.exe process (depending
on the isolation level).

If you want all the COM objects created in one place, and perhaps able to
talk to each other, install it in COM+ as a server application. Then all
the instances of this COM type will be created in a single dllhost process,
and if you implement the COM object in .NET, you can easilly share static
data among the instances, so that a user's session could effectively span
ColdFusion and .NET.

David
 
I'm sort of following you. Do you know where there are any white papers
that might describe this process from start to finish?
 
Let's say I create an IIS server extension in VB. What directory do I
put it in so that my applications will know it's there?
 
Curt Emich said:
Let's say I create an IIS server extension in VB. What directory do I
put it in so that my applications will know it's there?

Ok, I think I misunderstood your question. You just want to run the same
piece of code from VB or ColdFusion. That's easy. Just write a COM
component in VB6 VB.NET or C++ ATL and register it on the server. The COM
regisration goes into the registry and then all the applications can find
the component. (if it's a .NET component registered for COM interop either
install it into the GAC or use the /codebase option when registering it)

David
 
Thanks for the feedback.

Will Cold Fusion be able to recognize components created in .NET
residing in the GAC?
 
I tried to instantiate the object I created using CreateObject in
another VB.NET app. Apparently, that's not the way to do things,
because I got the message "Cannot create ActiveX Control".

I tried to use "New", but I couldn't see the object in the Intellisense
list. I know it's registered in the registry, but I can't seem to get
to it.

Any ideas?
 
Curt Emich said:
I tried to instantiate the object I created using CreateObject in
another VB.NET app. Apparently, that's not the way to do things,
because I got the message "Cannot create ActiveX Control".

I tried to use "New", but I couldn't see the object in the Intellisense
list. I know it's registered in the registry, but I can't seem to get
to it.

Any ideas?

If you want to access it from VB.NET, then set a reference to the dll. You
should use CreateObject only from non-.net COM clients. You can always test
using VBScript (an unmanaged COM client) instead of VB.NET.

David
 
Back
Top