I would include the file in the same place as the class file (in the
app-root/web-inf/classes/...)- then you can use something like
<yourclassname>.class.getResourceAsStream("<sub folder relative to class's
package>/db.cfg"); Then you can read the configuration properties from that
stream (Dont forget to close it after reading the contents).
By default tomcat blocks all access to the web-inf folderS. -----Original Message----- From: Venkat Dosapati [mailto:[EMAIL PROTECTED]] Sent: Friday, December 21, 2001 12:47 AM To: Tomcat Users List Subject: protecting a non-jsp file from accessing Hi, I have been using Tomcat 3.2.1 with Apache for my application deployment. In my application I have a database configuration file called db.cfg. The file is placed in document root directory. Now my problem is that the file can be accessed through the browser by using http://<VirtualHostName>/db.cfg. Is there anyway to block the file from users. Any ideas will be appreciated. Thanx in advance. ---- Venkat -- To unsubscribe: <mailto:[EMAIL PROTECTED]> For additional commands: <mailto:[EMAIL PROTECTED]> Troubles with the list: <mailto:[EMAIL PROTECTED]>
