Google Answers Logo
View Question
 
Q: IIS ISAPI ASP interaction ( Answered 3 out of 5 stars,   0 Comments )
Question  
Subject: IIS ISAPI ASP interaction
Category: Computers
Asked by: macwinux-ga
List Price: $10.00
Posted: 11 Dec 2002 18:23 PST
Expires: 10 Jan 2003 18:23 PST
Question ID: 123400
How do I Access ASP-Session variables from an ISAPI filter ? 

(I'm trying to scheme out an authentication mechanism for file
accesses on a web server)
Answer  
Subject: Re: IIS ISAPI ASP interaction
Answered By: theta-ga on 13 Dec 2002 11:22 PST
Rated:3 out of 5 stars
 
Hi macwinux-ga,
          Unfortunately, it is not possible to directly access ASP
session variables from an ISAPI filter. This is because the ISAPI dll
and the ASP application run in different application contexts.
           However, the following article from a backissue of MIND
magazine, describes how you can create a DLL that contains both an
ISAPI interface and a COM object. Within the DLL it is possible to
share variables and values between ISAPI and ASP, and there are
several ways to synchronize the ASP Session object with the ISAPI
interface. You will have to protect the shared variables with
synchronization objects such as mutexes or critical sections. You can
view the article and download the relevant source code from :
           - Tips and Tricks for ISAPI Programming
              by Christian Gross 
             [ Microsoft Internet Developer, July 1997]
             ( http://www.microsoft.com/mind/0797/ISAPItips.asp )

If the above approach doesn't work for you, then you might have to
rethink your strategy for the authentication mechanism. Perhaps the
following articles will help :

    - MSDN : Authentication in ASP.NET: .NET Security Guidance
      ( http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnbda/html/authaspdotnet.asp
)

    - MSDN : Fitch & Mather Stocks 2000: Security
      ( http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnfmstock/html/fm2ksecurity.asp
)

    - DevGuru Tutorials : Web-user Authentication for IIS 
      ( www.devguru.com/features/tutorials/authentication/authentication.html
)


Hope this helps.
If you need any clarifications, just ask!

:)

===========================================
Some Google Groups postings on this issue :
      
      - Subject: HELP!!!! with ISAPI and ASP Session Variables
        Newsgroup: microsoft.public.inetserver.iis
        ( groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=80hu0j%249ro%241%40nnrp1.deja.com
)

      - Subject: Integration of ASP and ISAPI-filters, plz. help
        Newsgroup: microsoft.public.inetserver.iis
        ( http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=35d729bf.1612375%40msnews.microsoft.com
)

=======

Google Search Terms Used :
       Access ASP-Session variables from an ISAPI filter
       Isapi filter asp session authentication mechanism for file
       "ISAPI filter" Access ASP "Session variables"
       isapi filter to monitor access to website

Google Search terms Used : 
       Access ASP-Session variables from an ISAPI filter
macwinux-ga rated this answer:3 out of 5 stars
Probably I misunderstood your working ...
(I was expecting a suggestion outside of google search)
Of course , I had done a lot of research on the question using google
myself.
It was'nt a very good feeling to see sites that i had previously
reached through google search.

Thanks.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy