2017-08-07 79 views

回答

0

承担,你不希望暴露/static/that/文件夹的例子。

不是黑名单的方法,我建议有选择地定义白名单资源像下面(如果你没有定义说/static/that/)的上面的代码

spring.resources.static-locations=classpath:/META-INF/resources/,classpath:/resources/,classpath:/static/this/,classpath:/public/ # Locations of static resources. 

Excert,从Spring Boot Documentation

采取