Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398) - Nessus
High Plugin ID: 133148This page contains detailed information about the Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398) Nessus plugin including available exploits and PoCs found on GitHub, in Metasploit or Exploit-DB for verifying of this vulnerability.
Plugin Overview
ID: 133148
Name: Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398)
Filename: spring_CVE-2020-5398.nasl
Vulnerability Published: 2020-01-16
This Plugin Published: 2020-01-22
Last Modification Time: 2022-04-11
Plugin Version: 1.5
Plugin Type: local
Plugin Family: Misc.
Dependencies:
spring_jar_detection.nbin
Vulnerability Information
Severity: High
Vulnerability Published: 2020-01-16
Patch Published: 2020-01-16
CVE [?]: CVE-2020-5398
CPE [?]: cpe:/a:pivotal_software:spring_framework
Synopsis
The remote host contains a web application framework library that is affected by a reflected file download vulnerability.
Description
The remote host contains a Spring Framework library version that is 5.0.x prior to 5.0.16 or 5.1.x prior to 5.1.13 or 5.2.x prior to 5.2.3. It is, therefore, affected by a reflected file download vulnerability. An attacker can exploit this tricking user to click on a URL for trusted domain. Upon clicking on the malicious link, the victim will be presented with a download which appears to have originated from a trusted domain. Once downloaded, the malicious payload can execute arbitrary code and potentially completely take-over a system.
Solution
Upgrade to Spring Framework version 5.0.16 or 5.1.13 or 5.2.3 or later.
Public Exploits
Target Network Port(s): N/A
Target Asset(s): N/A
Exploit Available: True (GitHub)
Exploit Ease: Exploits (PoCs) are available
Here's the list of publicly known exploits and PoCs for verifying the Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398) vulnerability:
- GitHub: https://github.com/AlAIAL90/CVE-2020-5398
[CVE-2020-5398: PoC for exploiting CVE-2020-5398 : In Spring Framework, versions 5.2.x prior to ...] - GitHub: https://github.com/Mr-xn/Penetration_Testing_POC
[CVE-2020-5398] - GitHub: https://github.com/motikan2010/CVE-2020-5398
[CVE-2020-5398: 💣 CVE-2020-5398 - RFD(Reflected File Download) Attack for Spring MVC]
Before running any exploit against any system, make sure you are authorized by the owner of the target system(s) to perform such activity. In any other case, this would be considered as an illegal activity.
WARNING: Beware of using unverified exploits from sources such as GitHub or Exploit-DB. These exploits and PoCs could contain malware. For more information, see how to use exploits safely.
Risk Information
CVSS Score Source [?]: CVE-2020-5398
CVSS V2 Vector: AV:N/AC:H/Au:N/C:C/I:C/A:C/E:U/RL:OF/RC:C
CVSS Base Score: | 7.6 (High) |
Impact Subscore: | 10.0 |
Exploitability Subscore: | 4.9 |
CVSS Temporal Score: | 5.6 (Medium) |
CVSS Environmental Score: | NA (None) |
Modified Impact Subscore: | NA |
Overall CVSS Score: | 5.6 (Medium) |
CVSS Base Score: | 7.5 (High) |
Impact Subscore: | 5.9 |
Exploitability Subscore: | 1.6 |
CVSS Temporal Score: | 6.5 (Medium) |
CVSS Environmental Score: | NA (None) |
Modified Impact Subscore: | NA |
Overall CVSS Score: | 6.5 (Medium) |
Go back to menu.
Plugin Source
This is the spring_CVE-2020-5398.nasl nessus plugin source code. This script is Copyright (C) 2020-2022 and is owned by Tenable, Inc. or an Affiliate thereof.
#%NASL_MIN_LEVEL 70300
#
# (C) Tenable Network Security, Inc.
#
include('deprecated_nasl_level.inc');
include('compat.inc');
if (description)
{
script_id(133148);
script_version("1.5");
script_set_attribute(attribute:"plugin_modification_date", value:"2022/04/11");
script_cve_id("CVE-2020-5398");
script_name(english:"Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398)");
script_set_attribute(attribute:"synopsis", value:
"The remote host contains a web application framework library that is
affected by a reflected file download vulnerability.");
script_set_attribute(attribute:"description", value:
"The remote host contains a Spring Framework library version that is 5.0.x prior to 5.0.16 or 5.1.x prior to 5.1.13 or
5.2.x prior to 5.2.3. It is, therefore, affected by a reflected file download vulnerability. An attacker can exploit
this tricking user to click on a URL for trusted domain. Upon clicking on the malicious link, the victim will be
presented with a download which appears to have originated from a trusted domain. Once downloaded, the malicious
payload can execute arbitrary code and potentially completely take-over a system.");
script_set_attribute(attribute:"see_also", value:"https://pivotal.io/security/cve-2020-5398");
script_set_attribute(attribute:"solution", value:
"Upgrade to Spring Framework version 5.0.16 or 5.1.13 or 5.2.3 or later.");
script_set_attribute(attribute:"agent", value:"all");
script_set_cvss_base_vector("CVSS2#AV:N/AC:H/Au:N/C:C/I:C/A:C");
script_set_cvss_temporal_vector("CVSS2#E:U/RL:OF/RC:C");
script_set_cvss3_base_vector("CVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H");
script_set_cvss3_temporal_vector("CVSS:3.0/E:U/RL:O/RC:C");
script_set_attribute(attribute:"cvss_score_source", value:"CVE-2020-5398");
script_set_attribute(attribute:"exploitability_ease", value:"No known exploits are available");
script_set_attribute(attribute:"vuln_publication_date", value:"2020/01/16");
script_set_attribute(attribute:"patch_publication_date", value:"2020/01/16");
script_set_attribute(attribute:"plugin_publication_date", value:"2020/01/22");
script_set_attribute(attribute:"plugin_type", value:"local");
script_set_attribute(attribute:"cpe", value:"cpe:/a:pivotal_software:spring_framework");
script_set_attribute(attribute:"thorough_tests", value:"true");
script_end_attributes();
script_category(ACT_GATHER_INFO);
script_family(english:"Misc.");
script_copyright(english:"This script is Copyright (C) 2020-2022 and is owned by Tenable, Inc. or an Affiliate thereof.");
script_dependencies("spring_jar_detection.nbin");
exit(0);
}
include('vcf.inc');
app_info = vcf::combined_get_app_info(app:'Spring Framework');
constraints = [
{ 'min_version':'5.0', 'fixed_version':'5.0.16' },
{ 'min_version':'5.1', 'fixed_version':'5.1.13' },
{ 'min_version':'5.2', 'fixed_version':'5.2.3' }
];
vcf::check_version_and_report(app_info:app_info, constraints:constraints, severity:SECURITY_HOLE);
The latest version of this script can be found in these locations depending on your platform:
- Linux / Unix:
/opt/nessus/lib/nessus/plugins/spring_CVE-2020-5398.nasl
- Windows:
C:\ProgramData\Tenable\Nessus\nessus\plugins\spring_CVE-2020-5398.nasl
- Mac OS X:
/Library/Nessus/run/lib/nessus/plugins/spring_CVE-2020-5398.nasl
Go back to menu.
How to Run
Here is how to run the Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398) as a standalone plugin via the Nessus web user interface (https://localhost:8834/):
- Click to start a New Scan.
- Select Advanced Scan.
- Navigate to the Plugins tab.
- On the top right corner click to Disable All plugins.
- On the left side table select Misc. plugin family.
- On the right side table select Spring Framework 5.0.x < 5.0.16 / 5.1.x < 5.1.13 / 5.2.x < 5.2.3 Spring Framework Reflected File Download Vulnerability. (CVE-2020-5398) plugin ID 133148.
- Specify the target on the Settings tab and click to Save the scan.
- Run the scan.
Here are a few examples of how to run the plugin in the command line. Note that the examples below demonstrate the usage on the Linux / Unix platform.
Basic usage:
/opt/nessus/bin/nasl spring_CVE-2020-5398.nasl -t <IP/HOST>
Run the plugin with audit trail message on the console:
/opt/nessus/bin/nasl -a spring_CVE-2020-5398.nasl -t <IP/HOST>
Run the plugin with trace script execution written to the console (useful for debugging):
/opt/nessus/bin/nasl -T - spring_CVE-2020-5398.nasl -t <IP/HOST>
Run the plugin with using a state file for the target and updating it (useful for running multiple plugins on the target):
/opt/nessus/bin/nasl -K /tmp/state spring_CVE-2020-5398.nasl -t <IP/HOST>
Go back to menu.
References
See also:
- https://www.tenable.com/plugins/nessus/133148
- https://pivotal.io/security/cve-2020-5398
- https://vulners.com/nessus/SPRING_CVE-2020-5398.NASL
- 138569 - MySQL Enterprise Monitor 4.0.x < 4.0.13.5350 / 8.0.x < 8.0.21.1243 (Jul 2020 CPU)
- 138592 - Oracle WebLogic Server Multiple Vulnerabilities (Jul 2020 CPU)
- 129500 - Spring Framework 4.3.x < 4.3.16 / 5.0.x < 5.0.5 Remote Code Execution with spring-messaging (CVE-2018-1270)
- 159730 - VMware Spring Cloud Function < 3.1.7 / 3.2.x < 3.2.3 SPEL Expression Injection (local check)
- 159374 - Spring Framework < 5.2.20 / 5.3.x < 5.3.18 Remote Code Execution (CVE-2022-22965)
- 160544 - Spring Data Commons < 1.13.11 / 2.x < 2.0.6 RCE
- 159375 - Spring Cloud Function SPEL Expression Injection (direct check)
- 119846 - Spring Framework 4.3.x < 4.3.15 / 5.0.x < 5.0.5 Windows Directory Traversal Vulnerability (CVE-2018-1271)
- 159542 - Spring Framework Spring4Shell (CVE-2022-22965)
- 126653 - Debian DLA-1853-1 : libspring-java security update
- 149004 - Debian DLA-2635-1 : libspring-java security update
- 73255 - Debian DSA-2890-1 : libspring-java - security update
- 129973 - Oracle GoldenGate for Big Data 12.3.1.1.x < 12.3.1.1.6 / 12.3.2.1.x < 12.3.2.1.5 Spring Framework DoS (Oct 2019 CPU)
Version
This page has been produced using Nessus Professional 10.1.2 (#68) LINUX, Plugin set 202205072148.
Plugin file spring_CVE-2020-5398.nasl version 1.5. For more plugins, visit the Nessus Plugin Library.
Go back to menu.