Vulnerabilities > CVE-2013-6031 - Improper Authentication vulnerability in Huawei E355 and E355 Firmware

047910
CVSS 4.3 - MEDIUM
Attack vector
ADJACENT_NETWORK
Attack complexity
MEDIUM
Privileges required
NONE
Confidentiality impact
PARTIAL
Integrity impact
PARTIAL
Availability impact
NONE
huawei
CWE-287
nessus
metasploit

Summary

The Huawei E355 adapter with firmware 21.157.37.01.910 does not require authentication for API pages, which allows remote attackers to change passwords and settings, or obtain sensitive information, via a direct request to (1) api/wlan/security-settings, (2) api/device/information, (3) api/wlan/basic-settings, (4) api/wlan/mac-filter, (5) api/monitoring/status, or (6) api/dhcp/settings.

Vulnerable Configurations

Part Description Count
OS
Huawei
1
Hardware
Huawei
1

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.

Metasploit

descriptionThis module exploits an unauthenticated information disclosure vulnerability in Huawei SOHO routers. The module will gather information by accessing the /api pages where authentication is not required, allowing configuration changes as well as information disclosure, including any stored SMS.
idMSF:AUXILIARY/GATHER/HUAWEI_WIFI_INFO
last seen2020-06-07
modified2017-07-24
published2015-01-24
referenceshttps://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-6031
reporterRapid7
sourcehttps://github.com/rapid7/metasploit-framework/blob/master//modules/auxiliary/gather/huawei_wifi_info.rb
titleHuawei Datacard Information Disclosure Vulnerability

Nessus

NASL familyCGI abuses
NASL idHUAWEI_SECURITY_BYPASS.NASL
descriptionThe remote Huawei device is affected by an authentication bypass vulnerability. Nessus was able to exploit this vulnerability to gain access to sensitive information on the device (such as the WPA preshared key). A remote attacker could exploit this flaw to perform administrative functions on the device.
last seen2020-06-01
modified2020-06-02
plugin id73155
published2014-03-24
reporterThis script is Copyright (C) 2014-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
sourcehttps://www.tenable.com/plugins/nessus/73155
titleHuawei Multiple Device Authentication Bypass
code
#
# (C) Tenable Network Security, Inc.
#

include("compat.inc");

if (description)
{
  script_id(73155);
  script_version("1.8");
  script_cvs_date("Date: 2019/11/26");

  script_cve_id("CVE-2013-6031");
  script_bugtraq_id(66017, 66065);
  script_xref(name:"CERT", value:"341526");
  script_xref(name:"EDB-ID", value:"32161");

  script_name(english:"Huawei Multiple Device Authentication Bypass");
  script_summary(english:"Tries to exploit authentication bypass vulnerability");

  script_set_attribute(attribute:"synopsis", value:
"The remote device is affected by an authentication bypass
vulnerability.");
  script_set_attribute(attribute:"description", value:
"The remote Huawei device is affected by an authentication bypass
vulnerability.  Nessus was able to exploit this vulnerability to gain
access to sensitive information on the device (such as the WPA preshared
key).  A remote attacker could exploit this flaw to perform
administrative functions on the device.");
  # https://www.sec-consult.com/fxdata/seccons/prod/temedia/advisories_txt/20140307-0_Huawei_E5331_MiFi_Unauthenticated_access_and_settings_modifications_v10.txt
  script_set_attribute(attribute:"see_also", value:"http://www.nessus.org/u?1d7f5eab");
  script_set_attribute(attribute:"solution", value:
"Apply the appropriate firmware update, or restrict access to the device
if an update is not available.");
  script_set_cvss_base_vector("CVSS2#AV:A/AC:M/Au:N/C:P/I:P/A:N");
  script_set_cvss_temporal_vector("CVSS2#E:POC/RL:U/RC:ND");
  script_set_attribute(attribute:"cvss_score_source", value:"CVE-2013-6031");

  script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
  script_set_attribute(attribute:"exploit_available", value:"true");
  script_set_attribute(attribute:"exploited_by_nessus", value:"true");

  script_set_attribute(attribute:"vuln_publication_date", value:"2014/03/06");
  script_set_attribute(attribute:"patch_publication_date", value:"2014/03/06");
  script_set_attribute(attribute:"plugin_publication_date", value:"2014/03/24");

  script_set_attribute(attribute:"plugin_type", value:"remote");
  script_set_attribute(attribute:"cpe", value:"cpe:/h:huawei:e355");
  script_set_attribute(attribute:"cpe", value:"cpe:/o:huawei:e355_firmware");
  script_end_attributes();

  script_category(ACT_ATTACK);
  script_family(english:"CGI abuses");

  script_copyright(english:"This script is Copyright (C) 2014-2019 and is owned by Tenable, Inc. or an Affiliate thereof.");

  script_dependencies("http_version.nasl");
  script_require_keys("www/ipwebs");
  script_require_ports("Services/www", 80, 443);

  exit(0);
}

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

get_kb_item_or_exit("www/ipwebs");

port = get_http_port(default:80, embedded:TRUE);

server_name = http_server_header(port:port);
if (stridx(server_name,"IPWEBS/") != 0) audit(AUDIT_NOT_LISTEN, "A Huawei router web server", port);

check_list =
  make_array("/api/wlan/security-settings", "WifiWpapsk",
             "/api/wlan/wps", "WPSPin",
             "/api/device/information", "WebUIVersion");

report = '';

foreach check (keys(check_list))
{
  res = http_send_recv3(item         : check,
                        method       : "GET",
                        port         : port,
                        exit_on_fail : TRUE);

  start_tag = '<' + check_list[check] + '>';
  end_tag = '</' + check_list[check] + '>';

  if (
    '<?xml version="1.0" encoding="UTF-8"?>' >< res[2] &&
    '<response>' ><  res[2] && '</response>' >< res[2] &&
    start_tag >< res[2] && end_tag >< res[2]
  )
  {
    # we need to sanitize output for everything except information page
    if ('information' >!< check)
    {
      item = eregmatch(pattern: start_tag + "([^<]+)",
                       string: res[2]);
      if (!isnull(item) && !isnull(item[1]))
      {
        tmp = item[1];
        if (strlen(tmp) <= 2)
          sanitized = crap(data:'*', length:6);
        else
          sanitized = tmp[0] + crap(data:'*', length:6) + tmp[strlen(tmp)-1];

        report += '\n  URL : ' + build_url(port:port, qs:check) +
                  '\n  ' + check_list[check] + ' : ' + sanitized + '\n';
      }
    }
    else
    {
      report += '\n  URL : ' + build_url(port:port, qs:check) +
                '\n  Information XML Contents :\n\n' + chomp(res[2]) + '\n';
    }
  }
}

if (report != '')
{
  if (report_verbosity > 0) security_warning(port:port, extra:report);
  else security_warning(port);
}
else audit(AUDIT_LISTEN_NOT_VULN, "web server", port);

Seebug

  • bulletinFamilyexploit
    descriptionBugtraq ID:66017 CVE ID:CVE-2013-6031 Huawei E355是一款家用SOHO路由器设备。 Huawei E355存在信息泄漏和跨站请求伪造漏洞,通过直接访问/api脚本,攻击者可利用漏洞获取敏感信息。此外构建恶意URI,诱使用户解析,可以目标用户上下文执行恶意操作。 0 Huawei E355 目前没有详细解决方案提供: http://www.huawei.com/
    idSSV:61728
    last seen2017-11-19
    modified2014-03-11
    published2014-03-11
    reporterRoot
    sourcehttps://www.seebug.org/vuldb/ssvid-61728
    titleHuawei E355信息泄漏和跨站请求伪造漏洞
  • bulletinFamilyexploit
    descriptionCVE ID:CVE-2013-6031 Huawei E355是一款被称为WiFi猫的设备。 Huawei E355应用程序不正确限制对某些API函数的访问,允许攻击者利用漏洞绕过安全限制获取受限信息。 0 Huawei E355 21.157.37.01.910 目前没有详细解决方案提供: http://www.huawei.com
    idSSV:61929
    last seen2017-11-19
    modified2014-03-26
    published2014-03-26
    reporterRoot
    titleHuawei E355 API验证绕过漏洞