ServerComponentsEndpointOptions.DisableWebSocketCompression Property

Definition

Gets or sets a value that determines if WebSocket compression should be disabled.

public bool DisableWebSocketCompression { get; set; }
member this.DisableWebSocketCompression : bool with get, set
Public Property DisableWebSocketCompression As Boolean

Property Value

Remarks

WebSocket compression is enabled by default, but it can be disabled by setting this value to true. When a callback for ConfigureWebSocketAcceptContext is provided, the value of this property will be ignored, whether compression is enabled or not will be determined by the callback, and the Content Security Policy will be applied according to the value of ContentSecurityFrameAncestorsPolicy. When compression is disabled and no callback is provided, the Content Security Policy header will not be set on the responses.

Applies to