#%NASL_MIN_LEVEL 80900
##
# (C) Tenable, Inc.
##
include('compat.inc');
if (description)
{
script_id(248840);
script_version("1.7");
script_set_attribute(attribute:"plugin_modification_date", value:"2025/12/01");
script_cve_id("CVE-2024-5535");
script_name(english:"Linux Distros Unpatched Vulnerability : CVE-2024-5535");
script_set_attribute(attribute:"synopsis", value:
"The Linux/Unix host has one or more packages installed with a vulnerability that the vendor indicates will not be
patched.");
script_set_attribute(attribute:"description", value:
"The Linux/Unix host has one or more packages installed that are impacted by a vulnerability without a vendor supplied
patch available.
- Issue summary: Calling the OpenSSL API function SSL_select_next_proto with an empty supported client
protocols buffer may cause a crash or memory contents to be sent to the peer. Impact summary: A buffer
overread can have a range of potential consequences such as unexpected application beahviour or a crash.
In particular this issue could result in up to 255 bytes of arbitrary private data from memory being sent
to the peer leading to a loss of confidentiality. However, only applications that directly call the
SSL_select_next_proto function with a 0 length list of supported client protocols are affected by this
issue. This would normally never be a valid scenario and is typically not under attacker control but may
occur by accident in the case of a configuration or programming error in the calling application. The
OpenSSL API function SSL_select_next_proto is typically used by TLS applications that support ALPN
(Application Layer Protocol Negotiation) or NPN (Next Protocol Negotiation). NPN is older, was never
standardised and is deprecated in favour of ALPN. We believe that ALPN is significantly more widely
deployed than NPN. The SSL_select_next_proto function accepts a list of protocols from the server and a
list of protocols from the client and returns the first protocol that appears in the server list that also
appears in the client list. In the case of no overlap between the two lists it returns the first item in
the client list. In either case it will signal whether an overlap between the two lists was found. In the
case where SSL_select_next_proto is called with a zero length client list it fails to notice this
condition and returns the memory immediately following the client list pointer (and reports that there was
no overlap in the lists). This function is typically called from a server side application callback for
ALPN or a client side application callback for NPN. In the case of ALPN the list of protocols supplied by
the client is guaranteed by libssl to never be zero in length. The list of server protocols comes from the
application and should never normally be expected to be of zero length. In this case if the
SSL_select_next_proto function has been called as expected (with the list supplied by the client passed in
the client/client_len parameters), then the application will not be vulnerable to this issue. If the
application has accidentally been configured with a zero length server list, and has accidentally passed
that zero length server list in the client/client_len parameters, and has additionally failed to correctly
handle a no overlap response (which would normally result in a handshake failure in ALPN) then it will
be vulnerable to this problem. In the case of NPN, the protocol permits the client to opportunistically
select a protocol when there is no overlap. OpenSSL returns the first client protocol in the no overlap
case in support of this. The list of client protocols comes from the application and should never normally
be expected to be of zero length. However if the SSL_select_next_proto function is accidentally called
with a client_len of 0 then an invalid memory pointer will be returned instead. If the application uses
this output as the opportunistic protocol then the loss of confidentiality will occur. This issue has been
assessed as Low severity because applications are most likely to be vulnerable if they are using NPN
instead of ALPN - but NPN is not widely used. It also requires an application configuration or programming
error. Finally, this issue would not typically be under attacker control making active exploitation
unlikely. The FIPS modules in 3.3, 3.2, 3.1 and 3.0 are not affected by this issue. Due to the low
severity of this issue we are not issuing new releases of OpenSSL at this time. The fix will be included
in the next releases when they become available. (CVE-2024-5535)
Note that Nessus relies on the presence of the package as reported by the vendor.");
script_set_attribute(attribute:"see_also", value:"https://access.redhat.com/security/cve/cve-2024-5535");
script_set_attribute(attribute:"see_also", value:"https://ubuntu.com/security/CVE-2024-5535");
script_set_attribute(attribute:"solution", value:
"There is no known solution at this time.");
script_set_attribute(attribute:"agent", value:"unix");
script_set_cvss_base_vector("CVSS2#AV:N/AC:M/Au:N/C:N/I:N/A:P");
script_set_cvss_temporal_vector("CVSS2#E:POC/RL:U/RC:C");
script_set_cvss3_base_vector("CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H");
script_set_cvss3_temporal_vector("CVSS:3.0/E:P/RL:U/RC:C");
script_set_attribute(attribute:"cvss_score_source", value:"CVE-2024-5535");
script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
script_set_attribute(attribute:"exploit_available", value:"true");
script_set_attribute(attribute:"vendor_unpatched", value:"true");
script_set_attribute(attribute:"vuln_publication_date", value:"2023/12/12");
script_set_attribute(attribute:"plugin_publication_date", value:"2025/08/12");
script_set_attribute(attribute:"plugin_type", value:"local");
script_set_attribute(attribute:"cpe", value:"cpe:/o:canonical:ubuntu_linux:14.04:-:lts");
script_set_attribute(attribute:"cpe", value:"cpe:/o:canonical:ubuntu_linux:16.04:-:lts");
script_set_attribute(attribute:"cpe", value:"cpe:/o:canonical:ubuntu_linux:18.04:-:lts");
script_set_attribute(attribute:"cpe", value:"cpe:/o:canonical:ubuntu_linux:20.04:-:lts");
script_set_attribute(attribute:"cpe", value:"cpe:/o:canonical:ubuntu_linux:22.04:-:lts");
script_set_attribute(attribute:"cpe", value:"cpe:/o:centos:centos:7");
script_set_attribute(attribute:"cpe", value:"cpe:/o:centos:centos:8");
script_set_attribute(attribute:"cpe", value:"cpe:/o:redhat:enterprise_linux:10");
script_set_attribute(attribute:"cpe", value:"cpe:/o:redhat:enterprise_linux:7");
script_set_attribute(attribute:"cpe", value:"cpe:/o:redhat:enterprise_linux:8");
script_set_attribute(attribute:"cpe", value:"cpe:/o:redhat:enterprise_linux:9");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:canonical:ubuntu_linux:edk2");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:canonical:ubuntu_linux:nodejs");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:canonical:ubuntu_linux:openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:canonical:ubuntu_linux:openssl1.0");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:AAVMF");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:OVMF");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:compat-openssl10");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:compat-openssl11");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:edk2");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:edk2-aarch64");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:edk2-ovmf");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:edk2-tools");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:edk2-tools-doc");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:mingw32-openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:mingw64-openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:openssl-devel");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:openssl-libs");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:openssl-perl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:openssl-static");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:centos:centos:ovmf");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:AAVMF");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:OVMF");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:compat-openssl10");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:compat-openssl11");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:edk2");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:edk2-aarch64");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:edk2-ovmf");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:edk2-tools");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:edk2-tools-doc");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:mingw32-openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:mingw64-openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:openssl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:openssl-devel");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:openssl-libs");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:openssl-perl");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:openssl-static");
script_set_attribute(attribute:"cpe", value:"p-cpe:/a:redhat:enterprise_linux:ovmf");
script_set_attribute(attribute:"generated_plugin", value:"current");
script_end_attributes();
script_category(ACT_GATHER_INFO);
script_family(english:"Misc.");
script_copyright(english:"This script is Copyright (C) 2025 and is owned by Tenable, Inc. or an Affiliate thereof.");
script_dependencies("ssh_get_info2.nasl", "set_linux_os_id.nasl");
script_require_keys("Host/cpu", "Host/local_checks_enabled", "global_settings/vendor_unpatched", "Host/OS/identifier");
script_require_ports("Host/OS/CentOS Linux-7", "Host/OS/CentOS Linux-8", "Host/OS/Red Hat Enterprise Linux-10", "Host/OS/Red Hat Enterprise Linux-7", "Host/OS/Red Hat Enterprise Linux-8", "Host/OS/Red Hat Enterprise Linux-9", "Host/OS/Ubuntu Linux-14.04", "Host/OS/Ubuntu Linux-16.04", "Host/OS/Ubuntu Linux-18.04", "Host/OS/Ubuntu Linux-20.04", "Host/OS/Ubuntu Linux-22.04");
exit(0);
}
if (!get_kb_item("global_settings/vendor_unpatched")) exit(0, "Unpatched Vulnerabilities Detection not active.");
if (!get_kb_item("Host/local_checks_enabled")) audit(AUDIT_LOCAL_CHECKS_NOT_ENABLED);
if (empty_or_null(get_one_kb_item("Host/CentOS/rpm-list")) && empty_or_null(get_one_kb_item("Host/Debian/dpkg-l")) && empty_or_null(get_one_kb_item("Host/RedHat/rpm-list"))) audit(AUDIT_PACKAGE_LIST_MISSING);
include('linux_unpatched.inc');
var distro_constraints_array = {
"Ubuntu Linux-14.04": {
"package_manager": "dpkg-l",
"constraints": [
{
"release": "14.04",
"pkgs": [
{"reference": "libcrypto1.0.0-udeb"},
{"reference": "libssl-dev"},
{"reference": "libssl-doc"},
{"reference": "libssl1.0.0"},
{"reference": "libssl1.0.0-dbg"},
{"reference": "libssl1.0.0-udeb"},
{"reference": "openssl"}
]
}
]
},
"Ubuntu Linux-16.04": {
"package_manager": "dpkg-l",
"constraints": [
{
"release": "16.04",
"pkgs": [
{"reference": "edk2"},
{"reference": "libcrypto1.0.0-udeb"},
{"reference": "libssl-dev"},
{"reference": "libssl-doc"},
{"reference": "libssl1.0.0"},
{"reference": "libssl1.0.0-dbg"},
{"reference": "libssl1.0.0-udeb"},
{"reference": "nodejs"},
{"reference": "openssl"}
]
}
]
},
"Ubuntu Linux-18.04": {
"package_manager": "dpkg-l",
"constraints": [
{
"release": "18.04",
"pkgs": [
{"reference": "edk2"},
{"reference": "libcrypto1.0.0-udeb"},
{"reference": "libcrypto1.1-udeb"},
{"reference": "libssl-dev"},
{"reference": "libssl-doc"},
{"reference": "libssl1.0-dev"},
{"reference": "libssl1.0.0"},
{"reference": "libssl1.0.0-udeb"},
{"reference": "libssl1.1"},
{"reference": "libssl1.1-udeb"},
{"reference": "nodejs"},
{"reference": "openssl"},
{"reference": "openssl1.0"}
]
}
]
},
"Ubuntu Linux-20.04": {
"package_manager": "dpkg-l",
"constraints": [
{
"release": "20.04",
"pkgs": [
{"reference": "ovmf"},
{"reference": "qemu-efi"},
{"reference": "qemu-efi-aarch64"},
{"reference": "qemu-efi-arm"}
]
}
]
},
"Ubuntu Linux-22.04": {
"package_manager": "dpkg-l",
"constraints": [
{
"release": "22.04",
"pkgs": [
{"reference": "nodejs"}
]
}
]
},
"Red Hat Enterprise Linux-10": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "10",
"pkgs": [
{"reference": "openssl"},
{"reference": "openssl-devel"},
{"reference": "openssl-libs"},
{"reference": "openssl-perl"}
]
}
]
},
"CentOS Linux-7": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "7",
"pkgs": [
{"reference": "AAVMF"},
{"reference": "OVMF"},
{"reference": "openssl"},
{"reference": "openssl-devel"},
{"reference": "openssl-libs"},
{"reference": "openssl-perl"},
{"reference": "openssl-static"},
{"reference": "ovmf"}
]
}
]
},
"Red Hat Enterprise Linux-7": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "7",
"pkgs": [
{"reference": "AAVMF"},
{"reference": "OVMF"},
{"reference": "openssl"},
{"reference": "openssl-devel"},
{"reference": "openssl-libs"},
{"reference": "openssl-perl"},
{"reference": "openssl-static"},
{"reference": "ovmf"}
]
}
]
},
"CentOS Linux-8": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "8",
"pkgs": [
{"reference": "compat-openssl10"},
{"reference": "edk2"},
{"reference": "edk2-aarch64"},
{"reference": "edk2-ovmf"},
{"reference": "mingw32-openssl"},
{"reference": "mingw64-openssl"}
]
}
]
},
"Red Hat Enterprise Linux-8": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "8",
"pkgs": [
{"reference": "compat-openssl10"},
{"reference": "edk2"},
{"reference": "edk2-aarch64"},
{"reference": "edk2-ovmf"},
{"reference": "mingw32-openssl"},
{"reference": "mingw64-openssl"}
]
}
]
},
"Red Hat Enterprise Linux-9": {
"package_manager": "rpm-list",
"constraints": [
{
"release": "9",
"pkgs": [
{"reference": "compat-openssl11"},
{"reference": "edk2"},
{"reference": "edk2-aarch64"},
{"reference": "edk2-ovmf"},
{"reference": "edk2-tools"},
{"reference": "edk2-tools-doc"}
]
}
]
}
};
var distro_constraints_values = linux_unpatched::get_distro_constraints(distro_constraints_arr:distro_constraints_array);
if (empty_or_null(distro_constraints_values)) audit(AUDIT_HOST_NOT, 'affected');
var report = linux_unpatched::check_unpatched_constraints(distro_constraints_values:distro_constraints_values);
if (!empty_or_null(report))
{
security_report_v4(
port : 0,
severity : SECURITY_WARNING,
extra : report
);
exit(0);
}
else
{
audit(AUDIT_HOST_NOT, 'affected');
}
Data
Build on a solid foundation with Vulners data
We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data
Api
Power your application with Vulners API
The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access
App
Assess and manage vulnerabilities with Vulners tools
Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation