-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathweb.config
More file actions
53 lines (48 loc) · 2.33 KB
/
web.config
File metadata and controls
53 lines (48 loc) · 2.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<httpProtocol>
<customHeaders>
<add name="Cache-Control" value="no-cache, no-store, must-revalidate" />
<add name="Pragma" value="no-cache" />
<add name="Expires" value="-1" />
</customHeaders>
</httpProtocol>
<staticContent>
<clientCache cacheControlMode="DisableCache" />
</staticContent>
<caching enabled="false" enableKernelCache="false" />
<urlCompression doStaticCompression="true" doDynamicCompression="true" />
<httpErrors errorMode="Custom" existingResponse="Replace">
<remove statusCode="404" subStatusCode="-1" />
<error statusCode="404" path="/404.html" responseMode="ExecuteURL" />
</httpErrors>
<rewrite>
<outboundRules>
<rule name="AddCacheControlHeader">
<match serverVariable="RESPONSE_Cache-Control" pattern=".*" />
<action type="Rewrite" value="no-cache, no-store, must-revalidate" />
</rule>
<rule name="AddPragmaHeader">
<match serverVariable="RESPONSE_Pragma" pattern=".*" />
<action type="Rewrite" value="no-cache" />
</rule>
<rule name="AddExpiresHeader">
<match serverVariable="RESPONSE_Expires" pattern=".*" />
<action type="Rewrite" value="-1" />
</rule>
</outboundRules>
<rules>
<rule name="Handle 404" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{URL}" pattern="^/404.html$" negate="true" />
</conditions>
<action type="CustomResponse" statusCode="404" statusReason="Not Found" statusDescription="The requested page was not found." />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>