mirror of
https://github.com/tnb-labs/panel.git
synced 2026-09-01 14:55:12 +08:00
6f0593fbf8
- 切片字段加 unique 防重复配置(域名/监听/IP/白名单/网卡/磁盘设备/ NTP 服务器/应用标识/压缩路径/TLS 版本/索引/定时任务目标) - 网站统计日期范围 End 加 after_or_equal:Start(结束不早于开始) - 新增 tags_test.go:CheckRules 体检关键请求 + 全包 validate tag 编译校验,坏规则名/语法错/未注册自定义规则在测试期即报错 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
14 lines
619 B
Go
14 lines
619 B
Go
package request
|
|
|
|
// FirewallScanSetting 扫描感知设置
|
|
type FirewallScanSetting struct {
|
|
Enabled bool `json:"enabled"`
|
|
Days uint `json:"days" validate:"min:1 && max:365"`
|
|
Interfaces []string `json:"interfaces" validate:"unique"`
|
|
AutoBlock bool `json:"auto_block"`
|
|
BlockThreshold uint `json:"block_threshold" validate:"min:1 && max:100000"`
|
|
BlockWindow uint `json:"block_window" validate:"min:1 && max:1440"`
|
|
BlockDuration uint `json:"block_duration" validate:"max:87600"`
|
|
Whitelist []string `json:"whitelist" validate:"unique && dive && ipcidr"`
|
|
}
|