Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
twbworld committed Jul 21, 2023
1 parent 3a58d05 commit e8bb88f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions router/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/twbworld/proxy/controller"
"github.com/twbworld/proxy/dao"
"github.com/twbworld/proxy/global"
"github.com/twbworld/proxy/model"

"github.com/gin-gonic/gin"
Expand Down Expand Up @@ -39,6 +40,13 @@ func Init(ginServer *gin.Engine) {
func validatorUri() gin.HandlerFunc {
return func(ctx *gin.Context) {
userName := ctx.Query("u")
global.Log.Info("1======================")
global.Log.Info(userName)
global.Log.Info("2======================")
global.Log.Info(ctx.Request)
global.Log.Info("3======================")
global.Log.Info(ctx.Params)
global.Log.Info("4======================")
if userName == "" || len(userName) < 3 || len(userName) > 50 {
ctx.Abort()
ctx.Redirect(http.StatusMovedPermanently, "/404.html")
Expand Down

0 comments on commit e8bb88f

Please sign in to comment.