-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathreplace-outgoing-header_v3.xml
77 lines (77 loc) · 3.69 KB
/
replace-outgoing-header_v3.xml
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<match:metadata-stage value="client-response">
<match:variable name="PMUSER_MODIFY_OUTGOING_KEY" value="?*" value-wildcard="on">
<match:variable name="PMUSER_MODIFY_OUTGOING_NONCE" value="?*" value-wildcard="on">
<assign:variable>
<name>PMUSER_MODIFY_OUTGOING_NONCE</name>
<value>101010</value>
<hidden>on</hidden>
</assign:variable>
</match:variable>
<match:variable name="PMUSER_SURROGATE_SETTINGS" value="?*" value-wildcard="on">
<assign:variable>
<name>PMUSER_MODIFY_OUTGOING_ENC</name>
<value>%(PMUSER_SURROGATE_SETTINGS)</value>
<hidden>on</hidden>
<transform>
<encrypt>
<algorithm>AES256</algorithm>
<key>%(PMUSER_MODIFY_OUTGOING_KEY)</key>
<mode>CBC</mode>
<nonce>%(PMUSER_MODIFY_OUTGOING_NONCE)</nonce>
<prepend-bytes>on</prepend-bytes>
</encrypt>
<base64Encode/>
</transform>
</assign:variable>
</match:variable>
</match:variable>
<match:variable name="PMUSER_HEADER_NAME" value="?*" value-wildcard="on">
<edgeservices:modify-outgoing-response.remove-header>
<name>%(PMUSER_HEADER_NAME)</name>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.remove-header>
<match:variable name="PMUSER_HEADER_VALUE" value="?*" value-wildcard="on">
<edgeservices:modify-outgoing-response.add-header>
<name>%(PMUSER_HEADER_NAME)</name>
<value>%(PMUSER_HEADER_VALUE)%(PMUSER_MODIFY_OUTGOING_ENC)</value>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.add-header>
</match:variable>
</match:variable>
<match:variable name="PMUSER_HTTP_SET_COOKIE_VALUE" value="?*" value-wildcard="on">
<edgeservices:modify-outgoing-response.add-header>
<name>Set-Cookie</name>
<value>%(PMUSER_HTTP_SET_COOKIE_VALUE)%(PMUSER_MODIFY_OUTGOING_ENC)</value>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.add-header>
</match:variable>
<match:variable name="PMUSER_HTTP_LOCATION" value="?*" value-wildcard="on">
<edgeservices:modify-outgoing-response.remove-header>
<name>Location</name>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.remove-header>
<edgeservices:modify-outgoing-response.add-header>
<name>Location</name>
<value>%(PMUSER_HTTP_LOCATION)%(PMUSER_MODIFY_OUTGOING_ENC)</value>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.add-header>
</match:variable>
<match:variable name="PMUSER_SURROGATE_LOCATION" value="?*" value-wildcard="on">
<edgeservices:modify-outgoing-response.remove-header>
<name>Surrogate-Location</name>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.remove-header>
<edgeservices:modify-outgoing-response.add-header>
<name>Surrogate-Location</name>
<value>%(PMUSER_SURROGATE_LOCATION)%(PMUSER_MODIFY_OUTGOING_ENC)</value>
<status>on</status>
<edge-only>off</edge-only>
</edgeservices:modify-outgoing-response.add-header>
</match:variable>
</match:metadata-stage>