A security audit of a site complained about anti-caching headers. Some browsers and proxies 'ignore' the no-cache setting and do store some responses. These stored responses could then be read without permission.
The proposed solution was to add a 'no-store' to the caching. Easiest way was to change the default cache-control headers in drupal_page_header().

I'll add a patch that provides a variable with a default for the default page headers. Should give no backwards-compatible problems.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

SpadXIII’s picture

The patch with the default page cache-control header in a variable.

MrHaroldA’s picture

Cool!

Another option could be to move the variable_get() into the drupal_send_headers() call to give you full control over all headers.

drupal_send_headers(variable_get('drupal_default_headers', $default_headers));
SpadXIII’s picture

Status: Active » Needs review
FileSize
616 bytes

Updated the patch for latest 7.x

Tess Bakker’s picture

FileSize
751 bytes

New patch based on latest dev

mvwensen’s picture

Status: Needs review » Needs work

The last submitted patch, 5: default_page_headers-2457613-5.patch, failed testing.

The last submitted patch, 5: default_page_headers-2457613-5.patch, failed testing.

Tess Bakker’s picture

Tip: Use Metatag module to setup a global or context-specific Control-Cache tag.