Bug #35369 [Com]: Serialized objects referencing each other, memory exhaustion when unserializing

2011-09-03 Thread junxing dot lin at yahoo dot com
Edit report at https://bugs.php.net/bug.php?id=35369&edit=1

 ID: 35369
 Comment by: junxing dot lin at yahoo dot com
 Reported by:bugreports at insign dot ch
 Summary:Serialized objects referencing each other, memory
 exhaustion when unserializing
 Status: No Feedback
 Type:   Bug
 Package:Class/Object related
 Operating System:   Prolly irrelevant (Linux 2.6.4)
 PHP Version:5CVS-2005-11-24 (CVS)
 Block user comment: N
 Private report: N

 New Comment:

http://www.officialnflshop.co.uk
nfl jerseys
nfl jerseys uk
authentic nfl jerseys
nfl jerseys sale uk
nfl jerseys shop
shop nfl jerseys
nike nfl jerseys
nfl shop uk
nfl shop 2011
NFL Jerseys 2011
2011 nike nfl jerseys
NFL London store
NFL Jerseys online
NFL Jerseys free shipping
NFL shop
NFL store
nfl jerseys official website
nfl jerseys website


Previous Comments:

[2011-08-02 06:11:33] junxing dot lin at yahoo dot com

http://www.chihaironline.net
Shop for over 70% off deals on Chi flat iron, chi hair straightener, chi hair 
tools! Fast Savings & Free worldwide Shipping!


[2011-08-02 06:10:53] junxing dot lin at yahoo dot com

Shop for over 70% off deals on Chi flat iron, chi hair straightener, chi hair 
tools! Fast Savings & Free worldwide Shipping!
http://www.chihaironline.net|chi flat iron
http://www.chihaironline.net|chi hair straightener


[2010-06-28 09:01:24] DAVOGUEMALL at GMAIL dot COM

Due to the poplarity and demand of counterfeit http://www.superflatiron.com/";>chi flat iron are getting more and 
more popular in the europe and united states.The moreden beauty is the sole 
distributor of CHI IRONS that are produced in Columbia.Along with the farouk 
systems,we are not actively and aggressively working to stop the sales of the 
none csa,counterfeight chi flat iron. These chi flat iron are non compliant 
with federal safety standards and have no warranty.Though they can be used for 
several months or even one year,two years,but they are counterfeight products. 
In China,such http://www.superflatiron.com/chi-turbo-ceramic-flat-iron-p-191.html";>GHD 
Turbo Ceramic Flat Iron are hot sellers.We meet one store called 
davoguemall,they even make the chi hairstraightener comes with plug for 
different countries. As the economy problem,not all people can afford such 
expensive CHI FLAT IRON though they are marked 
"authentic". This is the most important reason for the replica chi 
hair straightener can be sold so well. Now our question is turn to how to 
choose a good quality replica chi hair straightener,right?


[2009-09-25 08:47:08] DSHHH at HOTMAIL dot COM

http://www.hotuggsale.co.uk  ugg boots uk
http://www.hotuggsale.co.uk  ugg boots sale
http://www.hotuggsale.co.uk  ugg boots uk sale


[2009-09-12 00:46:41] linlixiang123 at 126 dot com

A man is driving up a steep, narrow mountain road. http://www.chihaironline.com";>chi hair tools A woman is driving down 
the same road. As they pass each other, the woman leans out of the window and 
yells "PIG!!" http://www.chihaironline.com";>chi flat irons The man 
immediately leans out of his window and replies, "WITCH!!"They each 
continue on their way, and as the man rounds the next corner, http://www.chihaironline.com";>chi hair straighteners he crashes into 
a pig in the middle of the road. If only men would listen.




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

https://bugs.php.net/bug.php?id=35369


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


Bug #55525 [Opn]: --enable-zend-multibyte cause Apache exit on signal 10

2011-09-03 Thread info at ihead dot ru
Edit report at https://bugs.php.net/bug.php?id=55525&edit=1

 ID: 55525
 User updated by:info at ihead dot ru
 Reported by:info at ihead dot ru
 Summary:--enable-zend-multibyte cause Apache exit on signal
 10
 Status: Open
 Type:   Bug
 Package:Apache related
 Operating System:   FreeBSD 7.4
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

Here is bugtrace

php53test# gdb /usr/local/apache/bin/httpd13 /usr/local/apache/httpd13.core
GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "amd64-marcel-freebsd"...(no debugging symbols 
found)...
Core was generated by `httpd13'.
Program terminated with signal 10, Bus error.
Reading symbols from /lib/libcrypt.so.4...(no debugging symbols found)...done.
Loaded symbols for /lib/libcrypt.so.4
Reading symbols from /lib/libc.so.7...(no debugging symbols found)...done.
Loaded symbols for /lib/libc.so.7
Reading symbols from /usr/local/apache/libexec/libphp5.so...done.
Loaded symbols for /usr/local/apache/libexec/libphp5.so
Reading symbols from /usr/lib/librt.so.1...done.
Loaded symbols for /usr/lib/librt.so.1
Reading symbols from /lib/libm.so.5...done.
Loaded symbols for /lib/libm.so.5
Reading symbols from /lib/libz.so.4...done.
Loaded symbols for /lib/libz.so.4
Reading symbols from /usr/local/lib/libxml2.so.5...done.
Loaded symbols for /usr/local/lib/libxml2.so.5
Reading symbols from /usr/local/lib/libiconv.so.3...done.
Loaded symbols for /usr/local/lib/libiconv.so.3
Reading symbols from /libexec/ld-elf.so.1...done.
Loaded symbols for /libexec/ld-elf.so.1
#0  0x000200802324 in memcmp () from /lib/libc.so.7
(gdb) bt
#0  0x000200802324 in memcmp () from /lib/libc.so.7
#1  0x000200f68a05 in zend_mm_check_ptr (heap=0x201e5d000, ptr=0x201e18220, 
silent=0, __zend_filename=0x201312554 "Zend/zend_language_scanner.l",
__zend_lineno=707, __zend_orig_filename=0x0, __zend_orig_lineno=0) at 
/root/php/php-5.3.8/Zend/zend_alloc.c:1492
#2  0x000200f6853d in zend_mm_check_ptr (heap=0x201e5d000, ptr=0x201e18220, 
silent=1, __zend_filename=0x201312554 "Zend/zend_language_scanner.l",
__zend_lineno=707, __zend_orig_filename=0x0, __zend_orig_lineno=0) at 
/root/php/php-5.3.8/Zend/zend_alloc.c:1393
#3  0x000200f69f71 in _zend_mm_free_int (heap=0x201e5d000, p=0x201e18220, 
__zend_filename=0x201312554 "Zend/zend_language_scanner.l", __zend_lineno=707,
__zend_orig_filename=0x0, __zend_orig_lineno=0) at 
/root/php/php-5.3.8/Zend/zend_alloc.c:1993
#4  0x000200f6b611 in _efree (ptr=0x201e18220, __zend_filename=0x201312554 
"Zend/zend_language_scanner.l", __zend_lineno=707, __zend_orig_filename=0x0,
__zend_orig_lineno=0) at /root/php/php-5.3.8/Zend/zend_alloc.c:2361
#5  0x000200f4a5e7 in zend_multibyte_read_script (
buf=0x2005c9000 "' . \"\\n\" 
.\n'Reply-To: ad...@ihead.ru' . \"\\r\\n\"\n"..., n=207) at 
zend_language_scanner.l:707
#6  0x000200f49178 in open_file_for_scanning (file_handle=0x7fffe540) 
at zend_language_scanner.l:279
#7  0x000200f4947f in compile_file (file_handle=0x7fffe540, type=8) at 
zend_language_scanner.l:352
#8  0x000200d96842 in phar_compile_file (file_handle=0x7fffe540, 
type=8) at /root/php/php-5.3.8/ext/phar/phar.c:3393
#9  0x000200f94935 in zend_execute_scripts (type=8, retval=0x0, 
file_count=3) at /root/php/php-5.3.8/Zend/zend.c:1228
#10 0x000200f12872 in php_execute_script (primary_file=0x7fffe540) at 
/root/php/php-5.3.8/main/main.c:2284
#11 0x000201088bcc in apache_php_module_main (r=0x201d8f060, 
display_source_mode=0) at /root/php/php-5.3.8/sapi/apache/sapi_apache.c:53
#12 0x000201089d4e in send_php (r=0x201d8f060, display_source_mode=0, 
filename=0x201d90410 "/usr/local/www/1/1.php")
at /root/php/php-5.3.8/sapi/apache/mod_php5.c:682
#13 0x000201089daf in send_parsed_php (r=0x201d8f060) at 
/root/php/php-5.3.8/sapi/apache/mod_php5.c:697
#14 0x00422e92 in ap_invoke_handler ()
#15 0x0043b899 in process_request_internal ()
#16 0x0043b8f4 in ap_process_request ()
#17 0x00431473 in child_main ()
#18 0x00431784 in make_child ()
#19 0x00431bbb in perform_idle_server_maintenance ()
#20 0x004321a9 in standalone_main ()
#21 0x004327f4 in main ()


Previous Comments:

[2011-09-03 14:33:15] info at ihead dot ru

I compile PHP 5.3.8 from src with: './configure' 
'--with-apxs=/usr/local/sbin/apxs' '--enable-debug' '--enable-zend-multibyte' 

I tried to get coredump, but i can find it any

Bug #55577 [Opn->Asn]: Install fails

2011-09-03 Thread felipe
Edit report at https://bugs.php.net/bug.php?id=55577&edit=1

 ID: 55577
 Updated by: fel...@php.net
 Reported by:fedora at famillecollet dot com
 Summary:Install fails
-Status: Open
+Status: Assigned
 Type:   Bug
 Package:FPM related
 Operating System:   GNU/Linux (Fedora 15)
 PHP Version:5.4SVN-2011-09-03 (snap)
-Assigned To:
+Assigned To:fat
 Block user comment: N
 Private report: N



Previous Comments:

[2011-09-03 13:56:00] fedora at famillecollet dot com

Description:

status.html is not present in the build tree, so can't be installed

Attached patch fix this issue.
Another solution could be to add status.html to the PHP_OUTPUT in config.m4


Test script:
---
+ make -C build-fpm install-fpm INSTALL_ROOT=/home/rpmbuild/BUILDROOT



Expected result:

make: Entering directory `/dev/shm/php5.4-201109031230/build-fpm'
Installing PHP FPM binary:
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/sbin/
Installing PHP FPM config:
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/etc/
Installing PHP FPM man page:  
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/man/man8/
Installing PHP FPM status page:  
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/fpm/
make: Leaving directory `/dev/shm/php5.4-201109031230/build-fpm'
make[1]: *** [install-fpm] Error 1

Actual result:
--
/php-5.3.8-0.1.201109031230.fc15.remi.x86_64
make[1]: Entering directory `/dev/shm/php5.4-201109031230/build-fpm'
Installing PHP FPM binary:
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/sbin/
Installing PHP FPM config:
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/etc/
Installing PHP FPM man page:  
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/man/man8/
Installing PHP FPM status page:  
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/fpm/
cp: cannot stat `sapi/fpm/status.html': No such file or directory







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


Bug #55578 [Opn->Asn]: Segfault on implode/concat

2011-09-03 Thread felipe
Edit report at https://bugs.php.net/bug.php?id=55578&edit=1

 ID: 55578
 Updated by: fel...@php.net
 Reported by:kontakt at beberlei dot de
 Summary:Segfault on implode/concat
-Status: Open
+Status: Assigned
 Type:   Bug
 Package:Reproducible crash
 PHP Version:5.4.0alpha3
-Assigned To:
+Assigned To:dmitry
 Block user comment: N
 Private report: N

 New Comment:

Minor test case:

 '(',
'post' => ')',
'separator' => ' AND ',
);

class Foo
{
public function __toString()
{
return 'Foo';
}
}   

function test($options, $queryPart)
{
return (isset($options['pre']) ? $options['pre'] : '')
 . (is_array($queryPart) ? implode($options['separator'], 
$queryPart) : $queryPart)
 . (isset($options['post']) ? $options['post'] : '');
}

#echo test($options, "test"); // comment this in and the line after works aswell
echo test($options, new Foo()); // this segfaults

Expected result:

(Foo)




Actual result:
--
Segfault, Backtrace is:

#0  gc_remove_zval_from_buffer (zv=0xb5f5b1b0) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_gc.c:265
#1  0x083723c8 in _zval_ptr_dtor (zval_ptr=0x8913da8) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_execute_API.c:437
#2  0x08374065 in zend_call_function (fci=0xbfffc8ac, fci_cache=0xbfffc8d0) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_execute_API.c:1018
#3  0x0839660b in zend_call_method (object_pp=0xbfffc9a0, obj_ce=, fn_proxy=0xb5f76d38, function_name=0x8866e95 "__tostring", 
function_name_len=10, 
retval_ptr_ptr=0xbfffc97c, param_count=0, arg1=0x0, arg2=0x0) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_interfaces.c:97
#4  0x083a0f11 in zend_std_cast_object_tostring (readobj=0xb5f5b1b0, 
writeobj=0xbfffca48, type=6)
at /home/benny/downloads/php-5.4.0alpha3/Zend/zend_object_handlers.c:1472
#5  0x0838152b in zend_make_printable_zval (expr=0xb5f5b1b0, 
expr_copy=0xbfffca48, use_copy=0xbfffca68) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend.c:260
#6  0x0837c678 in concat_function (result=0xb5f5b1c0, op1=0xb5f5b170, 
op2=0xb5f5b1b0) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_operators.c:1243
#7  0x083d4d53 in ZEND_CONCAT_SPEC_TMP_TMP_HANDLER (execute_data=0xb5f5b0f8) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_vm_execute.h:8133
#8  0x083e52e6 in execute (op_array=0x8a5e7b0) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_vm_execute.h:410
#9  0x08381d82 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at 
/home/benny/downloads/php-5.4.0alpha3/Zend/zend.c:1262
#10 0x083247a2 in php_execute_script (primary_file=0xbfffeebc) at 
/home/benny/downloads/php-5.4.0alpha3/main/main.c:2385
#11 0x0842005e in do_cli (argc=2, argv=0xb144) at 
/home/benny/downloads/php-5.4.0alpha3/sapi/cli/php_cli.c:983
#12 0x084208d7 in main (argc=2, argv=0xb144) at 
/home/benny/downloads/php-5.4.0alpha3/sapi/cli/php_cli.c:1356






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


Bug #55576 [Opn]: Race condition in move_uploaded_file()

2011-09-03 Thread cataphract
Edit report at https://bugs.php.net/bug.php?id=55576&edit=1

 ID: 55576
 Updated by: cataphr...@php.net
 Reported by:cjk at wwwtech dot de
 Summary:Race condition in move_uploaded_file()
 Status: Open
 Type:   Bug
 Package:Filesystem function related
 Operating System:   All
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

The patch makes sense for paths in the filesystem, but this function also 
supports an arbitrary stream wrapper in the destination.

In any case, I'm puzzled by the first unlink() call (on new_path), it seems 
redundant. It was introduced in r32313.


Previous Comments:

[2011-09-03 11:34:19] cjk at wwwtech dot de

Description:

There is a race condition in the move_uploaded_file() function: if you don't 
want 
to overwrite a file, the standard mechanism is:

$fd = fopen($file,"x");
fclose($fd);
move_uploaded_file($uploaded_file,$file);

But since move_uploaded_file() unlink()s a file first, there may be a race 
condition: file gets created exclusively via fopen(…,"x"), 
move_uploaded_file() 
removes the same file and the process gets suspended. Another process creates 
the 
file via fopen(…,"x"), voila, race condition.

Expected result:

We need a concurrency save implementation of move_uploaded_file(). This can be 
achieved by implementing a third parameter, boolean $dont_overwrite. When set 
to 
true, move_uploaded_file() will ensure that the file does not exist by using 
open(…,O_RDWR|O_CREAT|O_EXCL) and returning false in error case. The patch I 
attached does exactly this.


Actual result:
--
When two concurrent processes, they may overwrite the same file twice w/o the 
possibility to prevent it. 






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


[PHP-BUG] Bug #55578 [NEW]: Segfault on implode/concat

2011-09-03 Thread kontakt at beberlei dot de
From: 
Operating system: 
PHP version:  5.4.0alpha3
Package:  Reproducible crash
Bug Type: Bug
Bug description:Segfault on implode/concat

Description:

I found this issue running the Doctrine 2 testsuite with PHP 5.4.0 alpha 3
and could isolate the segfault behavior to a very simple php script.

I cant make anything out of the backtrace with regard to the nature of the
failing. But it seems to have something to do with the __toString() that
gets implicitly called.

Test script:
---
 '(',
'post' => ')',
'separator' => ' AND ',
);

class Foo
{
public function __toString()
{
return 'Foo';
}
}   

function test($options, $queryPart)
{
return (isset($options['pre']) ? $options['pre'] : '')
 . (is_array($queryPart) ? implode($options['separator'],
$queryPart) : $queryPart)
 . (isset($options['post']) ? $options['post'] : '');
}

#echo test($options, "test"); // comment this in and the line after works
aswell
echo test($options, new Foo()); // this segfaults

Expected result:

(Foo)




Actual result:
--
Segfault, Backtrace is:

#0  gc_remove_zval_from_buffer (zv=0xb5f5b1b0) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_gc.c:265
#1  0x083723c8 in _zval_ptr_dtor (zval_ptr=0x8913da8) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_execute_API.c:437
#2  0x08374065 in zend_call_function (fci=0xbfffc8ac, fci_cache=0xbfffc8d0)
at /home/benny/downloads/php-5.4.0alpha3/Zend/zend_execute_API.c:1018
#3  0x0839660b in zend_call_method (object_pp=0xbfffc9a0, obj_ce=, fn_proxy=0xb5f76d38, function_name=0x8866e95 "__tostring",
function_name_len=10, 
retval_ptr_ptr=0xbfffc97c, param_count=0, arg1=0x0, arg2=0x0) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_interfaces.c:97
#4  0x083a0f11 in zend_std_cast_object_tostring (readobj=0xb5f5b1b0,
writeobj=0xbfffca48, type=6)
at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_object_handlers.c:1472
#5  0x0838152b in zend_make_printable_zval (expr=0xb5f5b1b0,
expr_copy=0xbfffca48, use_copy=0xbfffca68) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend.c:260
#6  0x0837c678 in concat_function (result=0xb5f5b1c0, op1=0xb5f5b170,
op2=0xb5f5b1b0) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_operators.c:1243
#7  0x083d4d53 in ZEND_CONCAT_SPEC_TMP_TMP_HANDLER
(execute_data=0xb5f5b0f8) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_vm_execute.h:8133
#8  0x083e52e6 in execute (op_array=0x8a5e7b0) at
/home/benny/downloads/php-5.4.0alpha3/Zend/zend_vm_execute.h:410
#9  0x08381d82 in zend_execute_scripts (type=8, retval=0x0, file_count=3)
at /home/benny/downloads/php-5.4.0alpha3/Zend/zend.c:1262
#10 0x083247a2 in php_execute_script (primary_file=0xbfffeebc) at
/home/benny/downloads/php-5.4.0alpha3/main/main.c:2385
#11 0x0842005e in do_cli (argc=2, argv=0xb144) at
/home/benny/downloads/php-5.4.0alpha3/sapi/cli/php_cli.c:983
#12 0x084208d7 in main (argc=2, argv=0xb144) at
/home/benny/downloads/php-5.4.0alpha3/sapi/cli/php_cli.c:1356

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



Bug #55525 [Fbk->Opn]: --enable-zend-multibyte cause Apache exit on signal 10

2011-09-03 Thread info at ihead dot ru
Edit report at https://bugs.php.net/bug.php?id=55525&edit=1

 ID: 55525
 User updated by:info at ihead dot ru
 Reported by:info at ihead dot ru
 Summary:--enable-zend-multibyte cause Apache exit on signal
 10
-Status: Feedback
+Status: Open
 Type:   Bug
 Package:Apache related
 Operating System:   FreeBSD 7.4
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

I compile PHP 5.3.8 from src with: './configure' 
'--with-apxs=/usr/local/sbin/apxs' '--enable-debug' '--enable-zend-multibyte' 

I tried to get coredump, but i can find it anywhere.

When i start apache (with -X) i see:
php53test# apachectl13 start
Processing config directory: /usr/local/apache/conf/includes13/*.conf
 Processing config file: /usr/local/apache/conf/includes13/13.s16.ihead.ru.conf

After that i make two requests to the Apache.
1) Processed and is see text of syntax error (command line ok)
2) I see blank page (command line print "Bus error")

After that i see text in the command line:
Bus error
/usr/local/sbin/apachectl13 start: httpd could not be started

In the logs such records:
[Sat Sep  3 14:19:40 2011] [warn] pid file /usr/local/apache/logs13/httpd.pid 
overwritten -- Unclean shutdown of previous Apache run?
/usr/local/www/1/1.php(4) : Parse error - syntax error, unexpected ';'
[Sat Sep  3 14:19:46 2011]  Script:  '/usr/local/www/1/1.php'
---
Zend/zend_language_scanner.l(707) : Block 0x201e18220 status:
Beginning:  Freed
Start:  Overflown (magic=0x5A5A5A5A instead of 0x513AB69F)
At least 4 bytes overflown
Processing config directory: /usr/local/apache/conf/includes13/*.conf
 Processing config file: /usr/local/apache/conf/includes13/13.s16.ihead.ru.conf
[Sat Sep  3 14:22:39 2011] [warn] pid file /usr/local/apache/logs13/httpd.pid 
overwritten -- Unclean shutdown of previous Apache run?
/usr/local/www/1/1.php(4) : Parse error - syntax error, unexpected ';'
[Sat Sep  3 14:22:44 2011]  Script:  '/usr/local/www/1/1.php'
---
Zend/zend_language_scanner.l(707) : Block 0x201e18220 status:
Beginning:  Freed
Start:  Overflown (magic=0x5A5A5A5A instead of 0x545BD6B9)
At least 4 bytes overflown


Previous Comments:

[2011-09-03 11:23:20] larue...@php.net

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.




[2011-08-28 14:46:47] info at ihead dot ru

Description:

--enable-zend-multibyte in "configure" script (Zend Multibyte Support = 
Enabled) cause Apache's child processes outputs any result, but exit on signal 
10 when in PHP-script there is syntax error and when MaxRequestPerChild != 1.

Tested on Apache 1.3 and Apache 2.2 building PHP from FreeBSD ports or from 
source directly.

Test script:
---


Expected result:

Work correctly on any next request

Actual result:
--
Apache's child proccess outputs any result (text of syntax error) and exit with 
signal 10. It cause fails at the next request (Apache server close connection 
without any result), when request is scheduled to the killed child.






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


[PHP-BUG] Bug #55577 [NEW]: Install fails

2011-09-03 Thread fedora at famillecollet dot com
From: 
Operating system: GNU/Linux (Fedora 15)
PHP version:  5.4SVN-2011-09-03 (snap)
Package:  FPM related
Bug Type: Bug
Bug description:Install fails

Description:

status.html is not present in the build tree, so can't be installed

Attached patch fix this issue.
Another solution could be to add status.html to the PHP_OUTPUT in
config.m4


Test script:
---
+ make -C build-fpm install-fpm INSTALL_ROOT=/home/rpmbuild/BUILDROOT



Expected result:

make: Entering directory `/dev/shm/php5.4-201109031230/build-fpm'
Installing PHP FPM binary:   
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/sbin/
Installing PHP FPM config:   
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/etc/
Installing PHP FPM man page: 
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/man/man8/
Installing PHP FPM status page: 
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/fpm/
make: Leaving directory `/dev/shm/php5.4-201109031230/build-fpm'
make[1]: *** [install-fpm] Error 1

Actual result:
--
/php-5.3.8-0.1.201109031230.fc15.remi.x86_64
make[1]: Entering directory `/dev/shm/php5.4-201109031230/build-fpm'
Installing PHP FPM binary:   
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/sbin/
Installing PHP FPM config:   
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/etc/
Installing PHP FPM man page: 
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/man/man8/
Installing PHP FPM status page: 
/home/rpmbuild/BUILDROOT/php-5.3.8-0.1.201109031230.fc15.remi.x86_64/usr/share/fpm/
cp: cannot stat `sapi/fpm/status.html': No such file or directory


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



[PHP-BUG] Bug #55576 [NEW]: Race condition in move_uploaded_file()

2011-09-03 Thread cjk at wwwtech dot de
From: 
Operating system: All
PHP version:  5.3.8
Package:  Filesystem function related
Bug Type: Bug
Bug description:Race condition in move_uploaded_file()

Description:

There is a race condition in the move_uploaded_file() function: if you
don't want 
to overwrite a file, the standard mechanism is:

$fd = fopen($file,"x");
fclose($fd);
move_uploaded_file($uploaded_file,$file);

But since move_uploaded_file() unlink()s a file first, there may be a race

condition: file gets created exclusively via fopen(…,"x"),
move_uploaded_file() 
removes the same file and the process gets suspended. Another process
creates the 
file via fopen(…,"x"), voila, race condition.

Expected result:

We need a concurrency save implementation of move_uploaded_file(). This can
be 
achieved by implementing a third parameter, boolean $dont_overwrite. When
set to 
true, move_uploaded_file() will ensure that the file does not exist by
using 
open(…,O_RDWR|O_CREAT|O_EXCL) and returning false in error case. The
patch I 
attached does exactly this.


Actual result:
--
When two concurrent processes, they may overwrite the same file twice w/o
the 
possibility to prevent it. 

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



Bug #55525 [Opn->Fbk]: --enable-zend-multibyte cause Apache exit on signal 10

2011-09-03 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=55525&edit=1

 ID: 55525
 Updated by: larue...@php.net
 Reported by:info at ihead dot ru
 Summary:--enable-zend-multibyte cause Apache exit on signal
 10
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:Apache related
 Operating System:   FreeBSD 7.4
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.




Previous Comments:

[2011-08-28 14:46:47] info at ihead dot ru

Description:

--enable-zend-multibyte in "configure" script (Zend Multibyte Support = 
Enabled) cause Apache's child processes outputs any result, but exit on signal 
10 when in PHP-script there is syntax error and when MaxRequestPerChild != 1.

Tested on Apache 1.3 and Apache 2.2 building PHP from FreeBSD ports or from 
source directly.

Test script:
---


Expected result:

Work correctly on any next request

Actual result:
--
Apache's child proccess outputs any result (text of syntax error) and exit with 
signal 10. It cause fails at the next request (Apache server close connection 
without any result), when request is scheduled to the killed child.






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