Secure all links endpoint
This commit is contained in:
parent
5c0125a4b1
commit
a70aac85e7
1 changed files with 1 additions and 1 deletions
|
|
@ -22,7 +22,7 @@ func addMiddleware(s *echo.Echo, conf *koanf.Koanf) {
|
||||||
|
|
||||||
s.Use(middleware.JWTWithConfig(middleware.JWTConfig{
|
s.Use(middleware.JWTWithConfig(middleware.JWTConfig{
|
||||||
Skipper: func(ctx echo.Context) bool {
|
Skipper: func(ctx echo.Context) bool {
|
||||||
return ctx.Request().Method == "GET"
|
return ctx.Request().Method == "GET" && ctx.Request().URL.Path != "/links"
|
||||||
},
|
},
|
||||||
SigningMethod: conf.String("jwt.method"),
|
SigningMethod: conf.String("jwt.method"),
|
||||||
SigningKey: conf.Bytes("jwt.key"),
|
SigningKey: conf.Bytes("jwt.key"),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue