Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 174451 (CVE-2007-2024) - www-apps/phpwiki script upload vulnerability (CVE-2007-{2024,2025})
Summary: www-apps/phpwiki script upload vulnerability (CVE-2007-{2024,2025})
Status: RESOLVED FIXED
Alias: CVE-2007-2024
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Gentoo Security
URL: http://secunia.com/advisories/24888/
Whiteboard: B1 [glsa] p-y
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-13 13:05 UTC by Pierre-Yves Rofes (RETIRED)
Modified: 2008-08-17 18:08 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pierre-Yves Rofes (RETIRED) gentoo-dev 2007-04-13 13:05:36 UTC
A vulnerability has been discovered in PhpWiki, which can be exploited by malicious people to compromise a vulnerable system.

The "UpLoad" wiki page (index.php/UpLoad) fails to properly validate the extension of an uploaded file. The blacklist of disallowed file extensions does not include for example ".php3" and ".phtml". This can be exploited to upload files with such extensions and execute arbitrary PHP code on the server.

Successful exploitation requires being logged in and that the webserver is configured to execute PHP scripts with such extensions. In the default configuration of PhpWiki, no registration or validation is necessary to log in.

NOTE: The vulnerability is currently being actively exploited.

The vulnerability is confirmed in version 1.3.12p3. Other versions may also be affected.

Solution:
Disable the UpLoad functionality by giving the file "lib/plugin/UpLoad.php" the permissions 000 or by moving the file outside of the web tree.
Comment 1 Pierre-Yves Rofes (RETIRED) gentoo-dev 2007-04-13 13:06:26 UTC
setting status. web-apps, please advise.
Comment 2 Pierre-Yves Rofes (RETIRED) gentoo-dev 2007-04-13 13:21:03 UTC
Hmm no, I was right at first, it's a B1 since ppc had a stable version. sorry for the noise.
Comment 3 Gunnar Wrobel (RETIRED) gentoo-dev 2007-05-10 13:03:17 UTC
There is currently no fixed version available from UPSTREAM. I did proceed as suggested by the advisory and automatically remove the UpLoad.php file during the installation.

Now there is an updated ebuild phpwiki-1.3.10-r3 that contains this fix. It is still marked unstable for ppc. Please test and mark stable on ppc as soon as possible.

I removed two older ebuilds phpwiki-1.3.1{1,2} and added phpwiki-1.3.13_rc1 which will also remove UpLoad.php automatically during install.

Please advise people with a phpwiki installation to immeadiately remove their UpLoad.php file.
Comment 4 Pierre-Yves Rofes (RETIRED) gentoo-dev 2007-05-10 13:19:43 UTC
ppc, please test and mark www-apps/phpwiki-1.3.10-r3 stable.
Comment 5 Tobias Scherbaum (RETIRED) gentoo-dev 2007-05-14 18:35:52 UTC
ppc stable
Comment 6 Pierre-Yves Rofes (RETIRED) gentoo-dev 2007-05-14 18:47:44 UTC
thanks. ready for glsa.
Comment 7 Raphael Marichez (Falco) (RETIRED) gentoo-dev 2007-05-17 13:31:18 UTC
GLSA 200705-16, thanks everybody