1--TEST--
2session rfc1867 sid cookie
3--INI--
4file_uploads=1
5error_reporting=E_ALL&~E_NOTICE
6comment=debug builds show some additional E_NOTICE errors
7upload_max_filesize=1024
8session.save_path=
9session.name=PHPSESSID
10session.use_cookies=1
11session.use_only_cookies=0
12session.auto_start=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=0
18--SKIPIF--
19<?php include('skipif.inc'); ?>
20--COOKIE--
21PHPSESSID=_
22--POST_RAW--
23Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737
24-----------------------------20896060251896012921717172737
25Content-Disposition: form-data; name="PHP_SESSION_UPLOAD_PROGRESS"
26
27rfc1867_sid_invalid.php
28-----------------------------20896060251896012921717172737
29Content-Disposition: form-data; name="file1"; filename="file1.txt"
30
311
32-----------------------------20896060251896012921717172737
33Content-Disposition: form-data; name="file2"; filename="file2.txt"
34
352
36-----------------------------20896060251896012921717172737--
37--FILE--
38<?php
39error_reporting(0);
40session_start();
41var_dump(session_id());
42var_dump(basename(__FILE__) == $_POST[ini_get("session.upload_progress.name")]);
43var_dump($_FILES);
44var_dump($_SESSION["upload_progress_" . basename(__FILE__)]);
45session_destroy();
46?>
47--EXPECTF--
48Warning: Unknown: The session id is too long or contains illegal characters, valid characters are a-z, A-Z, 0-9 and '-,' in Unknown on line 0
49string(%d) "%s"
50bool(true)
51array(2) {
52  [%u|b%"file1"]=>
53  array(5) {
54    [%u|b%"name"]=>
55    %string|unicode%(9) "file1.txt"
56    [%u|b%"type"]=>
57    %string|unicode%(0) ""
58    [%u|b%"tmp_name"]=>
59    %string|unicode%(%d) "%s"
60    [%u|b%"error"]=>
61    int(0)
62    [%u|b%"size"]=>
63    int(1)
64  }
65  [%u|b%"file2"]=>
66  array(5) {
67    [%u|b%"name"]=>
68    %string|unicode%(9) "file2.txt"
69    [%u|b%"type"]=>
70    %string|unicode%(0) ""
71    [%u|b%"tmp_name"]=>
72    %string|unicode%(%d) "%s"
73    [%u|b%"error"]=>
74    int(0)
75    [%u|b%"size"]=>
76    int(1)
77  }
78}
79NULL
80