mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2026-01-06 15:55:48 +08:00
WAF SQL注入和XSS检测增加缓存/优化部分WAF相关测试用例
This commit is contained in:
@@ -402,7 +402,7 @@ func (this *WAF) Stop() {
|
||||
}
|
||||
|
||||
// MergeTemplate merge with template
|
||||
func (this *WAF) MergeTemplate() (changedItems []string) {
|
||||
func (this *WAF) MergeTemplate() (changedItems []string, err error) {
|
||||
changedItems = []string{}
|
||||
|
||||
// compare versions
|
||||
@@ -411,7 +411,10 @@ func (this *WAF) MergeTemplate() (changedItems []string) {
|
||||
}
|
||||
this.CreatedVersion = teaconst.Version
|
||||
|
||||
template := Template()
|
||||
template, err := Template()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
groups := []*RuleGroup{}
|
||||
groups = append(groups, template.Inbound...)
|
||||
groups = append(groups, template.Outbound...)
|
||||
|
||||
Reference in New Issue
Block a user