测试shell接口

This commit is contained in:
junleea 2025-03-05 19:56:20 +08:00
parent b75d6a62ef
commit ccf1916e4e
1 changed files with 4 additions and 4 deletions

View File

@ -105,6 +105,10 @@ func JWTAuthMiddleware() gin.HandlerFunc {
if tokenString == "" {
tokenString = c.Query("token")
}
//测试
if strings.Contains(c.Request.URL.Path, "/shell/") {
log.Printf("req token:%s ,path:%s", tokenString, c.Request.URL.Path)
}
//如果请求为login或register则不需要验证token
for k, _ := range proto.Url_map {
@ -134,10 +138,6 @@ func JWTAuthMiddleware() gin.HandlerFunc {
return
}
}
//测试
if strings.Contains(c.Request.URL.Path, "/shell/") {
log.Printf("req token:%s ,path:%s", tokenString, c.Request.URL.Path)
}
//查看token是否在超级token中
if worker.IsContainSet("super_permission_tokens", tokenString) {