File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change 16
16
use Symfony \Component \HttpKernel \KernelEvents ;
17
17
use Symfony \Component \HttpKernel \Exception \AccessDeniedHttpException ;
18
18
use Symfony \Component \HttpKernel \UriSigner ;
19
+ use Symfony \Component \HttpKernel \HttpKernelInterface ;
19
20
use Symfony \Component \EventDispatcher \EventSubscriberInterface ;
20
21
21
22
/**
24
25
* All URL paths starting with /_fragment are handled as
25
26
* content fragments by this listener.
26
27
*
27
- * If the request does not come from a trusted IP, it throws an
28
- * AccessDeniedHttpException exception .
28
+ * If throws an AccessDeniedHttpException exception if the request
29
+ * is not signed or if it is not an internal sub-request .
29
30
*
30
31
* @author Fabien Potencier <[email protected] >
31
32
*/
@@ -61,7 +62,9 @@ public function onKernelRequest(GetResponseEvent $event)
61
62
return ;
62
63
}
63
64
64
- $ this ->validateRequest ($ request );
65
+ if (HttpKernelInterface::MASTER_REQUEST === $ event ->getRequestType ()) {
66
+ $ this ->validateRequest ($ request );
67
+ }
65
68
66
69
parse_str ($ request ->query ->get ('_path ' , '' ), $ attributes );
67
70
$ request ->attributes ->add ($ attributes );
You can’t perform that action at this time.
0 commit comments