I am developing under a vagrant box using Ubuntu 14.04LTS with the most recent recent version of the Apache2 (2.4.7) available for this server. Mod_asis has been enabled.
If I use the following configuration (copy/paste from official Apache documentation), all the .asis file content gets echoed in the browser, including the header part of the .asis file.
<VirtualHost *:80>
ServerName test.server.com.dev
AddHandler send-as-is asis
RewriteCond %{DOCUMENT_ROOT}/cachedcontent%{REQUEST_FILENAME}.asis -f
RewriteRule .* /cachedcontent%{REQUEST_FILENAME}.asis [L]
</VirtualHost>
Instead, if I use the following configuration, the 'cache' content is echoed properly in the browser.
<VirtualHost *:80>
ServerName test.server.com.dev
<FilesMatch \.asis>
SetHandler send-as-is
</FilesMatch>
RewriteCond %{DOCUMENT_ROOT}/cache%{REQUEST_FILENAME}.asis -f
RewriteRule .* /cache%{REQUEST_FILENAME}.asis [L]
</VirtualHost>
Before I update my dev environment, 'AddHandler send-as-is asis' was working properly. I am wondering if there might be an issue with mod_asis, apache 2.4.7 and the use of VirtualHost.