TimRiker

BigIPReport IIS web.config for brotli

Mar 3rd, 2021
1,377
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <configuration>
  3.     <system.webServer>
  4.         <staticContent>
  5.             <remove fileExtension=".css.br" />
  6.             <remove fileExtension=".html.br" />
  7.             <remove fileExtension=".js.br" />
  8.             <remove fileExtension=".json.br" />
  9.             <mimeMap fileExtension=".css.br" mimeType="text/css" />
  10.             <mimeMap fileExtension=".html.br" mimeType="text/html" />
  11.             <mimeMap fileExtension=".js.br" mimeType="application/javascript" />
  12.             <mimeMap fileExtension=".json.br" mimeType="application/json" />
  13.         </staticContent>
  14.         <rewrite>
  15.             <outboundRules rewriteBeforeCache="true">
  16.                 <rule name="vary:accept-encoding">
  17.                     <match serverVariable="RESPONSE_VARY" pattern=".*" />
  18.                     <conditions>
  19.                         <add input="{REQUEST_URI}" pattern="\.br$" />
  20.                     </conditions>
  21.                     <action type="Rewrite" value="accept-encoding" />
  22.                 </rule>
  23.                 <rule name="content-encoding:br">
  24.                     <match serverVariable="RESPONSE_CONTENT_ENCODING" pattern=".*" />
  25.                     <conditions>
  26.                         <add input="{REQUEST_URI}" pattern="\.br$" />
  27.                     </conditions>
  28.                     <action type="Rewrite" value="br" />
  29.                 </rule>
  30.             </outboundRules>
  31.             <rules>
  32.                 <rule name="precompressed brotli" stopProcessing="true">
  33.                     <match url="(.*)\.(css|html|js|json)$" />
  34.                     <conditions>
  35.                         <add input="{HTTP_ACCEPT_ENCODING}" pattern="\bbr\b" />
  36.                         <add input="{REQUEST_FILENAME}.br" matchType="IsFile" />
  37.                     </conditions>
  38.                     <action type="Rewrite" url="{R:0}.br" />
  39.                 </rule>
  40.             </rules>
  41.         </rewrite>
  42.         <urlCompression doStaticCompression="false" />
  43.     </system.webServer>
  44. </configuration>
  45.  
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×