Skip to content

Commit 005ec4c

Browse files
committed
Bug 1606798 [wpt PR 21019] - HTTP: 0x00 in a header value, a=testonly
Automatic update from web-platform-tests HTTP: 0x00 in a header value Tests to complement those written in web-platform-tests/wpt#10424. -- wpt-commits: 38ecde806a5f1710d9e5beba700cef7352f7570e wpt-pr: 21019 UltraBlame original commit: 2df4f38122005c353cf34c665c293fcb975fbdb7
1 parent 6a5aad0 commit 005ec4c

6 files changed

+690
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,361 @@
1+
async_test
2+
(
3+
t
4+
=
5+
>
6+
{
7+
const
8+
script
9+
=
10+
document
11+
.
12+
createElement
13+
(
14+
"
15+
script
16+
"
17+
)
18+
;
19+
t
20+
.
21+
add_cleanup
22+
(
23+
(
24+
)
25+
=
26+
>
27+
script
28+
.
29+
remove
30+
(
31+
)
32+
)
33+
;
34+
script
35+
.
36+
src
37+
=
38+
"
39+
resources
40+
/
41+
script
42+
-
43+
with
44+
-
45+
0x00
46+
-
47+
in
48+
-
49+
header
50+
.
51+
py
52+
"
53+
;
54+
script
55+
.
56+
onerror
57+
=
58+
t
59+
.
60+
step_func_done
61+
(
62+
)
63+
;
64+
script
65+
.
66+
onload
67+
=
68+
t
69+
.
70+
unreached_func
71+
(
72+
)
73+
;
74+
document
75+
.
76+
body
77+
.
78+
append
79+
(
80+
script
81+
)
82+
;
83+
}
84+
"
85+
Expect
86+
network
87+
error
88+
for
89+
script
90+
with
91+
0x00
92+
in
93+
a
94+
header
95+
"
96+
)
97+
;
98+
async_test
99+
(
100+
t
101+
=
102+
>
103+
{
104+
const
105+
frame
106+
=
107+
document
108+
.
109+
createElement
110+
(
111+
"
112+
iframe
113+
"
114+
)
115+
;
116+
t
117+
.
118+
add_cleanup
119+
(
120+
(
121+
)
122+
=
123+
>
124+
frame
125+
.
126+
remove
127+
(
128+
)
129+
)
130+
;
131+
frame
132+
.
133+
src
134+
=
135+
"
136+
resources
137+
/
138+
document
139+
-
140+
with
141+
-
142+
0x00
143+
-
144+
in
145+
-
146+
header
147+
.
148+
py
149+
"
150+
;
151+
/
152+
/
153+
If
154+
network
155+
errors
156+
result
157+
in
158+
load
159+
events
160+
for
161+
frames
162+
per
163+
/
164+
/
165+
https
166+
:
167+
/
168+
/
169+
github
170+
.
171+
com
172+
/
173+
whatwg
174+
/
175+
html
176+
/
177+
issues
178+
/
179+
125
180+
and
181+
https
182+
:
183+
/
184+
/
185+
github
186+
.
187+
com
188+
/
189+
whatwg
190+
/
191+
html
192+
/
193+
issues
194+
/
195+
1230
196+
this
197+
/
198+
/
199+
should
200+
be
201+
changed
202+
to
203+
use
204+
the
205+
load
206+
event
207+
instead
208+
.
209+
t
210+
.
211+
step_timeout
212+
(
213+
(
214+
)
215+
=
216+
>
217+
{
218+
assert_equals
219+
(
220+
frame
221+
.
222+
contentDocument
223+
null
224+
)
225+
;
226+
t
227+
.
228+
done
229+
(
230+
)
231+
;
232+
}
233+
1000
234+
)
235+
;
236+
document
237+
.
238+
body
239+
.
240+
append
241+
(
242+
frame
243+
)
244+
;
245+
}
246+
"
247+
Expect
248+
network
249+
error
250+
for
251+
frame
252+
navigation
253+
to
254+
resource
255+
with
256+
0x00
257+
in
258+
a
259+
header
260+
"
261+
)
262+
;
263+
async_test
264+
(
265+
t
266+
=
267+
>
268+
{
269+
const
270+
img
271+
=
272+
document
273+
.
274+
createElement
275+
(
276+
"
277+
img
278+
"
279+
)
280+
;
281+
t
282+
.
283+
add_cleanup
284+
(
285+
(
286+
)
287+
=
288+
>
289+
img
290+
.
291+
remove
292+
(
293+
)
294+
)
295+
;
296+
img
297+
.
298+
src
299+
=
300+
"
301+
resources
302+
/
303+
blue
304+
-
305+
with
306+
-
307+
0x00
308+
-
309+
in
310+
-
311+
a
312+
-
313+
header
314+
.
315+
asis
316+
"
317+
;
318+
img
319+
.
320+
onerror
321+
=
322+
t
323+
.
324+
step_func_done
325+
(
326+
)
327+
;
328+
img
329+
.
330+
onload
331+
=
332+
t
333+
.
334+
unreached_func
335+
(
336+
)
337+
;
338+
document
339+
.
340+
body
341+
.
342+
append
343+
(
344+
img
345+
)
346+
;
347+
}
348+
"
349+
Expect
350+
network
351+
error
352+
for
353+
image
354+
with
355+
0x00
356+
in
357+
a
358+
header
359+
"
360+
)
361+
;

0 commit comments

Comments
 (0)