php config security concern for c5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



a recent post on bugtraq hilighted an issue with how upstream has 
configured apache to invoke php, namely using addhandler, which has the 
behavior of matching the extension anywhere in the file.  this means 
that foo.php.jpg will be run as php.  where this becomes an issue is web 
apps that allow uploads into the webspace for images, pdfs, etc.  if the 
app assumes that anything.jpg is safe, this addhandler feature will 
surprise it.

a fix is to replace two lines in /etc/httpd/conf.d/php.conf:

AddHandler php5-script .php
AddType text/html .php

with:

<FilesMatch \.php$>
    SetHandler php5-script
    ForceType text/html
</FilesMatch>


i have reported this upstream.  hopefully they will see it as a problem 
and address it.
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux