Article ID: 2402, created on Oct 29, 2007, last review on Apr 26, 2014

  • Applies to:
  • Pro Control Panel Linux


View Knowledge
Knowledge ID 1164
Product : WEBppliance for Linux
Version : 3.5.4
Topic : FAQ

PHP scripts randomly display php source code

PHP scripts randomly display php source code




PHP scripts in WEBppliance 3.5.4 will randomly display php source code.  This is related to a php bug in which 'php_admin_flag engine (on/off)' option will "bleed" out of the virtualhost container it is set in.  This results in random toggling of the global php state whenever a site is visited.

This will be corrected in an upcoming patch.  Here is a workaround you can apply to fix this problem:

For each site that is a "3.1 Compatible (medium)" or "Low" security site, this fix will need to be applied to prevent this problem:

1) Determine the site handle

sitelookup -d site_handle

# assuming the result returned is 'site10'
2) Add a file into /etc/httpd/conf/site10.  Pick a unique name such as 'phpadminfix'.

3) Add the following content to the file.

<IfModule mod_php4.c>
   php_admin_flag engine on

Also change the global configuration. 

1) Edit file /etc/appliance/apacheconf/apache

2) Add the following content at the top

<IfModule mod_php4.c>
   php_admin_flag engine on

Next, restart apache '/etc/rc.d/init.d/httpd restart'

NOTE: Please be sure to reverse these changes before applying the upcoming patch that will fix this issue.



Related Knowledge

Related Links
Last ModifiedUsageSatisfiedLast Used
8/20/2004 12:42:16 PM45 10/11/2007 6:28:16 AM

4cc899da08664637a8bc437308d3ddd7 3ccb419cf98083f3bb45808fba8dbc7c 6311ae17c1ee52b36e68aaf4ad066387

Email subscription for changes to this article
Save as PDF