xref: /PHP-8.0/ext/session/tests/bug79221.phpt (revision 7aacc705)
1--TEST--
2Null Pointer Dereference in PHP Session Upload Progress
3--INI--
4error_reporting=0
5file_uploads=1
6upload_max_filesize=1024
7session.save_path=
8session.name=PHPSESSID
9session.serialize_handler=php
10session.use_strict_mode=0
11session.use_cookies=1
12session.use_only_cookies=0
13session.upload_progress.enabled=1
14session.upload_progress.cleanup=0
15session.upload_progress.prefix=upload_progress_
16session.upload_progress.name=PHP_SESSION_UPLOAD_PROGRESS
17session.upload_progress.freq=1%
18session.upload_progress.min_freq=0.000000001
19--COOKIE--
20PHPSESSID=session-upload
21--POST_RAW--
22Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737
23-----------------------------20896060251896012921717172737
24Content-Disposition: form-data; name="PHPSESSID"
25
26session-upload
27-----------------------------20896060251896012921717172737
28Content-Disposition: form-data; name="PHP_SESSION_UPLOAD_PROGRESS"
29
30ryat
31-----------------------------20896060251896012921717172737
32Content-Disposition: form-data; file="file"; ryat="filename"
33
341
35-----------------------------20896060251896012921717172737--
36--FILE--
37<?php
38
39session_start();
40var_dump($_SESSION);
41session_destroy();
42
43?>
44--EXPECT--
45array(0) {
46}
47