Vulnerabilities > CVE-2013-1762 - Code Injection vulnerability in Stunnel

047910
CVSS 6.6 - MEDIUM
Attack vector
NETWORK
Attack complexity
HIGH
Privileges required
NONE
Confidentiality impact
PARTIAL
Integrity impact
PARTIAL
Availability impact
COMPLETE
network
high complexity
stunnel
CWE-94
nessus

Summary

stunnel 4.21 through 4.54, when CONNECT protocol negotiation and NTLM authentication are enabled, does not correctly perform integer conversion, which allows remote proxy servers to execute arbitrary code via a crafted request that triggers a buffer overflow.

Vulnerable Configurations

Part Description Count
Application
Stunnel
106

Common Attack Pattern Enumeration and Classification (CAPEC)

  • Leverage Executable Code in Non-Executable Files
    An attack of this type exploits a system's trust in configuration and resource files, when the executable loads the resource (such as an image file or configuration file) the attacker has modified the file to either execute malicious code directly or manipulate the target process (e.g. application server) to execute based on the malicious configuration parameters. Since systems are increasingly interrelated mashing up resources from local and remote sources the possibility of this attack occurring is high. The attack can be directed at a client system, such as causing buffer overrun through loading seemingly benign image files, as in Microsoft Security Bulletin MS04-028 where specially crafted JPEG files could cause a buffer overrun once loaded into the browser. Another example targets clients reading pdf files. In this case the attacker simply appends javascript to the end of a legitimate url for a pdf (http://www.gnucitizen.org/blog/danger-danger-danger/) http://path/to/pdf/file.pdf#whatever_name_you_want=javascript:your_code_here The client assumes that they are reading a pdf, but the attacker has modified the resource and loaded executable javascript into the client's browser process. The attack can also target server processes. The attacker edits the resource or configuration file, for example a web.xml file used to configure security permissions for a J2EE app server, adding role name "public" grants all users with the public role the ability to use the administration functionality. The server trusts its configuration file to be correct, but when they are manipulated, the attacker gains full control.
  • Manipulating User-Controlled Variables
    This attack targets user controlled variables (DEBUG=1, PHP Globals, and So Forth). An attacker can override environment variables leveraging user-supplied, untrusted query variables directly used on the application server without any data sanitization. In extreme cases, the attacker can change variables controlling the business logic of the application. For instance, in languages like PHP, a number of poorly set default configurations may allow the user to override variables.

Nessus

  • NASL familySuSE Local Security Checks
    NASL idSUSE_11_STUNNEL-130305.NASL
    descriptionThis update for stunnel fixes a buffer overflow vulnerability caused by incorrect integer conversion in the NTLM authentication of the CONNECT protocol negotiation. (CVE-2013-1762)
    last seen2020-06-05
    modified2013-04-24
    plugin id66195
    published2013-04-24
    reporterThis script is Copyright (C) 2013-2020 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/66195
    titleSuSE 11.2 Security Update : stunnel (SAT Patch Number 7449)
  • NASL familyWindows
    NASL idSTUNNEL_4_55.NASL
    descriptionThe version of stunnel installed on the remote host is a version after 4.21 and prior to 4.55. It is, therefore, affected by the following vulnerabilities : - The bundled version of OpenSSL contains an error related to CBC-mode and timing that allows an attacker to recover plaintext from encrypted communications. (CVE-2013-0169) - A buffer overflow condition exists related to NTLM authentication. Note this issue does not affect 32-bit builds.(CVE-2013-1762)
    last seen2020-06-01
    modified2020-06-02
    plugin id65690
    published2013-03-26
    reporterThis script is Copyright (C) 2013-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/65690
    titlestunnel 4.21 - 4.54 Multiple Vulnerabilities
  • NASL familyGentoo Local Security Checks
    NASL idGENTOO_GLSA-201402-08.NASL
    descriptionThe remote host is affected by the vulnerability described in GLSA-201402-08 (stunnel: Arbitrary code execution) A buffer overflow vulnerability has been discovered in stunnel. Please review the CVE identifier referenced below for details. Impact : A remote attacker could entice a user to connect to a malicious proxy server, resulting in the execution of arbitrary code within the configured chroot directory, with the privileges of the user running stunnel. Please review the references below for details. Workaround : There is no known workaround at this time.
    last seen2020-06-01
    modified2020-06-02
    plugin id72385
    published2014-02-07
    reporterThis script is Copyright (C) 2014-2018 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/72385
    titleGLSA-201402-08 : stunnel: Arbitrary code execution
  • NASL familyScientific Linux Local Security Checks
    NASL idSL_20130408_STUNNEL_ON_SL6_X.NASL
    descriptionAn integer conversion issue was found in stunnel when using Microsoft NT LAN Manager (NTLM) authentication with the HTTP CONNECT tunneling method. With this configuration, and using stunnel in SSL client mode on a 64-bit system, an attacker could possibly execute arbitrary code with the privileges of the stunnel process via a man-in-the-middle attack or by tricking a user into using a malicious proxy. (CVE-2013-1762)
    last seen2020-03-18
    modified2013-04-09
    plugin id65864
    published2013-04-09
    reporterThis script is Copyright (C) 2013-2020 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/65864
    titleScientific Linux Security Update : stunnel on SL6.x i386/x86_64 (20130408)
  • NASL familyFreeBSD Local Security Checks
    NASL idFREEBSD_PKG_C97219B6843D11E2B131000C299B62E1.NASL
    descriptionMichal Trojnara reports : 64-bit versions of stunnel with the following conditions : * NTLM authentication enabled * CONNECT protocol negotiation enabled * Configured in SSL client mode * An attacker that can either control the proxy server specified in the
    last seen2020-06-01
    modified2020-06-02
    plugin id65003
    published2013-03-05
    reporterThis script is Copyright (C) 2013-2018 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/65003
    titleFreeBSD : stunnel -- Remote Code Execution (c97219b6-843d-11e2-b131-000c299b62e1)
  • NASL familyMandriva Local Security Checks
    NASL idMANDRIVA_MDVSA-2013-130.NASL
    descriptionUpdated stunnel packages fix security vulnerability : stunnel 4.21 through 4.54, when CONNECT protocol negotiation and NTLM authentication are enabled, does not correctly perform integer conversion, which allows remote proxy servers to execute arbitrary code via a crafted request that triggers a buffer overflow (CVE-2013-1762). The updated packages also fixes the following : - move library subpackages back into main stunnel package - add a systemd unit file (partially fixing Bug 3951) - fix issues with stunnel.conf and stunnel.pem, with stunnel running in a chroot environment.
    last seen2020-06-01
    modified2020-06-02
    plugin id66142
    published2013-04-20
    reporterThis script is Copyright (C) 2013-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/66142
    titleMandriva Linux Security Advisory : stunnel (MDVSA-2013:130)
  • NASL familyRed Hat Local Security Checks
    NASL idREDHAT-RHSA-2013-0714.NASL
    descriptionAn updated stunnel package that fixes one security issue is now available for Red Hat Enterprise Linux 6. The Red Hat Security Response Team has rated this update as having moderate security impact. A Common Vulnerability Scoring System (CVSS) base score, which gives a detailed severity rating, is available from the CVE link in the References section. stunnel is a socket wrapper which can provide SSL (Secure Sockets Layer) support to ordinary applications. For example, it can be used in conjunction with imapd to create an SSL-secure IMAP server. An integer conversion issue was found in stunnel when using Microsoft NT LAN Manager (NTLM) authentication with the HTTP CONNECT tunneling method. With this configuration, and using stunnel in SSL client mode on a 64-bit system, an attacker could possibly execute arbitrary code with the privileges of the stunnel process via a man-in-the-middle attack or by tricking a user into using a malicious proxy. (CVE-2013-1762) All stunnel users should upgrade to this updated package, which contains a backported patch to correct this issue.
    last seen2020-06-01
    modified2020-06-02
    plugin id65863
    published2013-04-09
    reporterThis script is Copyright (C) 2013-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/65863
    titleRHEL 6 : stunnel (RHSA-2013:0714)
  • NASL familyCentOS Local Security Checks
    NASL idCENTOS_RHSA-2013-0714.NASL
    descriptionAn updated stunnel package that fixes one security issue is now available for Red Hat Enterprise Linux 6. The Red Hat Security Response Team has rated this update as having moderate security impact. A Common Vulnerability Scoring System (CVSS) base score, which gives a detailed severity rating, is available from the CVE link in the References section. stunnel is a socket wrapper which can provide SSL (Secure Sockets Layer) support to ordinary applications. For example, it can be used in conjunction with imapd to create an SSL-secure IMAP server. An integer conversion issue was found in stunnel when using Microsoft NT LAN Manager (NTLM) authentication with the HTTP CONNECT tunneling method. With this configuration, and using stunnel in SSL client mode on a 64-bit system, an attacker could possibly execute arbitrary code with the privileges of the stunnel process via a man-in-the-middle attack or by tricking a user into using a malicious proxy. (CVE-2013-1762) All stunnel users should upgrade to this updated package, which contains a backported patch to correct this issue.
    last seen2020-06-01
    modified2020-06-02
    plugin id65903
    published2013-04-10
    reporterThis script is Copyright (C) 2013-2020 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/65903
    titleCentOS 6 : stunnel (CESA-2013:0714)
  • NASL familyDebian Local Security Checks
    NASL idDEBIAN_DSA-2664.NASL
    descriptionStunnel, a program designed to work as an universal SSL tunnel for network daemons, is prone to a buffer overflow vulnerability when using the Microsoft NT LAN Manager (NTLM) authentication (
    last seen2020-03-17
    modified2013-05-03
    plugin id66296
    published2013-05-03
    reporterThis script is Copyright (C) 2013-2020 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/66296
    titleDebian DSA-2664-1 : stunnel4 - buffer overflow
  • NASL familyOracle Linux Local Security Checks
    NASL idORACLELINUX_ELSA-2013-0714.NASL
    descriptionFrom Red Hat Security Advisory 2013:0714 : An updated stunnel package that fixes one security issue is now available for Red Hat Enterprise Linux 6. The Red Hat Security Response Team has rated this update as having moderate security impact. A Common Vulnerability Scoring System (CVSS) base score, which gives a detailed severity rating, is available from the CVE link in the References section. stunnel is a socket wrapper which can provide SSL (Secure Sockets Layer) support to ordinary applications. For example, it can be used in conjunction with imapd to create an SSL-secure IMAP server. An integer conversion issue was found in stunnel when using Microsoft NT LAN Manager (NTLM) authentication with the HTTP CONNECT tunneling method. With this configuration, and using stunnel in SSL client mode on a 64-bit system, an attacker could possibly execute arbitrary code with the privileges of the stunnel process via a man-in-the-middle attack or by tricking a user into using a malicious proxy. (CVE-2013-1762) All stunnel users should upgrade to this updated package, which contains a backported patch to correct this issue.
    last seen2020-06-01
    modified2020-06-02
    plugin id68803
    published2013-07-12
    reporterThis script is Copyright (C) 2013-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/68803
    titleOracle Linux 6 : stunnel (ELSA-2013-0714)

Redhat

advisories
bugzilla
id917839
titleCVE-2013-1762 Stunnel: buffer overflow vulnerability due to incorrect integer conversion in the NTLM authentication of the CONNECT protocol negotiation
oval
OR
  • commentRed Hat Enterprise Linux must be installed
    ovaloval:com.redhat.rhba:tst:20070304026
  • AND
    • commentRed Hat Enterprise Linux 6 is installed
      ovaloval:com.redhat.rhba:tst:20111656003
    • commentstunnel is earlier than 0:4.29-3.el6_4
      ovaloval:com.redhat.rhsa:tst:20130714001
    • commentstunnel is signed with Red Hat redhatrelease2 key
      ovaloval:com.redhat.rhsa:tst:20130714002
rhsa
idRHSA-2013:0714
released2013-04-08
severityModerate
titleRHSA-2013:0714: stunnel security update (Moderate)
rpms
  • stunnel-0:4.29-3.el6_4
  • stunnel-debuginfo-0:4.29-3.el6_4