fix: 配置规范
This commit is contained in:
parent
2add41d74c
commit
f54fca305d
|
@ -127,9 +127,9 @@ public class WebConfig implements WebMvcConfigurer {
|
||||||
|
|
||||||
//XSS过滤器
|
//XSS过滤器
|
||||||
@Bean
|
@Bean
|
||||||
public FilterRegistrationBean xssFilterRegistration(@Value("${ms.xss.xssEnable:false}") boolean xssEnable,
|
public FilterRegistrationBean xssFilterRegistration(@Value("${ms.xss.enable:false}") boolean xssEnable,
|
||||||
@Value("${ms.xss.filterUrl}") String filterUrl,
|
@Value("${ms.xss.filter-url}:''") String filterUrl,
|
||||||
@Value("${ms.xss.excludeUrl}") String excludeUrl) {
|
@Value("${ms.xss.exclude-url}:''") String excludeUrl) {
|
||||||
XSSEscapeFilter xssFilter = new XSSEscapeFilter();
|
XSSEscapeFilter xssFilter = new XSSEscapeFilter();
|
||||||
Map<String, String> initParameters = new HashMap();
|
Map<String, String> initParameters = new HashMap();
|
||||||
FilterRegistrationBean registration = new FilterRegistrationBean();
|
FilterRegistrationBean registration = new FilterRegistrationBean();
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
server:
|
server:
|
||||||
port: 8080
|
port: 8080
|
||||||
servlet.session.timeout: P0DT60M0S #D天H小时M分钟S秒,字符T是紧跟在时分秒之前的,每个单位都必须由数字开始,且时分秒顺序不能乱
|
|
||||||
error:
|
error:
|
||||||
include-exception: true
|
include-exception: true
|
||||||
include-message: always
|
include-message: always
|
||||||
servlet:
|
servlet:
|
||||||
|
context-path: / #项目名称
|
||||||
|
session.timeout: P0DT60M0S #D天H小时M分钟S秒,字符T是紧跟在时分秒之前的,每个单位都必须由数字开始,且时分秒顺序不能乱
|
||||||
encoding:
|
encoding:
|
||||||
force: true
|
force: true
|
||||||
charset: utf-8
|
charset: utf-8
|
||||||
|
@ -21,9 +22,9 @@ logging:
|
||||||
|
|
||||||
ms:
|
ms:
|
||||||
xss:
|
xss:
|
||||||
xssEnable: true #xss过滤器的开关
|
enable: true #xss过滤器的开关
|
||||||
filterUrl: /** #过滤的url,多个用逗号分开
|
filter-url: /** #过滤的url,多个用逗号分开
|
||||||
excludeUrl: /static/**,/template/**,/file/upload.do,/static/plugins/ueditor/1.4.3.3/jsp/editor.do #排除的url,多个用逗号分开
|
exclude-url: /static/**,/template/**,/file/upload.do,/static/plugins/ueditor/1.4.3.3/jsp/editor.do #排除的url,多个用逗号分开
|
||||||
# mstore-url: http://store.i.mingsoft.net
|
# mstore-url: http://store.i.mingsoft.net
|
||||||
# mstore-host: store.i.mingsoft.net
|
# mstore-host: store.i.mingsoft.net
|
||||||
# shiro-key: #16位长度,不填写默认随机生成
|
# shiro-key: #16位长度,不填写默认随机生成
|
||||||
|
|
Loading…
Reference in New Issue