RouteOptions.SuppressCheckForUnhandledSecurityMetadata Property

Definition

Gets or sets a value that indicates if the check for unhandled security endpoint metadata is suppressed.

Endpoints can be associated with metadata such as authorization, or CORS, that needs to be handled by a specific middleware to be actionable. If the middleware is not configured, such metadata will go unhandled.

When false, prior to the execution of the endpoint, routing will verify that all known security-specific metadata has been handled. Setting this property to true suppresses this check.

public:
 property bool SuppressCheckForUnhandledSecurityMetadata { bool get(); void set(bool value); };
public bool SuppressCheckForUnhandledSecurityMetadata { get; set; }
member this.SuppressCheckForUnhandledSecurityMetadata : bool with get, set
Public Property SuppressCheckForUnhandledSecurityMetadata As Boolean

Property Value

Defaults to false.

Remarks

This check exists as a safeguard against accidental insecure configuration. You may suppress this check if it does not match your application's requirements.

Applies to