diff --git a/internal/nodes/http_request_waf.go b/internal/nodes/http_request_waf.go index bbbb7da..82c2140 100644 --- a/internal/nodes/http_request_waf.go +++ b/internal/nodes/http_request_waf.go @@ -22,10 +22,25 @@ func (this *HTTPRequest) doWAFRequest() (blocked bool) { if conn != nil { trafficConn, ok := conn.(*TrafficConn) if ok && trafficConn.IsClosed() { + this.disableLog = true return true } } + // 检查是否在临时黑名单中 + if waf.SharedIPBlackList.Contains(waf.IPTypeAll, firewallconfigs.FirewallScopeService, this.Server.Id, this.WAFRemoteIP()) { + this.disableLog = true + + if conn != nil { + trafficConn, ok := conn.(*TrafficConn) + if ok && !trafficConn.IsClosed() { + _ = trafficConn.Close() + } + } + + return true + } + // 当前服务的独立设置 if this.web.FirewallPolicy != nil && this.web.FirewallPolicy.IsOn { blocked, breakChecking := this.checkWAFRequest(this.web.FirewallPolicy)