title: How To Deny Access To File But Allow Server
body: <p>I have a web application that has a configuration folder that houses multiple XML files that are configuration settings for multiple "portals" as you will.  I need IIS to have access to them so the "portal" loads (sql connection strings, master page paths) but I want to deny any outside access (url browsing).  Here's an example below:</p>
  
  <p><a href="http://www.mywebsite/virtualdirectory/configurationdirectory/configfile.xml" rel="noreferrer">http://www.mywebsite/virtualdirectory/configurationdirectory/configfile.xml</a></p>
  
  <p>I need to restrict access to this file if you're browsing to it but still allow the system access to it so it can parse the "portal" that it's loading.  </p>
  
  <p>Any ideas?</p>