tomcat5.5/7 建立虚拟目录后访问权限问题?
时间:2011-03-22
来源:互联网
配置了虚拟目录web.xml权限部分如下:
<security-constraint>
<web-resource-collection>
<url-pattern>/*</url-pattern>
<http-method>GET</http-method>
<http-method>PUT</http-method>
<http-method>HEAD</http-method>
<http-method>TREACE</http-method>
<http-method>DELETE</http-method>
<http-method>POST</http-method>
<http-method>OPTIONS</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>role1</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>NONE</transport-guarantee>
</user-data-constraint>
</security-constraint>
<login-config>
<auth-method>BASIC</auth-method>
</login-config>
<security-role>
<role-name>role1</role-name>
</security-role>
按道理我从网上邻居(web folder)使用role1中的用户认证登陆后,只能浏览,不能下载上传删除虚拟目录中的文件
问题是 删除 或是下载的时候 居然再次弹出认证框 要求输入用户名,密码,而且正确输入之后居然能读能写也能上传下载了(不输入或者输入错误的话 就不能删除 下载 上传),这是为什么?
<security-constraint>
<web-resource-collection>
<url-pattern>/*</url-pattern>
<http-method>GET</http-method>
<http-method>PUT</http-method>
<http-method>HEAD</http-method>
<http-method>TREACE</http-method>
<http-method>DELETE</http-method>
<http-method>POST</http-method>
<http-method>OPTIONS</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>role1</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>NONE</transport-guarantee>
</user-data-constraint>
</security-constraint>
<login-config>
<auth-method>BASIC</auth-method>
</login-config>
<security-role>
<role-name>role1</role-name>
</security-role>
按道理我从网上邻居(web folder)使用role1中的用户认证登陆后,只能浏览,不能下载上传删除虚拟目录中的文件
问题是 删除 或是下载的时候 居然再次弹出认证框 要求输入用户名,密码,而且正确输入之后居然能读能写也能上传下载了(不输入或者输入错误的话 就不能删除 下载 上传),这是为什么?
作者: lgpjyf 发布时间: 2011-03-22
帮顶!!
作者: lijian8552 发布时间: 2011-03-22
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28