本文介绍了禁止最终用户查看文件.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在服务器上有XML文件. 路径:根\ Myfolder \ .xml文件 我正在使用IIS 6,它具有读写权限,因为它们用于存储日志和某些数据. 一切正常,但是假设我键入www.mydomain \ Myfolder \ abc.xml,它将显示该文件的所有包含内容. 我如何限制它,以便它会显示一些消息(假设FOBIDDEN消息). Prathamesh
Hi, I have my XML files on Server. path : root\Myfolder\.xml files I am using IIS 6, it has Read and write permissions as they are used to store Logs and some Data. It all work fine, But Suppose i Type www.mydomain\Myfolder\abc.xml it shows all the contains of the file. How can i Restrict it so it will display some message suppose FOBIDDEN Message.. Prathamesh
推荐答案将Web.Config文件添加到以下文件夹: Add a Web.Config file to the folder: <?xml version="1.0" encoding="utf-8"?> <configuration> <system.web> <authorization> <deny users="*" /> </authorization> </system.web> </configuration>
更多推荐
禁止最终用户查看文件.
发布评论