Document Title: =============== Mozilla SeaMonkey - Filter Bypass & Persistent Vulnerability References (Source): ==================== http://www.vulnerability-lab.com/get_content.php?id=967 Mozilla Bug Tracking ID: 881686 http://www.vulnerability-lab.com/get_content.php?id=953 Mozilla Bug Tracking ID: 875818 Exclusive News: (Partners) http://news.softpedia.com/news/Critical-Validation-and-Filter-Bypass-Vulnerability-Fixed-in-Thunderbird-420962.shtml http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2013-6674 CVE-ID: ======= CVE-2013-6674 Release Date: ============= 2014-01-29 Vulnerability Laboratory ID (VL-ID): ==================================== 967 Common Vulnerability Scoring System: ==================================== 7.3 Product & Service Introduction: =============================== SeaMonkey is a free and open source cross-platform Internet suite. It is the continuation of the former Mozilla Application Suite, based on the same source code. The development of SeaMonkey is community-driven, in contrast to the Mozilla Application Suite, which until its last released version (1.7.13) was governed by the Mozilla Foundation. The new project-leading group is the SeaMonkey Council. SeaMonkey consists of a web browser (SeaMonkey Navigator), which is a descendant of the Netscape family, an e-mail and news client program (SeaMonkey Mail & Newsgroups, which shares code with Mozilla Thunderbird), an HTML editor (SeaMonkey Composer) and an IRC client (ChatZilla). The software suite supports skins. It comes with two skins in the default installation, Modern and Classic. Mail Mail features includes support for multiple accounts {the documentation does not state how many}, junk mail detection, message filters, HTML message support, a dictionary, an address book, customizable labels, add-ons and mail views as well as integration with the rest of suite. Composer SeaMonkey Composer 2.16 running on Ubuntu 12.04. SeaMonkey Composer is a WYSIWYG HTML editor. Its main user interface features four tabs: Normal (WYSIWYG), HTML tags, HTML code, and browser preview. The generated code is HTML 4.01 Transitional. As of version 1.1.13, SeaMonkey Composer supports basic text formatting and styling, insertion of hyperlinks and images, and the creation of tables. It does not support the addition of form elements (text fields, check boxes, and buttons). SeaMonkey Composer is scheduled to be updated with the release of KompoZer 0.8 which is currently under development. Vendor Homepage: http://www.mozilla.org Product website: http://www.seamonkey-project.org/releases/seamonkey2.17/ Abstract Advisory Information: ============================== The Vulnerability Laboratory Research Team discovered a filter bypass and persistent validation web vulnerability in the Mozilla Seamonkey application. Vulnerability Disclosure Timeline: ================================== 2013-05-10: Researcher Notification & Coordination (Ateeq ur Rehman Khan) 2013-05-11: Vendor Notification (Mozilla Security Incident Team) 2013-05-21: Vendor Response/Feedback (Mozilla Security Incident Team) 2014-01-18: Vendor Fix/Patch (Mozilla Developer Team - Reward 1.500$ SWB) 2014-01-27: Public Disclosure (Vulnerability Laboratory) Discovery Status: ================= Published Affected Product(s): ==================== Mozilla Product: Seamonkey 2.17.1 Exploitation Technique: ======================= Remote Severity Level: =============== High Technical Details & Description: ================================ Since Seamonkey is using Mozilla Thunderbird at the backend for its mail client, It is prone to the same Persistent vulnerability that i had reported earlier to Mozilla Security Team. I will include the details again in this advisory for your reference and ease. Basically , attaching a debugger with the seamonkey binary file, it was initially noticed that malicious java-script tags were being filtered / blocked. By default, HTML tags like When the browser loads the object tag, it loads an object (in our case, it’s a javascript) assigned to its data attribute. This causes execution of our javascript. We were able to bypass the application blacklist filter because of the base64-encoded payload. 2.0 Seamonkey HTML Composer Preview - Input Filter Bypass Vulnerability Details: By default, html tags like work. Its an HTML composer, maybe its not allowed to filter any dangerous / malicious code requests by default and I am definitely not challenging that fact at all. I just felt its important to highlight the fact that if all other tags are being blocked in the preview, then this one actually bypasses the current Seamonkey Composer preview filters and still works. Vulnerable Product(s): [+] Seamonkey 2.17.1 - Latest Release Vulnerable Module(s): [+] Composer (CTRL+4) Vulnerable Section(s): [+] HTML Source 2.1 Proof of Concept: a) Open New Seamonkey Composer Window b) Goto Source c) Copy/Paste any one of the payloads mentioned under the "Payload" section, anywhere in the Code before tag. Example Code that i used for this POC: testtesttest

d) Click on Preview and you should be able to see a Javascript proving the existence of this Filter Bypass Vulnerability Payload #1 Payload #2 2.3 Interesting Raw Application Logs captured during the entire process of testing: [JavaScript Error: "ReferenceError: dOcUmeNt is not defined" {file: "data:text/html;base64, PHNjcmlwdD5hbGVydChkT2NVbWVOdC5Db29LaWUpOzwvc2NyaXB0Pg==" line: 1}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Error: "TypeError: t his.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64, PHNjcmlwdD5hbGVydChkT2NVbWVOdC5Db29LaWUpOzwvc2NyaXB0Pg==" line: 0}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64,PHNjcmlwdD5hbGVydChkb2N1bWVudC5jb29raWUpOzwvc2NyaXB0Pg==" line: 0}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64,PHNjcmlwdD5hbGVydChkb2N1bWVudC5jb29raWUpOzwvc2NyaXB0Pg==" line: 0}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64,PHNjcmlwdD5hbGVydCgiVnVsbmVyYWJsZSIpOzwvc2NyaXB0Pg==" line: 0}] ModLoad: 6fcd0000 6fce2000 C:\Windows\SysWOW64\dhcpcsvc.DLL ModLoad: 6fcc0000 6fccd000 C:\Windows\SysWOW64\dhcpcsvc6.DLL [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64,PHNjcmlwdD5hbGVydCgiVnVsbmVyYWJsZSIpOzwvc2NyaXB0Pg==" line: 0}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "Unknown property '-moz-border-radius-bottomleft'. Declaration dropped." {file: "https://www.google.com/search?q=a%2520%2F%3E%22%3Ch1%3E jakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq= t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown property '-moz-border-radius-topleft'. Declaration dropped." {file: "https://www.google.com/search?q= a%2520%2F%3E%22%3Ch1%3Ejakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown property '-moz-border-radius-topright'. Declaration dropped." {file: "https://www.google.com /search?q=a%2520%2F%3E%22%3Ch1%3Ejakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown property '-moz-border-radius-bottomright'. Declaration dropped." {file: "https://www.google.com/search?q=a%2520%2F %3E%22%3Ch1%3Ejakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Error in parsing value for 'filter'. Declaration dropped." {file: "https://www.google.com/search?q=a%2520%2F%3E%22%3Ch1%3Ejakjbsf %3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown property '-moz-border-radius'. Declaration dropped." {file: "https://www.google.com/search?q=a%2520%2F%3E%22%3Ch1%3Ejakjbsf %3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown property '-moz-box-shadow'. Declaration dropped." {file: "https://www.google.com/search?q=a%2520%2F%3E%22%3Ch1%3Ejakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] [JavaScript Warning: "Unknown pseudo-class or pseudo-element '-ms-clear'. Ruleset ignored due to bad selector." {file: "https://www.google.com/search?q= a%2520%2F%3E%22%3Ch1%3Ejakjbsf%3C%2Fh1%3E&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:unofficial&client=seamonkey-a" line: 1}] ModLoad: 139d0000 13a21000 C:\Windows\SysWOW64\WINSPOOL.DRV (1af0.258c): Unknown exception - code 000006ba (first chance) [JavaScript Error: "NS_ERROR_NOT_INITIALIZED: Component returned failure code: 0xc1f30001 (NS_ERROR_NOT_INITIALIZED) [nsIEditor.selectionController]" {file: "chrome://navigator/content/urlbarBindings.xml" line: 107}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "WARN addons.updates: Update manifest for modern@themes.mozilla.org did not contain an updates property" {file: "resource://gre/modules/AddonUpdateChecker.jsm" line: 312}] [JavaScript Warning: "WARN addons.updates: Update manifest for {972ce4c6-7e08-4474-a285-3208198ce6fd} did not contain an updates property" {file: "resource://gre/modules/AddonUpdateChecker.jsm" line: 312}] versioncheck.addons.mozilla.org : server does not support RFC 5746, see CVE-2009-3555 versioncheck.addons.mozilla.org : server does not support RFC 5746, see CVE-2009-3555 [JavaScript Error: "TypeError: this.tabbox is null" {file: "chrome://global/content/bindings/tabbox.xml" line: 480}] [JavaScript Warning: "The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it." {file: "data:text/html;base64,PHNjcmlwdD5hbGVydChkb2N1bWVudC5jb29raWUpOzwvc2NyaXB0Pg==" line: 0}] [JavaScript Warning: "The character encoding declaration of the HTML document was not found when prescanning the first 1024 bytes of the file. When viewed in a differently-configured browser, this page will reload automatically. The encoding declaration needs to be moved to be within the first 1024 bytes of the file." {file: "file:///C:/Users/John%20Doe/Desktop/testtesttest.html" line: 5}] Solution - Fix & Patch: ======================= 2014-01-18: Vendor Fix/Patch (Mozilla Developer Team - Reward 1.500$ SWB) Security Risk: ============== The security risk of the persistent input validation and input filter bypass vulnerabilities are estimated as high(+). Credits & Authors: ================== Vulnerability Laboratory [Research Team] - Ateeq ur Rehman Khan [ateeq@evolution-sec.com] [www.vulnerability-lab.com] Disclaimer & Information: ========================= The information provided in this advisory is provided as it is without any warranty. Vulnerability-Lab disclaims all warranties, either expressed or implied, including the warranties of merchantability and capability for a particular purpose. Vulnerability- Lab or its suppliers are not liable in any case of damage, including direct, indirect, incidental, consequential loss of business profits or special damages, even if Vulnerability-Lab or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for consequential or incidental damages so the foregoing limitation may not apply. We do not approve or encourage anybody to break any vendor licenses, policies, deface websites, hack into databases or trade with fraud/stolen material. Domains: www.vulnerability-lab.com - www.vuln-lab.com - www.vulnerability-lab.com/register Contact: admin@vulnerability-lab.com - support@vulnerability-lab.com - research@vulnerability-lab.com Section: video.vulnerability-lab.com - forum.vulnerability-lab.com - news.vulnerability-lab.com Social: twitter.com/#!/vuln_lab - facebook.com/VulnerabilityLab - youtube.com/user/vulnerability0lab Feeds: vulnerability-lab.com/rss/rss.php - vulnerability-lab.com/rss/rss_upcoming.php - vulnerability-lab.com/rss/rss_news.php Any modified copy or reproduction, including partially usages, of this file requires authorization from Vulnerability Laboratory. Permission to electronically redistribute this alert in its unmodified form is granted. All other rights, including the use of other media, are reserved by Vulnerability-Lab Research Team or its suppliers. All pictures, texts, advisories, source code, videos and other information on this website is trademark of vulnerability-lab team & the specific authors or managers. To record, list (feed), modify, use or edit our material contact (admin@vulnerability-lab.com or support@vulnerability-lab.com) to get a permission. Copyright © 2014 | Vulnerability Laboratory