Skip to content

Protocol: Cache Control Header

Identifier: header_cache_control

Scanner(s) Support

GraphQL Scanner REST Scanner WebApp Scanner ASM Scanner

Description

When web content contains sensitive information, it's crucial to tell browsers and other caching mechanisms not to store that data. If a website doesn't set a proper Cache-Control header, browsers might save pages that should stay private, potentially leaving sensitive data exposed.

How we test: We analyze HTTP response headers to detect if the Cache-Control header is missing or misconfigured. We check if sensitive pages are properly marked to prevent caching and if cache directives are correctly set to protect confidential information.

References:

Configuration

Example

Example configuration:

---
security_tests:
  header_cache_control:
    skip: false

Reference

skip

Type : boolean

Skip the test if true.