0

Please would someone explain in simple terms what these rules are doing:

RewriteEngine on
RewriteRule .* - [E=HTTP_IF_MODIFIED_SINCE:%{HTTP:If-Modified-Since}]
RewriteRule .* - [E=HTTP_IF_NONE_MATCH:%{HTTP:If-None-Match}]

1 Answer 1

4

It's matching any input (.*), and redirecting to the same location, setting the Environmental variables (HTTP_IF_MODIFIED_SINCE and HTTP_IF_NONE_MATCH) equal to the value in the http headers (If-Modified-Since and If-None-Match respectively).

Basically it's just pulling some HTTP Header information and putting it in Environmental variables, presumably for future logic to take some action dependent on the variables.

3
  • The reason I ask is I'm investigating a possible intrusion and I didn't remember writing them. Could this be used maliciously? Jul 26, 2011 at 15:43
  • @shanethehat These rules cannot make harm on their own.
    – LazyOne
    Jul 26, 2011 at 15:57
  • Fair enough, then I shall look elsewhere. Thanks folks. Jul 26, 2011 at 16:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .