ID: 27051
Comment by: benadler at gmx dot net
Reported By: ghoffer at globalscape dot com
Status: Feedback
Bug Type: Feature/Change Request
Operating System: Windows
PHP Version: 5.3
Assigned To: pajoye
New Comment:
Hope I'm not too verbose. Maybe it helps to see that calling this
exec("d:/programme/imagemagick/convert.exe -density $density
$baseDirectory/$bookId/document.pdf -quality 95
$baseDirectory/$bookId/$version/page_%04d.jpg", $output);
print_r($output);
in a script run by the webserver (as above) causes this:
Array
(
[0] => Error: /invalidfileaccess in --showpage--
[1] => Operand stack:
[2] => --nostringval-- 1 true
[3] => Execution stack:
[4] => %interp_exit .runexec2 --nostringval--
--nostringval-- --nostringval-- 2 %stopped_push --nostringval--
--nostringval-- --nostringval-- false 1 %stopped_push 1905
1 3 %oparray_pop 1904 1 3 %oparray_pop 1888 1 3
%oparray_pop --nostringval-- --nostringval-- 2 1 4
--nostringval-- %for_pos_int_continue --nostringval--
--nostringval-- 1777 1 9 %oparray_pop --nostringval--
--nostringval--
[5] => Dictionary stack:
[6] => --dict:1155/1684(ro)(G)-- --dict:1/20(G)--
--dict:75/200(L)-- --dict:75/200(L)-- --dict:106/127(ro)(G)--
--dict:275/300(ro)(G)-- --dict:22/25(L)-- --dict:4/6(L)--
--dict:22/40(L)--
[7] => Current allocation mode is local
[8] => Last OS error: Bad file descriptor
)
Previous Comments:
------------------------------------------------------------------------
[2009-09-07 11:11:06] benadler at gmx dot net
Ok, it works on the commandline but not using IIS6 and fastcgi with
fastcgi.impersonate = 1;.
This is test.php:
<?php
$out = array();
echo exec("echo %USERNAME%", $out);
print_r($out);
$out = array();
echo exec("echo %USERPROFILE%", $out);
print_r($out);
?>
and this results in:
%USERNAME%Array
(
[0] => %USERNAME%
)
C:\Documents and Settings\Default UserArray
(
[0] => C:\Documents and Settings\Default User
)
So it seems the user's profile/environment is not correctly set up.
I think username should be either domain\deabjs1 or just deabjs1,
because this is what I use to log on to IIS using NTLM. I'm still using
the same snapshot I was using at [6 Sep 6:13pm UTC].
Thanks for your help!
ben
------------------------------------------------------------------------
[2009-09-06 18:13:09] benadler at gmx dot net
I tried the newest snapshot and it seems to work - thank you!
But, could it be that the environment is not set up correctly?
Suddenly I start getting all those imagemagick-temp files in the
script's directory. I imagine the reason may be that the %TEMP% or
%TMP% system/user variables are not set correctly.
------------------------------------------------------------------------
[2009-09-03 21:17:45] [email protected]
Please (all :) try a snapshot, php 5.3 or 6 (5.3 recommended anyway
:).
------------------------------------------------------------------------
[2009-09-03 19:16:50] [email protected]
Automatic comment from SVN on behalf of pajoye
Revision: http://svn.php.net/viewvc/?view=revision&revision=288004
Log: - #27051, improve fix on xp/2k3
------------------------------------------------------------------------
[2009-09-03 19:16:17] [email protected]
Automatic comment from SVN on behalf of pajoye
Revision: http://svn.php.net/viewvc/?view=revision&revision=288003
Log: - #27051, improve fix on xp/2k3
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/27051
--
Edit this bug report at http://bugs.php.net/?id=27051&edit=1