ASP problem with includes

Discussion in 'ASP General' started by ceyhun, Jun 21, 2004.

  1. ceyhun

    ceyhun Guest

    When I use an include file like this
    <!--#include file="..\..\cfig.asp"-->
    <!--#include file="..\..\clsOOPModule.asp"-->
    my server gives an error of :
    Active Server Pages error 'ASP 0131'

    Disallowed Parent Path

    /test/module/VieBoard/main.asp, line 1

    The Include file '..\..\cfig.asp' cannot contain '..' to
    indicate the parent directory.
     
    ceyhun, Jun 21, 2004
    #1
    1. Advertising

  2. ceyhun

    Chris Barber Guest

    It's a setting of the website to allow / disallow parent paths.

    Open the website properties in IIS MMC console and change it (if you need this). It's a security
    thing to prevent crafted URLs that try and navigate outside of the website,

    Chris.

    "ceyhun" <> wrote in message news:1f06d01c4572a$89c94b10$...
    When I use an include file like this
    <!--#include file="..\..\cfig.asp"-->
    <!--#include file="..\..\clsOOPModule.asp"-->
    my server gives an error of :
    Active Server Pages error 'ASP 0131'

    Disallowed Parent Path

    /test/module/VieBoard/main.asp, line 1

    The Include file '..\..\cfig.asp' cannot contain '..' to
    indicate the parent directory.
     
    Chris Barber, Jun 21, 2004
    #2
    1. Advertising

  3. http://www.aspfaq.com/2412

    --
    http://www.aspfaq.com/
    (Reverse address to reply.)

    "ceyhun" <> wrote in message
    news:1f06d01c4572a$89c94b10$...
    > When I use an include file like this
    > <!--#include file="..\..\cfig.asp"-->
    > <!--#include file="..\..\clsOOPModule.asp"-->
    > my server gives an error of :
    > Active Server Pages error 'ASP 0131'
    >
    > Disallowed Parent Path
    >
    > /test/module/VieBoard/main.asp, line 1
    >
    > The Include file '..\..\cfig.asp' cannot contain '..' to
    > indicate the parent directory.
    >
     
    Aaron [SQL Server MVP], Jun 21, 2004
    #3
  4. ceyhun

    3legs Guest

    use relative path instead:

    <!--#include virtual=/path/to/files -->
    "ceyhun" <> ¦b¶l¥ó
    news:1f06d01c4572a$89c94b10$ ¤¤¼¶¼g...
    > When I use an include file like this
    > <!--#include file="..\..\cfig.asp"-->
    > <!--#include file="..\..\clsOOPModule.asp"-->
    > my server gives an error of :
    > Active Server Pages error 'ASP 0131'
    >
    > Disallowed Parent Path
    >
    > /test/module/VieBoard/main.asp, line 1
    >
    > The Include file '..\..\cfig.asp' cannot contain '..' to
    > indicate the parent directory.
    >
     
    3legs, Jun 21, 2004
    #4
  5. ceyhun

    Ceyhun Guest

    I opened MMC but there's nothing there. I use IIS6.0

    >-----Original Message-----
    >It's a setting of the website to allow / disallow parent

    paths.
    >
    >Open the website properties in IIS MMC console and change

    it (if you need this). It's a security
    >thing to prevent crafted URLs that try and navigate

    outside of the website,
    >
    >Chris.
    >
    >"ceyhun" <> wrote in message

    news:1f06d01c4572a$89c94b10$...
    >When I use an include file like this
    ><!--#include file="..\..\cfig.asp"-->
    ><!--#include file="..\..\clsOOPModule.asp"-->
    >my server gives an error of :
    >Active Server Pages error 'ASP 0131'
    >
    >Disallowed Parent Path
    >
    >/test/module/VieBoard/main.asp, line 1
    >
    >The Include file '..\..\cfig.asp' cannot contain '..' to
    >indicate the parent directory.
    >
    >
    >.
    >
     
    Ceyhun, Jun 21, 2004
    #5
  6. ceyhun

    Jeff Cochran Guest

    On Mon, 21 Jun 2004 00:26:13 -0700, "Ceyhun" <> wrote:

    >I opened MMC but there's nothing there. I use IIS6.0


    Nothing? Then you have a bigger problem than parent paths.

    If you just don't understand where to look, see:

    Enable Parent Paths Is Disabled by Default in IIS 6.0:
    http://support.microsoft.com/default.aspx?scid=kb;EN-US;332117

    Jeff

    >>-----Original Message-----
    >>It's a setting of the website to allow / disallow parent

    >paths.
    >>
    >>Open the website properties in IIS MMC console and change

    >it (if you need this). It's a security
    >>thing to prevent crafted URLs that try and navigate

    >outside of the website,
    >>
    >>Chris.
    >>
    >>"ceyhun" <> wrote in message

    >news:1f06d01c4572a$89c94b10$...
    >>When I use an include file like this
    >><!--#include file="..\..\cfig.asp"-->
    >><!--#include file="..\..\clsOOPModule.asp"-->
    >>my server gives an error of :
    >>Active Server Pages error 'ASP 0131'
    >>
    >>Disallowed Parent Path
    >>
    >>/test/module/VieBoard/main.asp, line 1
    >>
    >>The Include file '..\..\cfig.asp' cannot contain '..' to
    >>indicate the parent directory.
    >>
    >>
    >>.
    >>
     
    Jeff Cochran, Jun 21, 2004
    #6
  7. ceyhun

    3legs Guest

    I mean relative to the root (that is, absolute path :p )
    "3legs" <> ¦b¶l¥ó news:
    ¤¤¼¶¼g...
    > use relative path instead:
    >
    > <!--#include virtual=/path/to/files -->
    > "ceyhun" <> ¦b¶l¥ó
    > news:1f06d01c4572a$89c94b10$ ¤¤¼¶¼g...
    > > When I use an include file like this
    > > <!--#include file="..\..\cfig.asp"-->
    > > <!--#include file="..\..\clsOOPModule.asp"-->
    > > my server gives an error of :
    > > Active Server Pages error 'ASP 0131'
    > >
    > > Disallowed Parent Path
    > >
    > > /test/module/VieBoard/main.asp, line 1
    > >
    > > The Include file '..\..\cfig.asp' cannot contain '..' to
    > > indicate the parent directory.
    > >

    >
    >
     
    3legs, Jun 23, 2004
    #7
    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. Geraldine

    includes in ASP .NET

    Geraldine, Oct 28, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    324
    Kevin Spencer
    Oct 29, 2003
  2. Steve

    Virtual Includes in ASP.NET

    Steve, Nov 19, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    419
    Jim Cheshire [MSFT]
    Nov 19, 2003
  3. Davíð Þórisson

    migrating asp to aspl.net: includes?

    Davíð Þórisson, Dec 30, 2003, in forum: ASP .Net
    Replies:
    4
    Views:
    394
    Davíð Þórisson
    Dec 30, 2003
  4. Jay

    Using includes with ASP.NET

    Jay, Jan 13, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    497
  5. Mark Rae

    asp:Literal & <!--includes-->

    Mark Rae, Jul 15, 2004, in forum: ASP .Net
    Replies:
    4
    Views:
    2,174
    Mark Rae
    Jul 15, 2004
Loading...

Share This Page