Projects ⇒ Bugs ⇒ #1091: Seg Fault in Batch Add Pictures - Album Menu: with Fix ⇒ CPG Dragonfly™ CMS
Bug #1091 Seg Fault in Batch Add Pictures - Album Menu: with Fix
Project: Dragonfly 9.0.3 -> 9.3 Category: Coppermine
Submitted: Wednesday, April 29, 2009 (13:04:32) Modified: Saturday, May 09, 2009 (16:07:26)
Status: Closed Assigned to:
PHP Version: 5.2 HTTPD Server: Apache 2.0

View/Vote Add Comment

by: layingback
Description:
------------
See http://dragonflycms.org/Forums/viewtopic/t=23723/ for full details of symptoms.

Cause is Parallels Ensim Pro when run in 'High Security' mode.

The seg fault occurs when MySQL is called below function dirheader in modules/coppermine/searchnew.php. While the code is valid as-is for any cPanel or vanilla Linux/Unix system, it will seg fault repeatedly on Ensim Pro High Security. Host would not allow testing at Medium or Low Secuirty so results in thatose cases are unknown.

Parallels are not forthcoming with support for Ensim Pro, but it is my suspicion and the belief of my host that High Security adds a limitation to sprintf to prevent it executing outside of the current executable, i.e. prohibiting access to MySQL. (An error log entry to that effect would be nice.)

Suggested change imposes no overhead on DragonflyCMS or Coppermine, and eliminates a potential support issue, so I would suggest inclusion in code, even though instances on running under High Security mode may be few..

Reproduce code:
---------------
Original code:

return '<tr><td class="tableh2" valign="middle" colspan="3">' .
sprintf(TARGET_ALBUM, $dir, albumselect($dirid)) . '</td></tr>' . $warning;



Reworked code:

$alb_select = albumselect($dirid);
return '<tr><td class="tableh2" valign="middle" colspan="3">' .
sprintf(TARGET_ALBUM, $dir, $alb_select) . '</td></tr>' . $warning;
by: DJ Maze
This bug has been fixed in the CVS.

Snapshots of the sources are packaged every 6 hours; this change
will be in the next snapshot. You can grab the snapshot at the
Downloads section.

Thank you for the report, and for helping us to make Dragonfly 9.0.3 -> 9.2 better.
User Info

Welcome Anonymous



(Register)
Community

Support for DragonflyCMS in a other languages:

Deutsch
Español