Commit 13ba8b05 authored by ROBERT PATRICK CAREY III's avatar ROBERT PATRICK CAREY III 🗿

Update docs

parent caa3735d
......@@ -8,13 +8,21 @@ use Symfony\Component\HttpKernel\KernelEvents;
class RemoveXFrameOptionsSubscriber implements EventSubscriberInterface {
/**
* Executes actions on the respose event.
*
* @param \Symfony\Component\HttpKernel\Event\FilterResponseEvent $event
* Filter Response Event object.
*/
public function RemoveXFrameOptions(FilterResponseEvent $event) {
$response = $event->getResponse();
$response->headers->remove('X-Frame-Options');
$response->headers->set('X-Frame-Options', 'ALLOW-FROM https://psu.instructure.com/');
$response->headers->set('Content-Security-Policy', 'frame-ancestors https://psu.instructure.com/');
}
/**
* {@inheritdoc}
*/
public static function getSubscribedEvents() {
$events[KernelEvents::RESPONSE][] = array('RemoveXFrameOptions', -10);
return $events;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment