Sample Configurations Compression and TLS Some web applications are vulnerable to an information disclosure attack when a TLS connection carries deflate compressed data. This is a simple configuration that compresses common text-based content types. It never touches internal subrequests. Note There is an environment variable force-gzip, set via SetEnv , which will ignore the accept-encoding setting of your browser and will send compressed output. Few browsers have the ability to gzip request bodies. However, some special applications actually do support request compression, for instance some WebDAV clients.
|Published (Last):||18 January 2008|
|PDF File Size:||10.46 Mb|
|ePub File Size:||20.41 Mb|
|Price:||Free* [*Free Regsitration Required]|
Smart Filtering In the traditional filtering model, filters are inserted unconditionally using AddOutputFilter and family. Each filter then needs to determine whether to run, and there is little flexibility available for server admins to allow the chain to be configured dynamically. In fact, filters can be inserted based on complex boolean expressions This generalises the limited flexibility offered by AddOutputFilterByType.
Figure 1: The traditional filter model In the traditional model, output filters are a simple chain from the content generator handler to the client. This works well provided the filter chain can be correctly configured, but presents problems when the filters need to be configured dynamically based on the outcome of the handler.
Instead of inserting filters in the chain, we insert a filter harness which in turn dispatches conditionally to a filter provider. There can be multiple providers for one filter, but no more than one provider will run for any single request. A filter chain comprises any number of instances of the filter harness, each of which may have any number of providers. A special case is that of a single provider with unconditional dispatch: this is equivalent to inserting the provider filter directly into the chain.
For details of the directives, see below. Declare Filters The FilterDeclare directive declares a filter, assigning it a name and filter type. Register Providers The FilterProvider directive registers a provider with a filter.
The final argument to FilterProvider is an expression: the provider will be selected to run for a request if and only if the expression evaluates to true. The expression may evaluate HTTP request or response headers, environment variables, or the Handler used by this request.
Configure the Chain The above directives build components of a smart filter chain, but do not configure it to run. The FilterChain directive builds a filter chain from smart filters declared, offering the flexibility to insert filters at the beginning or end of the chain, remove a filter, or clear the chain. If you want to filter documents with other response statuses, you can set the filter-errordocs environment variable, and it will work on all responses regardless of status.
To refine this further, you can use expression conditions with FilterProvider. The FilterProvider directive has changed from httpd 2.
Note that the match no longer support substring matches. They can be replaced by regular expression matches.
So verbessern Sie die Performance Ihrer Webseite über Einstellungen in der .htaccess-Datei
Apache Module mod_deflate
Subscribe to RSS
Apache Module mod_filter