Re: Http Module Problem: not all requests hit my module why?

Discussion in 'ASP .Net' started by Jiong Feng, Nov 19, 2003.

  1. Jiong Feng

    Jiong Feng Guest

    Hi,

    Is there a way to let a request without filename come to http module?
    For example, http://localhost/abc/def
    where abc and def are not virtual directory, just random words.

    Thanks
    Jiong

    "Brian Combs" <> wrote in message
    news:ftJuSuKaCHA.2720@cpmsftngxa06...
    > Hello
    > Http Modules run in the .Net framework. They will only see requests that
    > are handled by the framework and not all requests to IIS. If you need to
    > see all the requests you should write an ISAPI filter. You may be able to
    > create a script map of .* to map all request to the .net framework dll but
    > you could then run into other problems.
    >
    > Thanks
    > Brian [MS]
    > Microsoft Developer Support
    > This posting is provided "AS IS" with no warranties, and confers no

    rights.
    >
     
    Jiong Feng, Nov 19, 2003
    #1
    1. Advertising

  2. Jiong Feng

    Bill Priess Guest

    Probably not as IIS still has issues when it comes to determining what is a
    directory and what is not in a parsed URL.

    HTH,
    Bill P.
    "Jiong Feng" <> wrote in message
    news:3fbbb967$...
    > Hi,
    >
    > Is there a way to let a request without filename come to http module?
    > For example, http://localhost/abc/def
    > where abc and def are not virtual directory, just random words.
    >
    > Thanks
    > Jiong
    >
    > "Brian Combs" <> wrote in message
    > news:ftJuSuKaCHA.2720@cpmsftngxa06...
    > > Hello
    > > Http Modules run in the .Net framework. They will only see requests that
    > > are handled by the framework and not all requests to IIS. If you need to
    > > see all the requests you should write an ISAPI filter. You may be able

    to
    > > create a script map of .* to map all request to the .net framework dll

    but
    > > you could then run into other problems.
    > >
    > > Thanks
    > > Brian [MS]
    > > Microsoft Developer Support
    > > This posting is provided "AS IS" with no warranties, and confers no

    > rights.
    > >

    >
    >
     
    Bill Priess, Nov 19, 2003
    #2
    1. Advertising

  3. Hi Bill and Jiong,

    If I understand correctly, the question is "Can IIS route requests with
    arbitrary URLs - that may or may not exist on the file system - to my ISAPI
    extension?"

    The answer to this is "yes". You can write an ISAPI filter on
    SF_NOTIFY_PREPROC_HEADERS to look at the incoming URLs and determine if they
    are interesting to you. If they are, then you can rewrite the URL so that
    it points to your ISAPI extension. This is, for example, how the pre-ISA
    proxy server works. It recognizes URLs directed to the proxy, stores the
    original URL away so that the extension can get them later, and then rewites
    the URL to msproxy.dll.

    Since SF_NOTIFY_PREPROC_HEADERS happens before any analysis of the request
    is done (only HTTP parsing has been done at this point), the URL from the
    client does not have to correspond to anything. The filter can take care of
    telling it where to go.

    I'm not sure what you mean by "IIS still has issues when it comes to
    determining what is a directory and what is not". IIS has no such
    limitation.

    Thank you,
    -Wade A. Hilmo,
    -Microsoft

    "Bill Priess" <> wrote in message
    news:...
    > Probably not as IIS still has issues when it comes to determining what is

    a
    > directory and what is not in a parsed URL.
    >
    > HTH,
    > Bill P.
    > "Jiong Feng" <> wrote in message
    > news:3fbbb967$...
    > > Hi,
    > >
    > > Is there a way to let a request without filename come to http module?
    > > For example, http://localhost/abc/def
    > > where abc and def are not virtual directory, just random words.
    > >
    > > Thanks
    > > Jiong
    > >
    > > "Brian Combs" <> wrote in message
    > > news:ftJuSuKaCHA.2720@cpmsftngxa06...
    > > > Hello
    > > > Http Modules run in the .Net framework. They will only see requests

    that
    > > > are handled by the framework and not all requests to IIS. If you need

    to
    > > > see all the requests you should write an ISAPI filter. You may be able

    > to
    > > > create a script map of .* to map all request to the .net framework dll

    > but
    > > > you could then run into other problems.
    > > >
    > > > Thanks
    > > > Brian [MS]
    > > > Microsoft Developer Support
    > > > This posting is provided "AS IS" with no warranties, and confers no

    > > rights.
    > > >

    > >
    > >

    >
    >
     
    Wade A. Hilmo [MS], Nov 29, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Brian Smith
    Replies:
    1
    Views:
    406
    Kevin Spencer
    Feb 20, 2004
  2. alex
    Replies:
    0
    Views:
    303
  3. CK
    Replies:
    9
    Views:
    400
    Jerry Rasmussen
    Oct 19, 2006
  4. Mr. SweatyFinger
    Replies:
    2
    Views:
    1,975
    Smokey Grindel
    Dec 2, 2006
  5. Dave Garcia
    Replies:
    5
    Views:
    592
    Dave Garcia
    Jun 5, 2009
Loading...

Share This Page