Folder permissions.

Discussion in 'ASP.NET / ASP.NET Core' started by mike1, Feb 9, 2004.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. Hi,

    This is likely to be an easy one and there doesn't appear to be a forum that I can pick to post this so it's in here sorry.

    How do I set the permissions on a folder so that people can't browse view the contents of the folder but the asp.net account can open files within that folder.

    For example if I create a data folder with xml files in it how do I keep those files private.

    Thanks in advance for your help.

    Mike
     
  2. Bruce

    Bruce DiscountASP.NET Staff

    See this FAQ

    http://kb.discountasp.net/article.aspx?id=10166


    quote:Originally posted by [email protected]

    Hi,

    This is likely to be an easy one and there doesn't appear to be a forum that I can pick to post this so it's in here sorry.

    How do I set the permissions on a folder so that people can't browse view the contents of the folder but the asp.net account can open files within that folder.

    For example if I create a data folder with xml files in it how do I keep those files private.

    Thanks in advance for your help.

    Mike
    </blockquote id="quote"></font id="quote">
     
  3. Bruce

    Bruce DiscountASP.NET Staff

    The directory has IIS read & execute permission switched off.

    Basically, you cannot access anything from this directory from the browser.

    quote:Originally posted by dns78727

    quote:Originally posted by bruce

    See this FAQ

    http://kb.discountasp.net/article.aspx?id=10166


    quote:Originally posted by [email protected]

    Hi,

    This is likely to be an easy one and there doesn't appear to be a forum that I can pick to post this so it's in here sorry.

    How do I set the permissions on a folder so that people can't browse view the contents of the folder but the asp.net account can open files within that folder.

    For example if I create a data folder with xml files in it how do I keep those files private.

    Thanks in advance for your help.

    Mike
    </blockquote id="quote"></font id="quote">
    </blockquote id="quote"></font id="quote">
    That link only refers to protecting Access databases (.mdb files) from being downloading. An XML file will not be a .mdb file. Is there a way to protect all the files in a directory from being downloaded but still accessible from ASP or ASPX scripts?
    </blockquote id="quote"></font id="quote">
     
  4. quote:Originally posted by bruce

    See this FAQ

    http://kb.discountasp.net/article.aspx?id=10166


    quote:Originally posted by [email protected]

    Hi,

    This is likely to be an easy one and there doesn't appear to be a forum that I can pick to post this so it's in here sorry.

    How do I set the permissions on a folder so that people can't browse view the contents of the folder but the asp.net account can open files within that folder.

    For example if I create a data folder with xml files in it how do I keep those files private.

    Thanks in advance for your help.

    Mike
    </blockquote id="quote"></font id="quote">
    </blockquote id="quote"></font id="quote">
    That link only refers to protecting Access databases (.mdb files) from being downloading. An XML file will not be a .mdb file. Is there a way to protect all the files in a directory from being downloaded but still accessible from ASP or ASPX scripts?
     
  5. quote:Originally posted by bruce

    The directory has IIS read & execute permission switched off.

    Basically, you cannot access anything from this directory from the browser.
    </blockquote id="quote"></font id="quote">

    If I understand correctly, in spite of the Knowledge Base stating that this directory is just for .mdb files and "Do not place any other files (e.g., html, asp...etc.) in this folder", I can place any file in this folder that I don't want to be available for download but I can read/write these files using classic ASP, ASP.NET, (and I hope) PHP scripts. I realize one would not want to place HTML and ASP scripts in this directory but there are many other types of files where I would want the same type of protection as for databases.
     
  6. Bruce

    Bruce DiscountASP.NET Staff

    That's exactly right.

    quote:Originally posted by dns78727

    quote:Originally posted by bruce

    The directory has IIS read & execute permission switched off.

    Basically, you cannot access anything from this directory from the browser.
    </blockquote id="quote"></font id="quote">

    If I understand correctly, in spite of the Knowledge Base stating that this directory is just for .mdb files and "Do not place any other files (e.g., html, asp...etc.) in this folder", I can place any file in this folder that I don't want to be available for download but I can read/write these files using classic ASP, ASP.NET, (and I hope) PHP scripts. I realize one would not want to place HTML and ASP scripts in this directory but there are many other types of files where I would want the same type of protection as for databases.
    </blockquote id="quote"></font id="quote">
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page