Module org.apache.wicket.core
Package org.apache.wicket.coop
Class CrossOriginOpenerPolicyRequestCycleListener
java.lang.Object
org.apache.wicket.coop.CrossOriginOpenerPolicyRequestCycleListener
- All Implemented Interfaces:
IRequestCycleListener
public class CrossOriginOpenerPolicyRequestCycleListener
extends Object
implements IRequestCycleListener
Sets Cross-Origin Opener Policy
headers on the responses based on the policy specified by
CrossOriginOpenerPolicyConfiguration
. The header
is not set for the paths that are exempted from COOP.
COOP is a mitigation against cross-origin information leaks and is used to make websites
cross-origin isolated. Setting the COOP header allows you to ensure that a top-level window is
isolated from other documents by putting them in a different browsing context group, so they
cannot directly interact with the top-level window. Using COEP and COOP together allows
developers to safely use * powerful features such as SharedArrayBuffer
,
performance.measureMemory()
, * and the JS Self-Profiling API.See
CrossOriginEmbedderPolicyRequestCycleListener
for instructions * on how to enable COOP.
Read more about cross-origin isolation on
https://web.dev/why-coop-coep/
- Author:
- Santiago Diaz - saldiaz@google.com, Ecenaz Jen Ozmen - ecenazo@google.com
- See Also:
-
Constructor Summary
ConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptionvoid
onRequestHandlerExecuted
(RequestCycle cycle, IRequestHandler handler) Called after anIRequestHandler
has been executed.void
onRequestHandlerResolved
(RequestCycle cycle, IRequestHandler handler) Called when anIRequestHandler
is resolved and will be executed.protected void
protect
(RequestCycle cycle, IRequestHandler handler) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.wicket.request.cycle.IRequestCycleListener
onBeginRequest, onDetach, onEndRequest, onException, onExceptionRequestHandlerResolved, onRequestHandlerScheduled, onUrlMapped
-
Constructor Details
-
CrossOriginOpenerPolicyRequestCycleListener
-
-
Method Details
-
onRequestHandlerResolved
Description copied from interface:IRequestCycleListener
Called when anIRequestHandler
is resolved and will be executed.- Specified by:
onRequestHandlerResolved
in interfaceIRequestCycleListener
-
onRequestHandlerExecuted
Description copied from interface:IRequestCycleListener
Called after anIRequestHandler
has been executed. If the execution resulted in an exception this method will not be called for that particularIRequestHandler
.- Specified by:
onRequestHandlerExecuted
in interfaceIRequestCycleListener
-
protect
-