Vulnerabilities > CVE-2009-0695 - Improper Authentication vulnerability in Dell Wyse Device Manager 4.7.0/4.7.1/4.7.2

047910
CVSS 7.5 - HIGH
Attack vector
NETWORK
Attack complexity
LOW
Privileges required
NONE
Confidentiality impact
PARTIAL
Integrity impact
PARTIAL
Availability impact
PARTIAL
network
low complexity
dell
CWE-287
nessus
exploit available
metasploit

Summary

hagent.exe in Wyse Device Manager (WDM) 4.7.x does not require authentication for commands, which allows remote attackers to obtain management access via a crafted query, as demonstrated by a V52 query that triggers a power-off action.

Vulnerable Configurations

Part Description Count
Application
Dell
3

Common Weakness Enumeration (CWE)

Common Attack Pattern Enumeration and Classification (CAPEC)

  • Authentication Abuse
    An attacker obtains unauthorized access to an application, service or device either through knowledge of the inherent weaknesses of an authentication mechanism, or by exploiting a flaw in the authentication scheme's implementation. In such an attack an authentication mechanism is functioning but a carefully controlled sequence of events causes the mechanism to grant access to the attacker. This attack may exploit assumptions made by the target's authentication procedures, such as assumptions regarding trust relationships or assumptions regarding the generation of secret values. This attack differs from Authentication Bypass attacks in that Authentication Abuse allows the attacker to be certified as a valid user through illegitimate means, while Authentication Bypass allows the user to access protected material without ever being certified as an authenticated user. This attack does not rely on prior sessions established by successfully authenticating users, as relied upon for the "Exploitation of Session Variables, Resource IDs and other Trusted Credentials" attack patterns.
  • Exploiting Trust in Client (aka Make the Client Invisible)
    An attack of this type exploits a programs' vulnerabilities in client/server communication channel authentication and data integrity. It leverages the implicit trust a server places in the client, or more importantly, that which the server believes is the client. An attacker executes this type of attack by placing themselves in the communication channel between client and server such that communication directly to the server is possible where the server believes it is communicating only with a valid client. There are numerous variations of this type of attack.
  • Utilizing REST's Trust in the System Resource to Register Man in the Middle
    This attack utilizes a REST(REpresentational State Transfer)-style applications' trust in the system resources and environment to place man in the middle once SSL is terminated. Rest applications premise is that they leverage existing infrastructure to deliver web services functionality. An example of this is a Rest application that uses HTTP Get methods and receives a HTTP response with an XML document. These Rest style web services are deployed on existing infrastructure such as Apache and IIS web servers with no SOAP stack required. Unfortunately from a security standpoint, there frequently is no interoperable identity security mechanism deployed, so Rest developers often fall back to SSL to deliver security. In large data centers, SSL is typically terminated at the edge of the network - at the firewall, load balancer, or router. Once the SSL is terminated the HTTP request is in the clear (unless developers have hashed or encrypted the values, but this is rare). The attacker can utilize a sniffer such as Wireshark to snapshot the credentials, such as username and password that are passed in the clear once SSL is terminated. Once the attacker gathers these credentials, they can submit requests to the web service provider just as authorized user do. There is not typically an authentication on the client side, beyond what is passed in the request itself so once this is compromised, then this is generally sufficient to compromise the service's authentication scheme.
  • Man in the Middle Attack
    This type of attack targets the communication between two components (typically client and server). The attacker places himself in the communication channel between the two components. Whenever one component attempts to communicate with the other (data flow, authentication challenges, etc.), the data first goes to the attacker, who has the opportunity to observe or alter it, and it is then passed on to the other component as if it was never intercepted. This interposition is transparent leaving the two compromised components unaware of the potential corruption or leakage of their communications. The potential for Man-in-the-Middle attacks yields an implicit lack of trust in communication or identify between two components.

Exploit-Db

  • descriptionWyse Rapport Hagent Fake Hserver Command Execution. CVE-2009-0695. Remote exploits for multiple platform
    idEDB-ID:9934
    last seen2016-02-01
    modified2009-07-10
    published2009-07-10
    reporterkf
    sourcehttps://www.exploit-db.com/download/9934/
    titleWyse Rapport Hagent Fake Hserver - Command Execution
  • descriptionWyse Rapport Hagent Fake Hserver Command Execution. CVE-2009-0695. Remote exploits for multiple platform
    idEDB-ID:16287
    last seen2016-02-01
    modified2010-11-11
    published2010-11-11
    reportermetasploit
    sourcehttps://www.exploit-db.com/download/16287/
    titleWyse Rapport Hagent Fake Hserver Command Execution
  • descriptionWyse - Machine Remote Power off (DOS) without any privilege. CVE-2009-0693,CVE-2009-0695. Dos exploit for hardware platform
    fileexploits/hardware/dos/19137.rb
    idEDB-ID:19137
    last seen2016-02-02
    modified2012-06-14
    platformhardware
    port
    published2012-06-14
    reporterit.solunium
    sourcehttps://www.exploit-db.com/download/19137/
    titleWyse - Machine Remote Power off DOS without any privilege
    typedos

Metasploit

descriptionThis module exploits the Wyse Rapport Hagent service by pretending to be a legitimate server. This process involves starting both HTTP and FTP services on the attacker side, then contacting the Hagent service of the target and indicating that an update is available. The target will then download the payload wrapped in an executable from the FTP service.
idMSF:EXPLOIT/MULTI/WYSE/HAGENT_UNTRUSTED_HSDATA
last seen2020-04-11
modified2017-07-24
published2009-08-19
references
reporterRapid7
sourcehttps://github.com/rapid7/metasploit-framework/blob/master//modules/exploits/multi/wyse/hagent_untrusted_hsdata.rb
titleWyse Rapport Hagent Fake Hserver Command Execution

Nessus

NASL familyWindows
NASL idWYSE_WDM_BUFFER_OVERFLOW.NASL
descriptionWyse Device Manager is installed on the remote system. The installed version is affected by a buffer overflow vulnerability. By sending a specially crafted request to the server, it may be possible for an unauthorized attacker to crash the server or execute arbitrary commands on the remote system with system level privileges.
last seen2020-06-01
modified2020-06-02
plugin id40333
published2009-07-21
reporterThis script is Copyright (C) 2009-2018 Tenable Network Security, Inc.
sourcehttps://www.tenable.com/plugins/nessus/40333
titleWyse Device Manager Buffer Overflow
code
#
# (C) Tenable Network Security, Inc.
#

include("compat.inc");

if (description)
{
  script_id(40333);
  script_version("1.16");
  script_cvs_date("Date: 2018/11/15 20:50:29");

  script_cve_id("CVE-2009-0693", "CVE-2009-0695");  
  script_bugtraq_id(35649, 54028);
  script_xref(name:"CERT", value:"654545");
  script_xref(name:"Secunia", value:"35794");

  script_name(english:"Wyse Device Manager Buffer Overflow");
  script_summary(english:"Checks if hotpatch is installed");
 
  script_set_attribute(attribute:"synopsis", value:
"The remote Windows host contains an application that is affected by a
buffer overflow vulnerability.");

  script_set_attribute(attribute:"description", value:
"Wyse Device Manager is installed on the remote system.  The installed
version is affected by a buffer overflow vulnerability.  By sending a
specially crafted request to the server, it may be possible for an
unauthorized attacker to crash the server or execute arbitrary
commands on the remote system with system level privileges.");

  script_set_attribute(attribute:"see_also", value:"https://www.theregister.co.uk/2009/07/10/wyse_remote_exploit_bugs/");
  # http://web.archive.org/web/20110726030311/http://www.wyse.com/serviceandsupport/Wyse%20Security%20Bulletin%20WSB09-01.pdf
  script_set_attribute(attribute:"see_also", value:"http://www.nessus.org/u?27941b3b");
  script_set_attribute(attribute:"solution", value:"Apply vendor-supplied patches.");
  script_set_cvss_base_vector("CVSS2#AV:N/AC:L/Au:N/C:C/I:C/A:C");
  script_set_cvss_temporal_vector("CVSS2#E:F/RL:OF/RC:C");
  script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
  script_set_attribute(attribute:"exploit_available", value:"true");
 script_set_attribute(attribute:"metasploit_name", value:'Wyse Rapport Hagent Fake Hserver Command Execution');
 script_set_attribute(attribute:"exploit_framework_metasploit", value:"true");

  script_set_attribute(attribute:"vuln_publication_date",  value:"2009/07/10");
  script_set_attribute(attribute:"patch_publication_date",  value:"2009/07/10");
  script_set_attribute(attribute:"plugin_publication_date",  value:"2009/07/21");

  script_set_attribute(attribute:"plugin_type", value:"local");
  script_set_attribute(attribute:"cpe",value:"cpe:/a:dell:wyse_device_manager");
  script_end_attributes();
 
  script_category(ACT_GATHER_INFO);
  script_family(english:"Windows");

  script_copyright(english:"This script is Copyright (C) 2009-2018 Tenable Network Security, Inc.");

  script_dependencies("smb_enum_services.nasl", "smb_hotfixes.nasl","http_version.nasl");
  script_require_keys("SMB/Registry/Enumerated");
  script_require_ports(139, 445,80);

  exit(0);
}


include("global_settings.inc");
include("misc_func.inc");
include("http.inc");
include("smb_func.inc");


if (report_paranoia < 2)
{
 port = get_http_port(default:80);
 banner = get_http_banner(port:port); 
 if(!banner || "Microsoft-IIS" >!< banner) exit(0, "The web server does not appear to be Microsoft IIS.");

 res = http_send_recv3(method:"GET", item:"/hserver.dll?&V94",port:port, exit_on_fail: 1 );
 
 # If we don't see a response, then we are not looking at WDM.
 # For e.g. 
 # Please append |Tsk=0 to the V94 command for more options 

 if(!ereg(pattern:"Please append |Tsk=0 to the V94 command for more options",string:res[2]))
 exit(0, "Wyse WDM Service was not detected.");
}

if (!get_kb_item("SMB/Registry/Enumerated")) exit(0, "SMB/Registry/Enumerated does not exist in KB.");

# Connect to the appropriate share.
name    =  kb_smb_name();
port    =  kb_smb_transport();
if (!get_port_state(port)) exit(1, "Port "+port+" is closed.");
login   =  kb_smb_login();
pass    =  kb_smb_password();
domain  =  kb_smb_domain();

soc = open_sock_tcp(port);
if (!soc) exit(1, "Connection refused on port "+port+".");

session_init(socket:soc, hostname:name);
rc = NetUseAdd(login:login, password:pass, domain:domain, share:"IPC$");
if (rc != 1) {
  NetUseDel();
  exit(1, "Can't connect to IPC$ share.");
}

# Connect to remote registry.
hklm = RegConnectRegistry(hkey:HKEY_LOCAL_MACHINE);
if (isnull(hklm))
{
  NetUseDel();
  exit(1, "Can't connect to remote registry.");
}

# Find where it's installed.
path = NULL;
release_ver = NULL;
patch = NULL;

key = "SOFTWARE\Rapport";
key_h = RegOpenKey(handle:hklm, key:key, mode:MAXIMUM_ALLOWED);
if (!isnull(key_h))
{
  value = RegQueryValue(handle:key_h, item:"ReleaseVersion");
  if (!isnull(value)) release_ver = value[1];

  RegCloseKey(handle:key_h);
}

key = "SOFTWARE\Rapport\Install";
key_h = RegOpenKey(handle:hklm, key:key, mode:MAXIMUM_ALLOWED);
if (!isnull(key_h))
{
  value = RegQueryValue(handle:key_h, item:"BaseDir");
  if (!isnull(value)) path = value[1];
 
  value = RegQueryValue(handle:key_h, item:"RptInstalled");
  if (!isnull(value)) patch = value[1];

  RegCloseKey(handle:key_h);
}
RegCloseKey(handle:hklm);

if (isnull(path))
{
  NetUseDel();
  exit(0, "Wyse WDM is not installed.");
}

if (isnull(release_ver))
{
  NetUseDel();
  exit(0, "Wyse WDM release_ver is NULL.");
}
NetUseDel(close:FALSE);


known_format = 0;
if(ereg(pattern:"^0*HF0*40720[0-9]+",string:patch))
{
  # Get rid of starting 0's and HF
  # For e.g. 00HF040720324   (unpatched default v4.7.2 install)
  #            HF04072019009 (patched)

  patch = ereg_replace(pattern:"^0*HF0*40720([0-9]+)$",string:patch,replace:"\1");
  patch = int(patch);
  known_format = 1;
}

# Grab the file version of file HServerInit.exe, just to make sure the 
# file exists. But rely on the version found in the registry since it
# is accurate.

share = ereg_replace(pattern:"^([A-Za-z]):.*", replace:"\1$", string:path);
exe =  ereg_replace(pattern:"^[A-Za-z]:(.*)", replace:"\1\HServerInit.exe", string:path);

rc = NetUseAdd(login:login, password:pass, domain:domain, share:share);
if (rc != 1)
{
  NetUseDel();
  exit(1, "Can't connect to "+share+" share.");
}

fh = CreateFile(
  file:exe,
  desired_access:GENERIC_READ,
  file_attributes:FILE_ATTRIBUTE_NORMAL,
  share_mode:FILE_SHARE_READ,
  create_disposition:OPEN_EXISTING
);
if (!isnull(fh))
{
  ver = GetFileVersion(handle:fh);
  CloseFile(handle:fh);
}
NetUseDel();

if (!isnull(ver))
{
  v = split(release_ver,sep:'.',keep:FALSE);
  for (i=0; i<max_index(v); i++)
    v[i] = int(v[i]);

  if (
    (v[0]  < 4 ) ||
    (v[0] == 4 && v[1]  < 7) || 
    (v[0] == 4 && v[1] == 7 && v[2]  < 2) ||
    (v[0] == 4 && v[1] == 7 && v[2] == 2 && isnull(patch)) ||
    (v[0] == 4 && v[1] == 7 && v[2] == 2 && !isnull(patch) && known_format && patch < 19009)
  ) 
  {
    if (report_verbosity > 0)
    {
      report = string(
        "\n",
        "  Version : ", release_ver, "\n",
        "  Path    : ", path, "\n"
      );
      security_hole(port:port, extra:report);
    }
    else security_hole(port);
    exit(0);
  }
  else exit(0, "Wyse WDM version "+release_ver+" is installed and not vulnerable.");
}
else exit(1, "Couldn't get file version of '"+exe+"'.");

Packetstorm