1234567891011121314151617 |
- package middleware
-
- import (
- "git.links123.net/links123.com/pkg/middleware/auth"
- "git.links123.net/Slate/CorpusAI/config"
- "git.links123.net/Slate/CorpusAI/service/store/cache"
- "github.com/gin-gonic/gin"
- )
-
- func Auth() gin.HandlerFunc {
- return auth.Auth(config.C.App.Secret, cache.AuthSessionStore())
- }
-
- func OptionalAuth() gin.HandlerFunc {
- return auth.OptionalAuth(config.C.App.Secret)
- }
|