According to its banner, the remote web server is running a version of OpenSSL 1.0.1 earlier than 1.0.1a. As such, the OpenSSL library itself is reportedly affected by a memory corruption vulnerability via an integer truncation error in the function ‘asn1_d2i_read_bio’ when reading ASN.1 DER format data.
Applications using the ‘BIO’ or ‘FILE’ based functions (i.e., ‘d2i_bio’ or 'd2i_fp’ functions) are affected by this issue. Also affected are ‘S/MIME’ or ‘CMS’ applications using ‘SMIME_read_PKCS7’ or ‘SMIME_read_CMS’ parsers. The OpenSSL command line utility is affected if used to handle untrusted DER formatted data.
Note that the SSL/TLS code of OpenSSL is not affected. Also not affected are applications using memory-based ASN.1 functions (e.g., ‘d2i_X509’, ‘d2i_PKCS12’, etc.) nor are applications using only PEM functions.
#
# (C) Tenable Network Security, Inc.
#
include("compat.inc");
if (description)
{
script_id(58801);
script_version("1.15");
script_set_attribute(attribute:"plugin_modification_date", value:"2023/08/21");
script_cve_id("CVE-2012-2110");
script_bugtraq_id(53158);
script_xref(name:"EDB-ID", value:"18756");
script_name(english:"OpenSSL 1.0.1 < 1.0.1a ASN.1 asn1_d2i_read_bio Memory Corruption");
script_summary(english:"Does a banner check.");
script_set_attribute(
attribute:"synopsis",
value:"The remote host may be affected by a memory corruption vulnerability."
);
script_set_attribute(
attribute:"description",
value:
"According to its banner, the remote web server is running a version
of OpenSSL 1.0.1 earlier than 1.0.1a. As such, the OpenSSL library
itself is reportedly affected by a memory corruption vulnerability via
an integer truncation error in the function 'asn1_d2i_read_bio' when
reading ASN.1 DER format data.
Applications using the 'BIO' or 'FILE' based functions (i.e.,
'd2i_*_bio' or 'd2i_*_fp' functions) are affected by this issue. Also
affected are 'S/MIME' or 'CMS' applications using 'SMIME_read_PKCS7'
or 'SMIME_read_CMS' parsers. The OpenSSL command line utility is
affected if used to handle untrusted DER formatted data.
Note that the SSL/TLS code of OpenSSL is not affected. Also not
affected are applications using memory-based ASN.1 functions (e.g.,
'd2i_X509', 'd2i_PKCS12', etc.) nor are applications using only PEM
functions."
);
script_set_attribute(attribute:"see_also", value:"https://www.openssl.org/news/secadv/20120419.txt");
script_set_attribute(attribute:"see_also", value:"https://www.openssl.org/news/changelog.html");
script_set_attribute(attribute:"see_also", value:"http://seclists.org/fulldisclosure/2012/Apr/210");
script_set_attribute(attribute:"solution", value:"Upgrade to OpenSSL 1.0.1a or later.");
script_set_cvss_base_vector("CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P");
script_set_cvss_temporal_vector("CVSS2#E:POC/RL:OF/RC:C");
script_set_attribute(attribute:"cvss_score_source", value:"CVE-2012-2110");
script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
script_set_attribute(attribute:"exploit_available", value:"true");
script_set_attribute(attribute:"vuln_publication_date", value:"2012/04/19");
script_set_attribute(attribute:"patch_publication_date", value:"2012/04/19");
script_set_attribute(attribute:"plugin_publication_date", value:"2012/04/19");
script_set_attribute(attribute:"plugin_type", value:"combined");
script_set_attribute(attribute:"cpe", value:"cpe:/a:openssl:openssl");
script_set_attribute(attribute:"agent", value:"all");
script_end_attributes();
script_category(ACT_GATHER_INFO);
script_family(english:"Web Servers");
script_copyright(english:"This script is Copyright (C) 2012-2023 Tenable Network Security, Inc.");
script_dependencies("openssl_version.nasl", "openssl_nix_installed.nbin", "openssl_win_installed.nbin");
script_require_keys("installed_sw/OpenSSL");
exit(0);
}
include('vcf.inc');
include('vcf_extras_openssl.inc');
var app_info = vcf::combined_get_app_info(app:'OpenSSL');
vcf::check_all_backporting(app_info:app_info);
var constraints = [{ 'min_version' : "1.0.1", 'fixed_version' : '1.0.1a'}];
vcf::openssl::check_version_and_report(app_info:app_info, constraints:constraints, severity:SECURITY_HOLE);