property CorsOptions.origin

Origin configuration:

  • true — reflect the request Origin header
  • false — deny all cross-origin
  • string — single allowed origin
  • readonly string[] — allowlist of origins
  • CorsOriginMatcher — dynamic matcher Default: empty allowlist (deny all cross-origin).

Type

boolean | string | readonly string[] | CorsOriginMatcher

Usage

import { type CorsOptions } from "http-security-plugin/src/index.ts";