feat: mcp server

This commit is contained in:
Jacky 2025-04-29 17:15:42 +08:00
parent c4a9d03bb3
commit e8ee931e16
No known key found for this signature in database
GPG key ID: 215C21B10DF38B4D
51 changed files with 2749 additions and 1526 deletions

View file

@ -59,6 +59,12 @@ func AuthRequired() gin.HandlerFunc {
return
}
if token := c.Query("node_secret"); token != "" && token == settings.NodeSettings.Secret {
c.Set("Secret", token)
c.Next()
return
}
token := getToken(c)
if token == "" {
abortWithAuthFailure()