Conditions | 4 |
Paths | 4 |
Total Lines | 32 |
Code Lines | 17 |
Lines | 0 |
Ratio | 0 % |
1 | <?php |
||
36 | public function doTest() |
||
37 | { |
||
38 | $this->setMessage('Check if PHP may spawn processes.'); |
||
39 | |||
40 | if (!FunctionAvailabilityCheck::isFunctionDefined('proc_open')) { |
||
41 | $this->markFailed( |
||
42 | 'The process execution relies on proc_open, which is not available on your PHP installation.' |
||
43 | ); |
||
44 | |||
45 | return; |
||
46 | } |
||
47 | |||
48 | if (FunctionAvailabilityCheck::isFunctionBlacklistedInSuhosin('proc_open')) { |
||
49 | $this->markFailed( |
||
50 | 'The process execution relies on proc_open, which is disabled in Suhosin on your PHP installation. ' . |
||
51 | 'Please remove "proc_open" from "suhosin.executor.func.blacklist" in php.ini' |
||
52 | ); |
||
53 | |||
54 | return; |
||
55 | } |
||
56 | |||
57 | if (FunctionAvailabilityCheck::isFunctionBlacklistedInPhpIni('proc_open')) { |
||
58 | $this->markFailed( |
||
59 | 'The process execution relies on proc_open, which is disabled in your PHP installation. ' . |
||
60 | 'Please remove "proc_open" from "disabled_functions" in php.ini' |
||
61 | ); |
||
62 | |||
63 | return; |
||
64 | } |
||
65 | |||
66 | $this->markSuccess(); |
||
67 | } |
||
68 | } |
||
69 |