Professional Web Applications Themes

HttpModule for ASP and ASP.NET URL filtering - ASP.NET General

I'm interested in writing an HttpModule to clean up URLs for a site that's in a transitional phase from ASP to ASP.NET. Basically, I'd like to hide some very messy querystrings (which are Google-proof-- they use GUIDs as query parameters) and use more memorable names in the URLs. I'd like this module to work for both ASP and ASP.NET pages in the site. I understand basically how to do this for my .aspx pages, but how do I tell IIS to pass .asp page requests through my ASP.NET module for URL rewriting, and then on to the standard ASP handler? ...

  1. #1

    Default HttpModule for ASP and ASP.NET URL filtering

    I'm interested in writing an HttpModule to clean up URLs for a site that's
    in a transitional phase from ASP to ASP.NET. Basically, I'd like to hide
    some very messy querystrings (which are Google-proof-- they use GUIDs as
    query parameters) and use more memorable names in the URLs.

    I'd like this module to work for both ASP and ASP.NET pages in the site. I
    understand basically how to do this for my .aspx pages, but how do I tell
    IIS to pass .asp page requests through my ASP.NET module for URL rewriting,
    and then on to the standard ASP handler?

    Any insights are appreciated.

    --Jon


    Jon Sequeira Guest

  2. #2

    Default Re: HttpModule for ASP and ASP.NET URL filtering

    I've seen this asked a few times but never seen it work. ASP would have to
    be pointed to the ASP.NET ISAPI handler in IIS, then you would need to
    remove the block in machine.config (cant remember the exact setting) that
    dissallows processing of ASP pages by ASP.NET. Potentially the handler
    could intercept the URL request before it realised the target page contained
    ASP and redirect accordingly.

    Look at the App Mappings section of your web application to see and change
    what the extensions are mapped too.

    --
    Regards

    John Timney (Microsoft ASP.NET MVP)
    ----------------------------------------------
    <shameless_author_plug>
    Professional .NET for Java Developers with C#
    ISBN:1-861007-91-4
    Professional Windows Forms
    ISBN: 1861005547
    Professional JSP 2nd Edition
    ISBN: 1861004958
    Professional JSP
    ISBN: 1861003625
    Beginning JSP Web Development
    ISBN: 1861002092
    </shameless_author_plug>
    ----------------------------------------------

    "Jon Sequeira" <jsequeirtwcny.rr.com> wrote in message
    news:#jQAbo0ODHA.1216TK2MSFTNGP11.phx.gbl...
    > I'm interested in writing an HttpModule to clean up URLs for a site that's
    > in a transitional phase from ASP to ASP.NET. Basically, I'd like to hide
    > some very messy querystrings (which are Google-proof-- they use GUIDs as
    > query parameters) and use more memorable names in the URLs.
    >
    > I'd like this module to work for both ASP and ASP.NET pages in the site. I
    > understand basically how to do this for my .aspx pages, but how do I tell
    > IIS to pass .asp page requests through my ASP.NET module for URL
    rewriting,
    > and then on to the standard ASP handler?
    >
    > Any insights are appreciated.
    >
    > --Jon
    >
    >

    John Timney \(Microsoft MVP\) Guest

  3. #3

    Default Re: HttpModule for ASP and ASP.NET URL filtering

    Thanks, John.

    In researching this, I've come across at least one reference implying that
    this limitation was going to be addressed and fixed in IIS6. Do you know
    anything about that?

    --Jon

    "John Timney (Microsoft MVP)" <xyztimneyjbtinternet.com> wrote in message
    news:#sF5qs1ODHA.3836tk2msftngp13.phx.gbl...
    > I've seen this asked a few times but never seen it work. ASP would have
    to
    > be pointed to the ASP.NET ISAPI handler in IIS, then you would need to
    > remove the block in machine.config (cant remember the exact setting) that
    > dissallows processing of ASP pages by ASP.NET. Potentially the handler
    > could intercept the URL request before it realised the target page
    contained
    > ASP and redirect accordingly.
    >
    > Look at the App Mappings section of your web application to see and change
    > what the extensions are mapped too.
    >
    > --
    > Regards
    >
    > John Timney (Microsoft ASP.NET MVP)
    > ----------------------------------------------
    > <shameless_author_plug>
    > Professional .NET for Java Developers with C#
    > ISBN:1-861007-91-4
    > Professional Windows Forms
    > ISBN: 1861005547
    > Professional JSP 2nd Edition
    > ISBN: 1861004958
    > Professional JSP
    > ISBN: 1861003625
    > Beginning JSP Web Development
    > ISBN: 1861002092
    > </shameless_author_plug>
    > ----------------------------------------------
    >
    > "Jon Sequeira" <jsequeirtwcny.rr.com> wrote in message
    > news:#jQAbo0ODHA.1216TK2MSFTNGP11.phx.gbl...
    > > I'm interested in writing an HttpModule to clean up URLs for a site
    that's
    > > in a transitional phase from ASP to ASP.NET. Basically, I'd like to hide
    > > some very messy querystrings (which are Google-proof-- they use GUIDs as
    > > query parameters) and use more memorable names in the URLs.
    > >
    > > I'd like this module to work for both ASP and ASP.NET pages in the site.
    I
    > > understand basically how to do this for my .aspx pages, but how do I
    tell
    > > IIS to pass .asp page requests through my ASP.NET module for URL
    > rewriting,
    > > and then on to the standard ASP handler?
    > >
    > > Any insights are appreciated.
    > >
    > > --Jon
    > >
    > >
    >
    >

    Jon Sequeira Guest

  4. #4

    Default Re: HttpModule for ASP and ASP.NET URL filtering

    you use ISAPI filters to do this type of url-rewriting before anything hist
    asp or asp.net
    search msdn for atl sample ISAPIfilter


    "Jon Sequeira" <jsequeirtwcny.rr.com> wrote in message
    news:#jQAbo0ODHA.1216TK2MSFTNGP11.phx.gbl...
    > I'm interested in writing an HttpModule to clean up URLs for a site that's
    > in a transitional phase from ASP to ASP.NET. Basically, I'd like to hide
    > some very messy querystrings (which are Google-proof-- they use GUIDs as
    > query parameters) and use more memorable names in the URLs.
    >
    > I'd like this module to work for both ASP and ASP.NET pages in the site. I
    > understand basically how to do this for my .aspx pages, but how do I tell
    > IIS to pass .asp page requests through my ASP.NET module for URL
    rewriting,
    > and then on to the standard ASP handler?
    >
    > Any insights are appreciated.
    >
    > --Jon
    >
    >

    gerry Guest

Similar Threads

  1. HttpModule Multithreading and instances
    By Shapiro in forum ASP.NET Web Services
    Replies: 0
    Last Post: December 7th, 04:19 AM
  2. Authentication using HttpModule
    By don smolen in forum ASP.NET Security
    Replies: 2
    Last Post: May 20th, 11:52 PM
  3. HttpModule & Basic Auth
    By Craig in forum ASP.NET Web Services
    Replies: 0
    Last Post: April 6th, 07:46 AM
  4. Interceptor, HttpModule, WSE
    By oliver.wulff@zurich.ch in forum ASP.NET Web Services
    Replies: 0
    Last Post: January 27th, 05:57 AM
  5. HttpModule
    By PJ in forum ASP.NET General
    Replies: 3
    Last Post: July 18th, 07:10 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139