Skip to main content

Interface: CsrfCookieOptions

Defined in: service-core/src/http/csrf/csrf.ts:57

Cookie-shape options accepted by buildCsrfCookie().

Properties​

maxAge?​

optional maxAge?: number

Defined in: service-core/src/http/csrf/csrf.ts:63

The Max-Age attribute, in seconds. Omitted (session cookie) if not set.


name?​

optional name?: string

Defined in: service-core/src/http/csrf/csrf.ts:59

The cookie's name. Default "csrf" (DEFAULT_CSRF_COOKIE_NAME).


path?​

optional path?: string

Defined in: service-core/src/http/csrf/csrf.ts:61

The Path attribute. Default /.


sameSite?​

optional sameSite?: "Strict" | "Lax" | "None"

Defined in: service-core/src/http/csrf/csrf.ts:65

The SameSite attribute. Default Lax.


secure?​

optional secure?: boolean

Defined in: service-core/src/http/csrf/csrf.ts:67

Set to false to omit the Secure (HTTPS-only) attribute — only for plain-HTTP local dev. Default true.