Secunia CSI7
Advisories
Research
Forums
Create Profile
Our Commitment
About the Team
Disclosure Policy
SVCRP

Secunia Research: The Address Book Multiple Vulnerabilities

====================================================================== 

                     Secunia Research 03/01/2007

           - The Address Book Multiple Vulnerabilities -

====================================================================== 
Table of Contents

Affected Software....................................................1
Severity.............................................................2
Vendor's Description of Software.....................................3
Description of Vulnerability.........................................4
Solution.............................................................5
Time Table...........................................................6
Credits..............................................................7
References...........................................................8
About Secunia........................................................9
Verification........................................................10

====================================================================== 
1) Affected Software 

* The Address Book 1.04e

NOTE: Other versions may also be affected.

====================================================================== 
2) Severity 

Rating: Highly critical
Impact: System compromise
        Exposure of sensitive information
        SQL injection
        Cross-site scripting
        Security bypass
        Cross-Site Request Forgery
Where:  Remote

====================================================================== 
3) Vendor's Description of Software 

"The Address Book is a free, open source address management system,
utilizing the combined power of PHP scripting and MySQL databases to
provide a flexible, robust system allowing users to add a virtually
unlimited number of addresses and other info.".

Product Link:
http://sourceforge.net/projects/theaddressbook

====================================================================== 
4) Description of Vulnerability

Secunia Research has discovered some vulnerabilities in The Address
Book, which can be exploited by malicious people to bypass certain
security restrictions, conduct cross-site scripting, cross-site request
forgery, script insertion, and SQL injection attacks, disclose
sensitive information, and compromise a vulnerable system.

1) Input passed to the "lastname" and "firstname" parameters when
adding a new entry, the "passwordOld" and "passwordNew" parameters when
changing the password in users.php, the "id" parameter when confirming
a user in users.php, the "language" and "defaultLetter" parameters when
changing personal options in users.php, the "goTo" and "search"
parameters in search.php during searches, the "groupAddName" parameter
when adding a new group in save.php, and the "newuserPass",
"newuserType", and "newuserEmail" parameters when an administrator adds
a user in users.php isn't properly sanitised before being used in a SQL
query. This can be exploited to manipulate SQL queries by injecting
arbitrary SQL code.

Successful exploitation requires that "magic_quotes_gpc" is disabled
(except for the "id" parameter).

2) An input validation error exists in the picture upload handling due
to missing verification of the content of uploaded images. This can be
exploited to execute arbitrary HTML and script code in a user's browser
session in context of an affected site when a specially crafted HTML
document with the ".gif" or ".jpg" file extension is viewed directly in
the Microsoft Internet Explorer browser.

3) Input passed to the "email" and "websites" parameters when adding a
new entry, and the "groupAddName" parameter when adding a new group in
save.php isn't properly sanitised before being used. This can be
exploited to inject arbitrary HTML and script code, which will be
executed in a user's browser session in context of an affected site
when the malicious user data is viewed.

Example:
Adding new entry: " onmouseover=[code] "

4) User credentials are included in the exported MySQL dump file
generated by export.php, which is accessible by normal users. This
can be exploited to disclose usernames and encrypted passwords
(MD5 sum).

5) Input passed to the "language" parameter when changing personal
options in users.php isn't properly verified, before it is used to
include files. This can be exploited to include arbitrary files from
local resources.

This can further be exploited to include arbitrary PHP code injected
into uploaded image files.

Example:
../mugshots/[file].gif%00

6) Input passed to the "errorMsg" parameter in index.php, and the
"goTo" and "search" parameters in search.php isn't properly sanitised
before being returned to the user. This can be exploited to execute
arbitrary HTML and script code in a user's browser session in context
of an affected site.

Successful exploitation requires that "register_globals" is enabled
(except for the "goTo" parameter).

7) It is possible to register a new user account in register.php even
when "Allow User Self-Registration" has been disabled by setting the
"mode" parameter to "confirm".

8) An error exists in the picture upload handling due to the
application only validating the "Content-Type" header and not the file
extension. This can be exploited to upload a malicious PHP script
inside the web root.

9) An error exists due to the application allowing users to perform
certain actions via HTTP requests without performing any validity
checks to verify the user's request.

Example:
http://[host]/users.php?action=deleteuser&id=[id]

====================================================================== 
5) Solution 

Use another product.

====================================================================== 
6) Time Table 

07/09/2006 - Vendor notified.
21/09/2006 - Vendor response.
27/11/2006 - Vendor contacted (status request).
02/12/2006 - Vendor response.
03/01/2007 - Public disclosure.

====================================================================== 
7) Credits 

Secunia Research

====================================================================== 
8) References

The Common Vulnerabilities and Exposures (CVE) project has assigned 
the following CVE identifiers for the vulnerabilities:

CVE-2006-4575 - SQL injection (#1)
CVE-2006-4576 - Picture Upload XSS (#2)
CVE-2006-4577 - Script insertion and XSS (#3 and #6)
CVE-2006-4578 - MySQL dump file credential exposure (#4)
CVE-2006-4579 - File inclusion (#5)
CVE-2006-4580 - "Allow User Self-Registration" bypass (#7)
CVE-2006-4581 - PHP script uploading (#8)
CVE-2006-4582 - Cross-Site Request Forgery (#9)

====================================================================== 
9) About Secunia

Secunia offers vulnerability management solutions to corporate
customers with verified and reliable vulnerability intelligence
relevant to their specific system configuration:

http://corporate.secunia.com/

Secunia also provides a publicly accessible and comprehensive advisory
database as a service to the security community and private 
individuals, who are interested in or concerned about IT-security.

http://secunia.com/

Secunia believes that it is important to support the community and to
do active vulnerability research in order to aid improving the 
security and reliability of software in general:

http://corporate.secunia.com/secunia_research/33/

Secunia regularly hires new skilled team members. Check the URL below to
see currently vacant positions:

http://secunia.com/secunia_vacancies/

Secunia offers a FREE mailing list called Secunia Security Advisories:

http://secunia.com/secunia_security_advisories/ 

====================================================================== 
10) Verification 

Please verify this advisory by visiting the Secunia website:
http://secunia.com/secunia_research/2006-76/

Complete list of vulnerability reports published by Secunia Research:
http://secunia.com/secunia_research/

======================================================================




 Products Solutions Customers Partner Resources Company
 
 Corporate
Vulnerability Intelligence Manager (VIM)
Corporate Software Inspector (CSI)
Consumer
Personal Software Inspector (PSI)
Online Software Inspector (OSI)
 Industry
Compliance
Technology
Integration
 Customers
Testimonials
 VARS
MSSP
Technology Partners
References
 Factsheets
Reports
Webinars
Events
 About us
Careers
Memberships
Newsroom


 
© 2002-2014 Secunia ApS - Rued Langgaards Vej 8, 4th floor, DK-2300 Copenhagen, Denmark - +45 7020 5144
Terms & Conditions and Copyright - Privacy - Report Vulnerability