クラス XXssProtectionServerHttpHeadersWriter
java.lang.ObjectSE
org.springframework.security.web.server.header.XXssProtectionServerHttpHeadersWriter
- 実装されているすべてのインターフェース:
- ServerHttpHeadersWriter
public class XXssProtectionServerHttpHeadersWriter
extends ObjectSE
implements ServerHttpHeadersWriter
x-xss-protection ヘッダーを追加します。
- 導入:
- 5.0
- ネストされたクラスの要約ネストされたクラス
- フィールドのサマリーフィールド
- コンストラクターの概要コンストラクター
- メソッドのサマリー修飾子と型メソッド説明- voidX-XSS-PROTECTION ヘッダーの値を設定します。- reactor.core.publisher.Mono<VoidSE>- writeHttpHeaders- (org.springframework.web.server.ServerWebExchange exchange) ヘッダーをレスポンスに書き込みます。
- フィールドの詳細- X_XSS_PROTECTION- 関連事項:
 
 
- コンストラクターの詳細- XXssProtectionServerHttpHeadersWriterpublic XXssProtectionServerHttpHeadersWriter()新しいインスタンスを作成します
 
- メソッドの詳細- writeHttpHeaderspublic reactor.core.publisher.Mono<VoidSE> writeHttpHeaders- (org.springframework.web.server.ServerWebExchange exchange) インターフェースからコピーされた説明:- ServerHttpHeadersWriterヘッダーをレスポンスに書き込みます。- 次で指定:
-  インターフェース ServerHttpHeadersWriterのwriteHttpHeaders
- 戻り値:
- ReactiveHttpOutputMessage.beforeCommit(Supplier)の- SupplierSE に戻される Mono。
 
- setHeaderValueX-XSS-PROTECTION ヘッダーの値を設定します。デフォルトは- XXssProtectionServerHttpHeadersWriter.HeaderValue.DISABLED- XXssProtectionServerHttpHeadersWriter.HeaderValue.DISABLEDの場合、X-XSS-Protection が無効であることを指定します。例:- X-XSS-Protection: 0 - XXssProtectionServerHttpHeadersWriter.HeaderValue.ENABLEDの場合、値 1 が含まれますが、モードがブロックされているとは指定されません。この場合、コンテンツの修正が試みられます。例:- X-XSS-Protection: 1 - XXssProtectionServerHttpHeadersWriter.HeaderValue.ENABLED_MODE_BLOCKの場合、値 1 が含まれ、モードがブロックされていると指定されます。内容は "#" に置き換えられます。例:- X-XSS-Protection: 1; mode=block - パラメーター:
- headerValue- 新しい headerValue
- 例外:
- IllegalArgumentExceptionSE- headerValue が null の場合
- 導入:
- 5.8