You've already forked caddy-opnsense-blocker
Refine the dashboard and requests log UX
This commit is contained in:
@@ -234,6 +234,7 @@ type EventListOptions struct {
|
||||
ShowKnownBots bool
|
||||
ShowAllowed bool
|
||||
ReviewOnly bool
|
||||
Offset int
|
||||
}
|
||||
|
||||
type SourceOffset struct {
|
||||
@@ -255,20 +256,32 @@ type IPDetails struct {
|
||||
}
|
||||
|
||||
type Overview struct {
|
||||
TotalEvents int64 `json:"total_events"`
|
||||
TotalIPs int64 `json:"total_ips"`
|
||||
BlockedIPs int64 `json:"blocked_ips"`
|
||||
ReviewIPs int64 `json:"review_ips"`
|
||||
AllowedIPs int64 `json:"allowed_ips"`
|
||||
ObservedIPs int64 `json:"observed_ips"`
|
||||
ActivitySince time.Time `json:"activity_since,omitempty"`
|
||||
ActivityBuckets []ActivityBucket `json:"activity_buckets"`
|
||||
Methods []MethodBreakdownRow `json:"methods"`
|
||||
Bots []BotBreakdownRow `json:"bots"`
|
||||
TopIPsByEvents []TopIPRow `json:"top_ips_by_events"`
|
||||
TopIPsByTraffic []TopIPRow `json:"top_ips_by_traffic"`
|
||||
TopSources []TopSourceRow `json:"top_sources"`
|
||||
TopURLs []TopURLRow `json:"top_urls"`
|
||||
RecentIPs []IPState `json:"recent_ips"`
|
||||
RecentEvents []Event `json:"recent_events"`
|
||||
TotalEvents int64 `json:"total_events"`
|
||||
TotalIPs int64 `json:"total_ips"`
|
||||
BlockedIPs int64 `json:"blocked_ips"`
|
||||
ReviewIPs int64 `json:"review_ips"`
|
||||
AllowedIPs int64 `json:"allowed_ips"`
|
||||
ObservedIPs int64 `json:"observed_ips"`
|
||||
ActivitySince time.Time `json:"activity_since,omitempty"`
|
||||
ActivityBuckets []ActivityBucket `json:"activity_buckets"`
|
||||
Methods []MethodBreakdownRow `json:"methods"`
|
||||
Bots []BotBreakdownRow `json:"bots"`
|
||||
TopIPsByEvents []TopIPRow `json:"top_ips_by_events"`
|
||||
TopBotIPsByEvents []TopIPRow `json:"top_bot_ips_by_events"`
|
||||
TopNonBotIPsByEvents []TopIPRow `json:"top_non_bot_ips_by_events"`
|
||||
TopIPsByTraffic []TopIPRow `json:"top_ips_by_traffic"`
|
||||
TopBotIPsByTraffic []TopIPRow `json:"top_bot_ips_by_traffic"`
|
||||
TopNonBotIPsByTraffic []TopIPRow `json:"top_non_bot_ips_by_traffic"`
|
||||
TopSources []TopSourceRow `json:"top_sources"`
|
||||
TopURLs []TopURLRow `json:"top_urls"`
|
||||
RecentIPs []IPState `json:"recent_ips"`
|
||||
RecentEvents []Event `json:"recent_events"`
|
||||
}
|
||||
|
||||
type EventPage struct {
|
||||
Items []Event `json:"items"`
|
||||
Page int `json:"page"`
|
||||
Limit int `json:"limit"`
|
||||
HasPrev bool `json:"has_prev"`
|
||||
HasNext bool `json:"has_next"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user