r2 - 15 Feb 2007 - 16:08:34 - ChristianFoliniYou are here: TWiki >  Main Web > Task35Start > StrictHeaderCheck

Rule Discussion "Strict Header Check"

The strict header checks, that only predefined request headers are present in a given request. The strict header check is meant to be specific for every path.

An example looks as follows:

  
  SecRule REQUEST_HEADERS_NAMES "!^(Host|User-Agent|Referer|Accept|Accept-Language|Accept-Encoding|Accept-Charset|Keep-Alive|Connection|Content-Type|Content-Length|Cookie|Pragma|Cache-Control)$" "t:none,deny,id:6,status:501,severity:3,msg:'Strict headercheck: At least one request header is not predefined for this path.'"

We check wether one of the items in the collection REQUEST_HEADERS_NAMES is not contained in our list of predefined headers. If this is the case, we deny access.

Otherwise, checking goes on ...

Edit | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r2 < r1 | More topic actions
 

No permission to view WebTopBar?

No permission to view WebBottomBar?