Vulnerabilities > CVE-2018-6003 - Uncontrolled Recursion vulnerability in multiple products
Attack vector
NETWORK Attack complexity
LOW Privileges required
NONE Confidentiality impact
NONE Integrity impact
NONE Availability impact
HIGH Summary
An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.
Vulnerable Configurations
Common Weakness Enumeration (CWE)
Common Attack Pattern Enumeration and Classification (CAPEC)
- XML Nested Payloads Applications often need to transform data in and out of the XML format by using an XML parser. It may be possible for an attacker to inject data that may have an adverse effect on the XML parser when it is being processed. By nesting XML data and causing this data to be continuously self-referential, an attacker can cause the XML parser to consume more resources while processing, causing excessive memory consumption and CPU utilization. An attacker's goal is to leverage parser failure to his or her advantage. In most cases this type of an attack will result in a denial of service due to an application becoming unstable, freezing, or crash. However it may be possible to cause a crash resulting in arbitrary code execution, leading to a jump from the data plane to the control plane [R.230.1].
- XML Oversized Payloads Applications often need to transform data in and out of the XML format by using an XML parser. It may be possible for an attacker to inject data that may have an adverse effect on the XML parser when it is being processed. By supplying oversized payloads in input vectors that will be processed by the XML parser, an attacker can cause the XML parser to consume more resources while processing, causing excessive memory consumption and CPU utilization, and potentially cause execution of arbitrary code. An attacker's goal is to leverage parser failure to his or her advantage. In many cases this type of an attack will result in a denial of service due to an application becoming unstable, freezing, or crash. However it is possible to cause a crash resulting in arbitrary code execution, leading to a jump from the data plane to the control plane [R.231.1].
- Violating Implicit Assumptions Regarding XML Content (aka XML Denial of Service (XDoS)) XML Denial of Service (XDoS) can be applied to any technology that utilizes XML data. This is, of course, most distributed systems technology including Java, .Net, databases, and so on. XDoS is most closely associated with web services, SOAP, and Rest, because remote service requesters can post malicious XML payloads to the service provider designed to exhaust the service provider's memory, CPU, and/or disk space. The main weakness in XDoS is that the service provider generally must inspect, parse, and validate the XML messages to determine routing, workflow, security considerations, and so on. It is exactly these inspection, parsing, and validation routines that XDoS targets. There are three primary attack vectors that XDoS can navigate Target CPU through recursion: attacker creates a recursive payload and sends to service provider Target memory through jumbo payloads: service provider uses DOM to parse XML. DOM creates in memory representation of XML document, but when document is very large (for example, north of 1 Gb) service provider host may exhaust memory trying to build memory objects. XML Ping of death: attack service provider with numerous small files that clog the system. All of the above attacks exploit the loosely coupled nature of web services, where the service provider has little to no control over the service requester and any messages the service requester sends.
- XML Parser Attack Applications often need to transform data in and out of the XML format by using an XML parser. It may be possible for an attacker to inject data that may have an adverse effect on the XML parser when it is being processed. These adverse effects may include the parser crashing, consuming too much of a resource, executing too slowly, executing code supplied by an attacker, allowing usage of unintended system functionality, etc. An attacker's goal is to leverage parser failure to his or her advantage. In some cases it may be possible to jump from the data plane to the control plane via bad data being passed to an XML parser. [R.99.1]
Nessus
NASL family SuSE Local Security Checks NASL id OPENSUSE-2018-112.NASL description This update for libtasn1 fixes one issue. This security issue was fixed : - CVE-2018-6003: Prevent a stack exhaustion in _asn1_decode_simple_ber (lib/decoding.c) when decoding BER encoded structure allowed for DoS (bsc#1076832). This update was imported from the SUSE:SLE-12-SP3:Update update project. last seen 2020-06-05 modified 2018-02-01 plugin id 106544 published 2018-02-01 reporter This script is Copyright (C) 2018-2020 Tenable Network Security, Inc. source https://www.tenable.com/plugins/nessus/106544 title openSUSE Security Update : libtasn1 (openSUSE-2018-112) code #%NASL_MIN_LEVEL 80502 # # (C) Tenable Network Security, Inc. # # The descriptive text and package checks in this plugin were # extracted from openSUSE Security Update openSUSE-2018-112. # # The text description of this plugin is (C) SUSE LLC. # include("compat.inc"); if (description) { script_id(106544); script_version("3.3"); script_set_attribute(attribute:"plugin_modification_date", value:"2020/06/04"); script_cve_id("CVE-2018-6003"); script_name(english:"openSUSE Security Update : libtasn1 (openSUSE-2018-112)"); script_summary(english:"Check for the openSUSE-2018-112 patch"); script_set_attribute( attribute:"synopsis", value:"The remote openSUSE host is missing a security update." ); script_set_attribute( attribute:"description", value: "This update for libtasn1 fixes one issue. This security issue was fixed : - CVE-2018-6003: Prevent a stack exhaustion in _asn1_decode_simple_ber (lib/decoding.c) when decoding BER encoded structure allowed for DoS (bsc#1076832). This update was imported from the SUSE:SLE-12-SP3:Update update project." ); script_set_attribute( attribute:"see_also", value:"https://bugzilla.opensuse.org/show_bug.cgi?id=1076832" ); script_set_attribute( attribute:"solution", value:"Update the affected libtasn1 packages." ); script_set_cvss_base_vector("CVSS2#AV:N/AC:L/Au:N/C:N/I:N/A:P"); script_set_cvss3_base_vector("CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"); script_set_attribute(attribute:"plugin_type", value:"local"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-6"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-6-32bit"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-6-debuginfo"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-6-debuginfo-32bit"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-debuginfo"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-debugsource"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-devel"); script_set_attribute(attribute:"cpe", value:"p-cpe:/a:novell:opensuse:libtasn1-devel-32bit"); script_set_attribute(attribute:"cpe", value:"cpe:/o:novell:opensuse:42.3"); script_set_attribute(attribute:"patch_publication_date", value:"2018/01/31"); script_set_attribute(attribute:"plugin_publication_date", value:"2018/02/01"); script_end_attributes(); script_category(ACT_GATHER_INFO); script_copyright(english:"This script is Copyright (C) 2018-2020 Tenable Network Security, Inc."); script_family(english:"SuSE Local Security Checks"); script_dependencies("ssh_get_info.nasl"); script_require_keys("Host/local_checks_enabled", "Host/SuSE/release", "Host/SuSE/rpm-list", "Host/cpu"); exit(0); } include("audit.inc"); include("global_settings.inc"); include("rpm.inc"); if (!get_kb_item("Host/local_checks_enabled")) audit(AUDIT_LOCAL_CHECKS_NOT_ENABLED); release = get_kb_item("Host/SuSE/release"); if (isnull(release) || release =~ "^(SLED|SLES)") audit(AUDIT_OS_NOT, "openSUSE"); if (release !~ "^(SUSE42\.3)$") audit(AUDIT_OS_RELEASE_NOT, "openSUSE", "42.3", release); if (!get_kb_item("Host/SuSE/rpm-list")) audit(AUDIT_PACKAGE_LIST_MISSING); ourarch = get_kb_item("Host/cpu"); if (!ourarch) audit(AUDIT_UNKNOWN_ARCH); if (ourarch !~ "^(i586|i686|x86_64)$") audit(AUDIT_ARCH_NOT, "i586 / i686 / x86_64", ourarch); flag = 0; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-6-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-6-debuginfo-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-debuginfo-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-debugsource-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", reference:"libtasn1-devel-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", cpu:"x86_64", reference:"libtasn1-6-32bit-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", cpu:"x86_64", reference:"libtasn1-6-debuginfo-32bit-4.9-3.1") ) flag++; if ( rpm_check(release:"SUSE42.3", cpu:"x86_64", reference:"libtasn1-devel-32bit-4.9-3.1") ) flag++; if (flag) { if (report_verbosity > 0) security_warning(port:0, extra:rpm_report_get()); else security_warning(0); exit(0); } else { tested = pkg_tests_get(); if (tested) audit(AUDIT_PACKAGE_NOT_AFFECTED, tested); else audit(AUDIT_PACKAGE_NOT_INSTALLED, "libtasn1 / libtasn1-6-32bit / libtasn1-6 / etc"); }
NASL family PhotonOS Local Security Checks NASL id PHOTONOS_PHSA-2018-1_0-0109_LIBTASN1.NASL description An update of the libtasn1 package has been released. last seen 2020-03-17 modified 2019-02-07 plugin id 121811 published 2019-02-07 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/121811 title Photon OS 1.0: Libtasn1 PHSA-2018-1.0-0109 NASL family PhotonOS Local Security Checks NASL id PHOTONOS_PHSA-2018-1_0-0109.NASL description An update of 'libtasn1', 'dnsmasq' packages of Photon OS has been released. last seen 2019-02-21 modified 2019-02-07 plugin id 111920 published 2018-08-17 reporter Tenable source https://www.tenable.com/plugins/index.php?view=single&id=111920 title Photon OS 1.0: Dnsmasq / Libtasn1 PHSA-2018-1.0-0109 (deprecated) NASL family Fedora Local Security Checks NASL id FEDORA_2018-DA4263F065.NASL description Update to 4.13 (#1535261) Note that Tenable Network Security has extracted the preceding description block directly from the Fedora update system website. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-05 modified 2018-01-24 plugin id 106286 published 2018-01-24 reporter This script is Copyright (C) 2018-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106286 title Fedora 27 : libtasn1 (2018-da4263f065) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2019-1031.NASL description According to the version of the libtasn1 packages installed, the EulerOS installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.(CVE-2018-6003) Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-05-06 modified 2019-02-15 plugin id 122204 published 2019-02-15 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/122204 title EulerOS 2.0 SP3 : libtasn1 (EulerOS-SA-2019-1031) NASL family SuSE Local Security Checks NASL id SUSE_SU-2018-0295-1.NASL description This update for libtasn1 fixes one issue. This security issue was fixed : - CVE-2018-6003: Prevent a stack exhaustion in _asn1_decode_simple_ber (lib/decoding.c) when decoding BER encoded structure allowed for DoS (bsc#1076832). Note that Tenable Network Security has extracted the preceding description block directly from the SUSE security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-01 modified 2020-06-02 plugin id 106528 published 2018-01-31 reporter This script is Copyright (C) 2018-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106528 title SUSE SLED12 / SLES12 Security Update : libtasn1 (SUSE-SU-2018:0295-1) NASL family Ubuntu Local Security Checks NASL id UBUNTU_USN-3547-1.NASL description It was discovered that Libtasn1 incorrectly handled certain files. If a user were tricked into opening a crafted file, an attacker could possibly use this to cause a denial of service. This issue only affected Ubuntu 14.04 LTS and Ubuntu 16.04 LTS. (CVE-2017-10790) It was discovered that Libtasn1 incorrectly handled certain inputs. An attacker could possibly use this to cause Libtasn1 to hang, resulting in a denial of service. This issue only affected Ubuntu 16.04 LTS and Ubuntu 17.10. (CVE-2018-6003). Note that Tenable Network Security has extracted the preceding description block directly from the Ubuntu security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-01 modified 2020-06-02 plugin id 106371 published 2018-01-26 reporter Ubuntu Security Notice (C) 2018-2019 Canonical, Inc. / NASL script (C) 2018-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106371 title Ubuntu 14.04 LTS / 16.04 LTS / 17.10 : libtasn1-6 vulnerabilities (USN-3547-1) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2019-1212.NASL description According to the version of the libtasn1 packages installed, the EulerOS Virtualization installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.i1/4^CVE-2018-6003i1/4%0 Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-03-19 modified 2019-04-09 plugin id 123898 published 2019-04-09 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/123898 title EulerOS Virtualization 2.5.4 : libtasn1 (EulerOS-SA-2019-1212) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2018-1445.NASL description According to the version of the libtasn1 packages installed, the EulerOS installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.(CVE-2018-6003) Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-05-06 modified 2018-12-28 plugin id 119934 published 2018-12-28 reporter This script is Copyright (C) 2018-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/119934 title EulerOS 2.0 SP2 : libtasn1 (EulerOS-SA-2018-1445) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2019-1208.NASL description According to the version of the libtasn1 packages installed, the EulerOS Virtualization installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.i1/4^CVE-2018-6003i1/4%0 Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-03-19 modified 2019-04-09 plugin id 123894 published 2019-04-09 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/123894 title EulerOS Virtualization 2.5.3 : libtasn1 (EulerOS-SA-2019-1208) NASL family PhotonOS Local Security Checks NASL id PHOTONOS_PHSA-2018-2_0-0017_LIBTASN1.NASL description An update of the libtasn1 package has been released. last seen 2020-03-17 modified 2019-02-07 plugin id 121921 published 2019-02-07 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/121921 title Photon OS 2.0: Libtasn1 PHSA-2018-2.0-0017 NASL family Fedora Local Security Checks NASL id FEDORA_2018-F8C54AEEC4.NASL description Fixes security issue. Note that Tenable Network Security has extracted the preceding description block directly from the Fedora update system website. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-05 modified 2018-01-29 plugin id 106423 published 2018-01-29 reporter This script is Copyright (C) 2018-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106423 title Fedora 27 : mingw-libtasn1 (2018-f8c54aeec4) NASL family Debian Local Security Checks NASL id DEBIAN_DSA-4106.NASL description Two vulnerabilities were discovered in Libtasn1, a library to manage ASN.1 structures, allowing a remote attacker to cause a denial of service against an application using the Libtasn1 library. last seen 2020-06-01 modified 2020-06-02 plugin id 106661 published 2018-02-08 reporter This script is Copyright (C) 2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106661 title Debian DSA-4106-1 : libtasn1-6 - security update NASL family PhotonOS Local Security Checks NASL id PHOTONOS_PHSA-2018-2_0-0017.NASL description An update of {'libtasn1', 'libtiff', 'dnsmasq'} packages of Photon OS has been released. last seen 2019-02-21 modified 2019-02-07 plugin id 111287 published 2018-07-24 reporter Tenable source https://www.tenable.com/plugins/index.php?view=single&id=111287 title Photon OS 2.0 : libtasn1 / libtiff / dnsmasq (PhotonOS-PHSA-2018-2.0-0017) (deprecated) NASL family Fedora Local Security Checks NASL id FEDORA_2018-EF303DEEC6.NASL description Update to 4.13 (#1535261) Note that Tenable Network Security has extracted the preceding description block directly from the Fedora update system website. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-05 modified 2018-02-07 plugin id 106647 published 2018-02-07 reporter This script is Copyright (C) 2018-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/106647 title Fedora 26 : libtasn1 (2018-ef303deec6) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2019-1018.NASL description According to the version of the libtasn1 packages installed, the EulerOS Virtualization installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.(CVE-2018-6003) Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-03-17 modified 2019-01-22 plugin id 121278 published 2019-01-22 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/121278 title EulerOS Virtualization 2.5.2 : libtasn1 (EulerOS-SA-2019-1018) NASL family Huawei Local Security Checks NASL id EULEROS_SA-2019-1006.NASL description According to the version of the libtasn1 packages installed, the EulerOS installation on the remote host is affected by the following vulnerability : - An issue was discovered in the _asn1_decode_simple_ber function in decoding.c in GNU Libtasn1 before 4.13. Unlimited recursion in the BER decoder leads to stack exhaustion and DoS.(CVE-2018-6003) Note that Tenable Network Security has extracted the preceding description block directly from the EulerOS security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-05-06 modified 2019-01-08 plugin id 120994 published 2019-01-08 reporter This script is Copyright (C) 2019-2020 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/120994 title EulerOS 2.0 SP5 : libtasn1 (EulerOS-SA-2019-1006)
References
- https://gitlab.com/gnutls/libtasn1/commit/946565d8eb05fbf7970ea366e817581bb5a90910
- https://bugzilla.suse.com/show_bug.cgi?id=1076832
- https://bugzilla.redhat.com/show_bug.cgi?id=1535926
- http://git.savannah.nongnu.org/cgit/libtasn1.git/commit/?id=c593ae84cfcde8fea45787e53950e0ac71e9ca97
- https://www.debian.org/security/2018/dsa-4106
- https://lists.apache.org/thread.html/rf4c02775860db415b4955778a131c2795223f61cb8c6a450893651e4%40%3Cissues.bookkeeper.apache.org%3E
- https://lists.apache.org/thread.html/r58af02e294bd07f487e2c64ffc0a29b837db5600e33b6e698b9d696b%40%3Cissues.bookkeeper.apache.org%3E