mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-04 05:00:25 +08:00
28 lines
1.0 KiB
Go
28 lines
1.0 KiB
Go
package waf
|
|
|
|
import (
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/configloaders"
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/default/servers/server/settings/waf/ipadmin"
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/default/servers/serverutils"
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/helpers"
|
|
"github.com/iwind/TeaGo"
|
|
)
|
|
|
|
func init() {
|
|
TeaGo.BeforeStart(func(server *TeaGo.Server) {
|
|
server.
|
|
Helper(helpers.NewUserMustAuth(configloaders.AdminModuleCodeServer)).
|
|
Helper(serverutils.NewServerHelper()).
|
|
Prefix("/servers/server/settings/waf").
|
|
GetPost("", new(IndexAction)).
|
|
Get("/ipadmin/allowList", new(ipadmin.AllowListAction)).
|
|
Get("/ipadmin/denyList", new(ipadmin.DenyListAction)).
|
|
//GetPost("/ipadmin", new(ipadmin.IndexAction)).
|
|
//GetPost("/ipadmin/provinces", new(ipadmin.ProvincesAction)).
|
|
GetPost("/ipadmin/createIPPopup", new(ipadmin.CreateIPPopupAction)).
|
|
GetPost("/ipadmin/updateIPPopup", new(ipadmin.UpdateIPPopupAction)).
|
|
Post("/ipadmin/deleteIP", new(ipadmin.DeleteIPAction)).
|
|
EndAll()
|
|
})
|
|
}
|