mirror of https://github.com/gophish/gophish
parent
b4a73ae5c7
commit
906c4e8a93
|
@ -57,11 +57,11 @@ func CreateAdminRouter() http.Handler {
|
||||||
// Setup CSRF Protection
|
// Setup CSRF Protection
|
||||||
csrfHandler := nosurf.New(router)
|
csrfHandler := nosurf.New(router)
|
||||||
// Exempt API routes and Static files
|
// Exempt API routes and Static files
|
||||||
csrfHandler.ExemptGlob("/api/campaigns/*")
|
csrfHandler.ExemptGlob("/api/campaigns*")
|
||||||
csrfHandler.ExemptGlob("/api/groups/*")
|
csrfHandler.ExemptGlob("/api/groups*")
|
||||||
csrfHandler.ExemptGlob("/api/templates/*")
|
csrfHandler.ExemptGlob("/api/templates*")
|
||||||
csrfHandler.ExemptGlob("/api/pages/*")
|
csrfHandler.ExemptGlob("/api/pages*")
|
||||||
csrfHandler.ExemptGlob("/api/import/*")
|
csrfHandler.ExemptGlob("/api/import*")
|
||||||
csrfHandler.ExemptGlob("/static/*")
|
csrfHandler.ExemptGlob("/static/*")
|
||||||
return Use(csrfHandler.ServeHTTP, mid.GetContext)
|
return Use(csrfHandler.ServeHTTP, mid.GetContext)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue