zendwang
2022-07-04 686068c8ed0137cc937a4894f3e110c58ed5b8c8
ruoyi-common/src/main/java/com/ruoyi/common/filter/XssFilter.java
@@ -1,5 +1,6 @@
package com.ruoyi.common.filter;
import cn.hutool.extra.servlet.ServletUtil;
import com.ruoyi.common.utils.StringUtils;
import javax.servlet.*;
@@ -48,7 +49,7 @@
        String url = request.getServletPath();
        String method = request.getMethod();
        // GET DELETE 不过滤
        if (method == null || method.matches("GET") || method.matches("DELETE")) {
        if (method == null || method.matches(ServletUtil.METHOD_GET) || method.matches(ServletUtil.METHOD_DELETE)) {
            return true;
        }
        return StringUtils.matches(url, excludes);