MCPcopy
hub / github.com/gofiber/fiber / updateCSRFCookie

Function updateCSRFCookie

middleware/csrf/csrf.go:301–303  ·  view source on GitHub ↗

Update CSRF cookie if expireCookie is true, the cookie will expire immediately

(c fiber.Ctx, cfg *Config, token string)

Source from the content-addressed store, hash-verified

299// Update CSRF cookie
300// if expireCookie is true, the cookie will expire immediately
301func updateCSRFCookie(c fiber.Ctx, cfg *Config, token string) {
302 setCSRFCookie(c, cfg, token, cfg.IdleTimeout)
303}
304
305func expireCSRFCookie(c fiber.Ctx, cfg *Config) {
306 setCSRFCookie(c, cfg, "", -time.Hour)

Callers 1

NewFunction · 0.85

Calls 1

setCSRFCookieFunction · 0.85

Tested by

no test coverage detected