#47654 [NEW]: Warning about empty IV in ECB mode

2009-03-13 Thread saurabh0 at gmail dot com
From: saurabh0 at gmail dot com
Operating system: Windoes Server 2003
PHP version:  5.2.9
PHP Bug Type: mcrypt related
Bug description:  Warning about empty IV in ECB mode

Description:

In ECB mode iv is ignored so there should not be any warning when passing
and empty iv string. This was also reported earlier in bugs #43143 and
#46010 which were supposedly fixed.




Reproduce code:
---
$td = mcrypt_module_open('tripledes', '', 'ecb', '');
mcrypt_generic_init($td, 'mysecretkey', '');

Expected result:

No warning. In fact a 'Notice' when a non-empty iv is given in ECB mode
mentioning that it will be ignored would be better.

Actual result:
--
Warning: mcrypt_generic_init() [function.mcrypt-generic-init]: Iv size
incorrect; supplied length: 0, needed: 8

-- 
Edit bug report at http://bugs.php.net/?id=47654&edit=1
-- 
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=47654&r=trysnapshot52
Try a CVS snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=47654&r=trysnapshot53
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=47654&r=trysnapshot60
Fixed in CVS:
http://bugs.php.net/fix.php?id=47654&r=fixedcvs
Fixed in CVS and need be documented: 
http://bugs.php.net/fix.php?id=47654&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=47654&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=47654&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=47654&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=47654&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=47654&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=47654&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=47654&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=47654&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=47654&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=47654&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=47654&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=47654&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=47654&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=47654&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=47654&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=47654&r=mysqlcfg



Bug #50163 [Com]: IUSR_ NTFS permissions issue on PHP 5.2.11-nts

2010-10-07 Thread saurabh0 at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=50163&edit=1

 ID: 50163
 Comment by: saurabh0 at gmail dot com
 Reported by:be3ch at centrum dot cz
 Summary:IUSR_ NTFS permissions issue on PHP 5.2.11-nts
 Status: No Feedback
 Type:   Bug
 Package:Filesystem function related
 Operating System:   win32 only - Windows 2003 Server
 PHP Version:5.2.11
 Assigned To:pajoye
 Block user comment: N

 New Comment:

I am facing the same problem. Running PHP Version 5.3.3 (FastCgi,
non-thread safe) on IIS6/Windows Server 2003.



All file functions give error when relative paths are used and with
*only* Read permissions on the folder. e.g.



file_get_contents('./path/file.txt');



The above gives:

Warning: file_get_contents(./path/file.txt): failed to open stream: No
such file or directory



If you give the full path its works fine. i.e. the follow works:



file_get_contents('C:/full/path/file.txt');



If you add "List Folder Contents" permission to the folder it starts to
work with relative folders as well.



I am guessing the when relative paths are used php tries to get some
information about the current folder which fails as the "List Folder
Contents" is not given.



Note: I had php (5.2) running as ISAPI before and didn't have this
problem. So it seems to be specific to non-thread safe version.


Previous Comments:

[2010-02-02 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".


[2010-01-25 08:50:32] paj...@php.net

That would help yes, please drop me a mail with the access data :)


[2009-12-07 13:41:22] be3ch at centrum dot cz

Any progress? I can give you access to my VPS server, where you can see
it. :)


[2009-11-24 20:14:17] be3ch at centrum dot cz

You can try this procedure to reproduce this problem:

- install Windows 2008 Server (x86)

- add Web Server role (for IIS7 support)

- download Web Platform Installer and install PHP 5.2.11



Now you have in IIS7 default web with PHP 5.2.11 support. Create test
script test.php with this content :







and copy test.php to C:\Inetpub\wwwroot . Now you can try
http://localhost/test.php and you can see result of script :

bool(true).



There is default icacls result on C:\Inetpub\wwwroot directory :



wwwroot BUILTIN\IIS_IUSRS:(RX)

BUILTIN\IIS_IUSRS:(OI)(CI)(IO)(GR,GE)

NT SERVICE\TrustedInstaller:(I)(F)

NT SERVICE\TrustedInstaller:(I)(OI)(CI)(IO)(F)

NT AUTHORITY\SYSTEM:(I)(F)

NT AUTHORITY\SYSTEM:(I)(OI)(CI)(IO)(F)

BUILTIN\Administrators:(I)(F)

BUILTIN\Administrators:(I)(OI)(CI)(IO)(F)

BUILTIN\Users:(I)(RX)

BUILTIN\Users:(I)(OI)(CI)(IO)(GR,GE)

CREATOR OWNER:(I)(OI)(CI)(IO)(F)



Successfully processed 1 files; Failed processing 0 files



Now on folder C:\inetpub\wwwroot delete inheritance and change
permissions to :



Administrators:F

IUSR:R

NETWORK SERVICE:R

System:F



icacls result will be:



wwwroot NT AUTHORITY\IUSR:(OI)(CI)(R)

NT AUTHORITY\SYSTEM:(OI)(CI)(F)

NT AUTHORITY\NETWORK SERVICE:(OI)(CI)(R)

BUILTIN\Administrators:(OI)(CI)(F)



Successfully processed 1 files; Failed processing 0 files



Restart IIS service and try http://localhost/test.php now. Result of
script will be : bool(false). Now you can try change test script to full
path and result will be bool(true). If you change PHP to TS version,
result with relative path will be correct bool(true). PHP 5.3 NonTS same
problem.


[2009-11-20 10:51:56] paj...@php.net

I fail to reproduce this problem. No matter the OS or configuration,
using 5.3 or 5.2.




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/bug.php?id=50163


-- 
Edit this bug report at http://bugs.php.net/bug.php?id=50163&edit=1


[PHP-BUG] Bug #53011 [NEW]: Error using relative paths are used with *only* Read permissions

2010-10-07 Thread saurabh0 at gmail dot com
From: 
Operating system: Windows Server 2003
PHP version:  5.3.3
Package:  Filesystem function related
Bug Type: Bug
Bug description:Error using relative paths are used with *only* Read permissions

Description:

Running PHP Version 5.3.3 (FastCgi, non-thread safe) on IIS6/Windows Server
2003.



All file functions give error when relative paths are used and with *only*
Read permissions on the folder. e.g.



file_get_contents('./path/file.txt');



The above gives:

Warning: file_get_contents(./path/file.txt): failed to open stream: No such
file or directory



If you give the full path to the same file it works fine. i.e. the follow
works:



file_get_contents('C:/full/path/file.txt');



If you add "List Folder Contents" permission to the folder it starts to
work with relative folders as well.



I am guessing the when relative paths are used php tries to get some
information about the current folder which fails as the "List Folder
Contents" is not given. There is no need to "List Folder Contents" just to
read a file (even if the path is relative).



This bug has been reported before but not fixed:

http://bugs.php.net/bug.php?id=50163



Note: I had php (5.2) running as ISAPI before and didn't have this problem.
So it seems to be specific to non-thread safe version.

Test script:
---
file_get_contents('./path/file.txt');

Expected result:

No error

Actual result:
--
Warning: file_get_contents(./path/file.txt): failed to open stream: No such
file or directory

-- 
Edit bug report at http://bugs.php.net/bug.php?id=53011&edit=1
-- 
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=53011&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=53011&r=trysnapshot53
Try a snapshot (trunk):  
http://bugs.php.net/fix.php?id=53011&r=trysnapshottrunk
Fixed in SVN:
http://bugs.php.net/fix.php?id=53011&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=53011&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=53011&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=53011&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=53011&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=53011&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=53011&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=53011&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=53011&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=53011&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=53011&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=53011&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=53011&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=53011&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=53011&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=53011&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=53011&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=53011&r=mysqlcfg



Bug #53011 [Com]: Error using relative paths are used with *only* Read permissions

2010-10-07 Thread saurabh0 at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=53011&edit=1

 ID: 53011
 Comment by: saurabh0 at gmail dot com
 Reported by:saurabh0 at gmail dot com
 Summary:Error using relative paths are used with *only* Read
 permissions
 Status: Open
 Type:   Bug
 Package:Filesystem function related
 Operating System:   Windows Server 2003
 PHP Version:5.3.3
 Block user comment: N

 New Comment:

Some additional info:



var_dump(getcwd(), realpath("."));



gives:



string(7) "c:\php5" string(7) "C:\php5" 



As expected, when you give "List Folder Contents" permission (in
addition to read) to the web root folder both functions return the
correct path.


Previous Comments:
------------
[2010-10-07 15:51:56] saurabh0 at gmail dot com

Description:

Running PHP Version 5.3.3 (FastCgi, non-thread safe) on IIS6/Windows
Server 2003.



All file functions give error when relative paths are used and with
*only* Read permissions on the folder. e.g.



file_get_contents('./path/file.txt');



The above gives:

Warning: file_get_contents(./path/file.txt): failed to open stream: No
such file or directory



If you give the full path to the same file it works fine. i.e. the
follow works:



file_get_contents('C:/full/path/file.txt');



If you add "List Folder Contents" permission to the folder it starts to
work with relative folders as well.



I am guessing the when relative paths are used php tries to get some
information about the current folder which fails as the "List Folder
Contents" is not given. There is no need to "List Folder Contents" just
to read a file (even if the path is relative).



This bug has been reported before but not fixed:

http://bugs.php.net/bug.php?id=50163



Note: I had php (5.2) running as ISAPI before and didn't have this
problem. So it seems to be specific to non-thread safe version.

Test script:
---
file_get_contents('./path/file.txt');

Expected result:

No error

Actual result:
--
Warning: file_get_contents(./path/file.txt): failed to open stream: No
such file or directory






-- 
Edit this bug report at http://bugs.php.net/bug.php?id=53011&edit=1


Bug #50163 [Com]: IUSR_ NTFS permissions issue on PHP 5.2.11-nts

2010-10-07 Thread saurabh0 at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=50163&edit=1

 ID: 50163
 Comment by: saurabh0 at gmail dot com
 Reported by:be3ch at centrum dot cz
 Summary:IUSR_ NTFS permissions issue on PHP 5.2.11-nts
 Status: Feedback
 Type:   Bug
 Package:Filesystem function related
 Operating System:   win32 only - Windows 2003 Server
 PHP Version:5.2.11
 Assigned To:pajoye
 Block user comment: N

 New Comment:

Some additional info:



var_dump(getcwd(), realpath("."));



gives:



string(7) "c:\php5" string(7) "C:\php5"



As expected, when you give "List Folder Contents" permission (in

addition to read) to the web root folder both functions return the

correct path.


Previous Comments:

[2010-10-07 17:54:38] cataphr...@php.net

Closed bug #53011 as a duplicate as this one.



Pierre: he's using PHP 5.3.3.


[2010-10-07 16:00:20] paj...@php.net

Please try using 5.3.3.

----------------
[2010-10-07 15:40:14] saurabh0 at gmail dot com

I am facing the same problem. Running PHP Version 5.3.3 (FastCgi,
non-thread safe) on IIS6/Windows Server 2003.



All file functions give error when relative paths are used and with
*only* Read permissions on the folder. e.g.



file_get_contents('./path/file.txt');



The above gives:

Warning: file_get_contents(./path/file.txt): failed to open stream: No
such file or directory



If you give the full path its works fine. i.e. the follow works:



file_get_contents('C:/full/path/file.txt');



If you add "List Folder Contents" permission to the folder it starts to
work with relative folders as well.



I am guessing the when relative paths are used php tries to get some
information about the current folder which fails as the "List Folder
Contents" is not given.



Note: I had php (5.2) running as ISAPI before and didn't have this
problem. So it seems to be specific to non-thread safe version.


[2010-02-02 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".


[2010-01-25 08:50:32] paj...@php.net

That would help yes, please drop me a mail with the access data :)




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/bug.php?id=50163


-- 
Edit this bug report at http://bugs.php.net/bug.php?id=50163&edit=1