WEB项目禁止外部访问某一文件

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/u011134399/article/details/78297448
在web.xml 追加   
<security-constraint>
		<web-resource-collection>
			<web-resource-name>disable_conf</web-resource-name>
			<url-pattern>*.xml</url-pattern>
			<url-pattern>*.log</url-pattern>
			<url-pattern>*.dll</url-pattern>
		</web-resource-collection>
		<auth-constraint />
	</security-constraint>

猜你喜欢

转载自blog.csdn.net/u011134399/article/details/78297448