2022-07-02 14:07:50 +08:00
|
|
|
package constant
|
|
|
|
|
|
|
|
const (
|
|
|
|
RuleTypeDefault = "default"
|
|
|
|
RuleTypeLogical = "logical"
|
|
|
|
)
|
2022-07-02 22:55:10 +08:00
|
|
|
|
|
|
|
const (
|
|
|
|
LogicalTypeAnd = "and"
|
|
|
|
LogicalTypeOr = "or"
|
|
|
|
)
|
2023-12-01 13:24:12 +08:00
|
|
|
|
|
|
|
const (
|
2024-06-26 00:43:51 +08:00
|
|
|
RuleSetTypeInline = "inline"
|
2023-12-01 13:24:12 +08:00
|
|
|
RuleSetTypeLocal = "local"
|
|
|
|
RuleSetTypeRemote = "remote"
|
|
|
|
RuleSetFormatSource = "source"
|
|
|
|
RuleSetFormatBinary = "binary"
|
|
|
|
)
|
2024-07-17 17:57:35 +08:00
|
|
|
|
|
|
|
const (
|
|
|
|
RuleSetVersion1 = 1 + iota
|
|
|
|
RuleSetVersion2
|
|
|
|
)
|
2024-10-21 23:38:34 +08:00
|
|
|
|
|
|
|
const (
|
|
|
|
RuleActionTypeRoute = "route"
|
|
|
|
RuleActionTypeReturn = "return"
|
|
|
|
RuleActionTypeReject = "reject"
|
|
|
|
RuleActionTypeHijackDNS = "hijack-dns"
|
|
|
|
RuleActionTypeSniff = "sniff"
|
|
|
|
RuleActionTypeResolve = "resolve"
|
|
|
|
)
|
|
|
|
|
|
|
|
const (
|
2024-10-22 21:28:22 +08:00
|
|
|
RuleActionRejectMethodDefault = "default"
|
|
|
|
RuleActionRejectMethodReset = "reset"
|
|
|
|
RuleActionRejectMethodNetworkUnreachable = "network-unreachable"
|
|
|
|
RuleActionRejectMethodHostUnreachable = "host-unreachable"
|
|
|
|
RuleActionRejectMethodPortUnreachable = "port-unreachable"
|
|
|
|
RuleActionRejectMethodDrop = "drop"
|
2024-10-21 23:38:34 +08:00
|
|
|
)
|