Results 1 to 12 of 12

Thread: ../ security issue *Resolved*

  1. #1

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196

    ../ security issue *Resolved*

    I got a web server that won't allow relative links like "../default/images/myimage.gif"
    because the "../" is a security risk.
    Does anyone have any ideas how to develop a site without
    using double dots, and yet still be able to move it from one server to another?
    Last edited by DeadEyes; Feb 7th, 2003 at 04:12 AM.

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    That's weird. Most servers I've come across do allow it.

    Anyways, what about using:

    /images/whatever.gif

    Basically, the first forward slash specifies the root directory, and you can give the path from there onwards.

  3. #3

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196
    So if I have a structure say
    Code:
    root
       |
       +---images
       +---page
               |
               +--item
    and I'm in item
    using "/images" will take me to images
    as oppossed to ../../images

  4. #4
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    Yep that's right. When you say your server doesn't allow it, do you mean when using a server side language like PHP, or just plain HTML? Could we see an example page? Seems kinda weird to me too.

  5. #5

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196
    It's a specific setting that the sys admin has put in.
    Something along the lines that if you view the source for
    a page and you see ../ you can then guess the directory structure
    and move to another directory and the permissions get messed up along the way.
    I'm not sure if this is a win2k server issue or iis thing.
    It effects everything

  6. #6

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196
    I've found some info on it here

  7. #7
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    Ah I see. That's pretty stupid of MS to leave a security flaw like that in there. Sounds like Mendhak's solution should work.

  8. #8

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196
    That's pretty stupid of MS to leave a security flaw like that in there
    yes, although maybe stupid should be replaced with typical.

    Hopefully it should sort it out, it's not something that has to be changed for a while,
    I got bugs of my own creation to sort out first

  9. #9
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    Wow... I'm actually useful

  10. #10

    Thread Starter
    Frenzied Member DeadEyes's Avatar
    Join Date
    Jul 2002
    Posts
    1,196
    Originally posted by mendhak
    Wow... I'm actually useful
    Yes thank you; now don't go making a habit of it

  11. #11
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    LOL

  12. #12

Posting Permissions

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



Click Here to Expand Forum to Full Width