xhr.https.html (5440B)
1 <!DOCTYPE html> 2 <!-- DO NOT EDIT! Generated by `common/security-features/tools/generate.py --spec upgrade-insecure-requests/` --> 3 <html> 4 <head> 5 <meta charset="utf-8"> 6 <meta name="timeout" content="long"> 7 <script src="/resources/testharness.js"></script> 8 <script src="/resources/testharnessreport.js"></script> 9 <script src="/common/security-features/resources/common.sub.js"></script> 10 <script src="../../../generic/test-case.sub.js"></script> 11 </head> 12 <body> 13 <script> 14 TestCase( 15 [ 16 { 17 "expectation": "allowed", 18 "origin": "cross-http-downgrade", 19 "redirection": "downgrade", 20 "source_context_list": [ 21 { 22 "policyDeliveries": [ 23 { 24 "deliveryType": "http-rp", 25 "key": "upgradeInsecureRequests", 26 "value": "upgrade" 27 } 28 ], 29 "sourceContextType": "worker-module" 30 } 31 ], 32 "source_scheme": "https", 33 "subresource": "xhr", 34 "subresource_policy_deliveries": [], 35 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to cross-http-downgrade origin and downgrade redirection from https context." 36 }, 37 { 38 "expectation": "allowed", 39 "origin": "cross-http-downgrade", 40 "redirection": "no-redirect", 41 "source_context_list": [ 42 { 43 "policyDeliveries": [ 44 { 45 "deliveryType": "http-rp", 46 "key": "upgradeInsecureRequests", 47 "value": "upgrade" 48 } 49 ], 50 "sourceContextType": "worker-module" 51 } 52 ], 53 "source_scheme": "https", 54 "subresource": "xhr", 55 "subresource_policy_deliveries": [], 56 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to cross-http-downgrade origin and no-redirect redirection from https context." 57 }, 58 { 59 "expectation": "allowed", 60 "origin": "cross-https", 61 "redirection": "downgrade", 62 "source_context_list": [ 63 { 64 "policyDeliveries": [ 65 { 66 "deliveryType": "http-rp", 67 "key": "upgradeInsecureRequests", 68 "value": "upgrade" 69 } 70 ], 71 "sourceContextType": "worker-module" 72 } 73 ], 74 "source_scheme": "https", 75 "subresource": "xhr", 76 "subresource_policy_deliveries": [], 77 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to cross-https origin and downgrade redirection from https context." 78 }, 79 { 80 "expectation": "allowed", 81 "origin": "same-http-downgrade", 82 "redirection": "downgrade", 83 "source_context_list": [ 84 { 85 "policyDeliveries": [ 86 { 87 "deliveryType": "http-rp", 88 "key": "upgradeInsecureRequests", 89 "value": "upgrade" 90 } 91 ], 92 "sourceContextType": "worker-module" 93 } 94 ], 95 "source_scheme": "https", 96 "subresource": "xhr", 97 "subresource_policy_deliveries": [], 98 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to same-http-downgrade origin and downgrade redirection from https context." 99 }, 100 { 101 "expectation": "allowed", 102 "origin": "same-http-downgrade", 103 "redirection": "no-redirect", 104 "source_context_list": [ 105 { 106 "policyDeliveries": [ 107 { 108 "deliveryType": "http-rp", 109 "key": "upgradeInsecureRequests", 110 "value": "upgrade" 111 } 112 ], 113 "sourceContextType": "worker-module" 114 } 115 ], 116 "source_scheme": "https", 117 "subresource": "xhr", 118 "subresource_policy_deliveries": [], 119 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to same-http-downgrade origin and no-redirect redirection from https context." 120 }, 121 { 122 "expectation": "allowed", 123 "origin": "same-https", 124 "redirection": "downgrade", 125 "source_context_list": [ 126 { 127 "policyDeliveries": [ 128 { 129 "deliveryType": "http-rp", 130 "key": "upgradeInsecureRequests", 131 "value": "upgrade" 132 } 133 ], 134 "sourceContextType": "worker-module" 135 } 136 ], 137 "source_scheme": "https", 138 "subresource": "xhr", 139 "subresource_policy_deliveries": [], 140 "test_description": "Upgrade-Insecure-Requests: Expects allowed for xhr to same-https origin and downgrade redirection from https context." 141 } 142 ], 143 new SanityChecker() 144 ).start(); 145 </script> 146 <div id="log"></div> 147 </body> 148 </html>