title: Laravel Not Adding Custom Headers
body: <p>Using laravel, I am attempting to add my own headers to all responses from the server.</p>
  
  <p>I have the following in <code>filters.php</code>:</p>
  
  <pre><code>App::after(function($request, $response)
  {
      // security related 
      $response-&gt;headers-&gt;set('X-Frame-Options','deny'); // Anti clickjacking
      $response-&gt;headers-&gt;set('X-XSS-Protection', '1; mode=block'); // Anti cross site scripting (XSS)
      $response-&gt;headers-&gt;set('X-Content-Type-Options', 'nosniff'); // Reduce exposure to drive-by dl attacks
      $response-&gt;headers-&gt;set('Content-Security-Policy', 'default-src \'self\''); // Reduce risk of XSS, clickjacking, and other stuff
      // Don't cache stuff (we'll be updating the page frequently)
      $response-&gt;headers-&gt;set('Cache-Control', 'nocache, no-store, max-age=0, must-revalidate');
      $response-&gt;headers-&gt;set('Pragma', 'no-cache');
      $response-&gt;headers-&gt;set('Expires', 'Fri, 01 Jan 1990 00:00:00 GMT');
      // CRITICAL: do NOT delete
      $response-&gt;headers-&gt;set('X-Archer', 'DANGER ZONE');
  });
  </code></pre>
  
  <p>Yet no new headers show up when I test it:</p>
  
  <pre><code>[tesla | ~] =&gt; curl -o/dev/null -s -D - localhost
  HTTP/1.1 200 OK
  Date: Wed, 10 Dec 2014 23:13:30 GMT
  Server: Apache
  X-Powered-By: PHP/5.6.2
  Content-Length: 974
  Content-Type: text/html; charset=UTF-8
  
  [tesla | ~] =&gt;
  </code></pre>
  
  <p>I have no error or warnings in my log files. How could this be?</p>