Documentation ¶
Index ¶
- type MiddlewareManager
- func (mw *MiddlewareManager) AdminMiddleware(next echo.HandlerFunc) echo.HandlerFunc
- func (mw *MiddlewareManager) AuthJWTMiddleware(authUsecase auth.Usecase, cfg *config.Config) echo.MiddlewareFunc
- func (mw *MiddlewareManager) AuthenticatedOrAdminMiddleware() echo.MiddlewareFunc
- func (mw *MiddlewareManager) CSRF(next echo.HandlerFunc) echo.HandlerFunc
- func (mw *MiddlewareManager) DebugMiddleware(next echo.HandlerFunc) echo.HandlerFunc
- func (mw *MiddlewareManager) RequestLoggerMiddleware(next echo.HandlerFunc) echo.HandlerFunc
- func (mw *MiddlewareManager) RoleBasedAuthMiddleware(roles []string) echo.MiddlewareFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MiddlewareManager ¶
type MiddlewareManager struct {
// contains filtered or unexported fields
}
func NewMiddlewareManager ¶
func NewMiddlewareManager(authUsecase auth.Usecase, cfg *config.Config, origins []string, logger logger.Logger) *MiddlewareManager
Middleware manager constructor
func (*MiddlewareManager) AdminMiddleware ¶
func (mw *MiddlewareManager) AdminMiddleware(next echo.HandlerFunc) echo.HandlerFunc
Admin permission role
func (*MiddlewareManager) AuthJWTMiddleware ¶
func (mw *MiddlewareManager) AuthJWTMiddleware(authUsecase auth.Usecase, cfg *config.Config) echo.MiddlewareFunc
Authentication based JWT
func (*MiddlewareManager) AuthenticatedOrAdminMiddleware ¶
func (mw *MiddlewareManager) AuthenticatedOrAdminMiddleware() echo.MiddlewareFunc
Role based auth middleware using ctx user
func (*MiddlewareManager) CSRF ¶
func (mw *MiddlewareManager) CSRF(next echo.HandlerFunc) echo.HandlerFunc
CSRF Middleware
func (*MiddlewareManager) DebugMiddleware ¶
func (mw *MiddlewareManager) DebugMiddleware(next echo.HandlerFunc) echo.HandlerFunc
func (*MiddlewareManager) RequestLoggerMiddleware ¶
func (mw *MiddlewareManager) RequestLoggerMiddleware(next echo.HandlerFunc) echo.HandlerFunc
func (*MiddlewareManager) RoleBasedAuthMiddleware ¶
func (mw *MiddlewareManager) RoleBasedAuthMiddleware(roles []string) echo.MiddlewareFunc
Role based auth middleware using ctx user
Click to show internal directories.
Click to hide internal directories.