PCI v3.2-6.5.8
CAPEC-252
CWE-22
HIPAA-164.306(a)
ISO27001-A.14.2.5
WASC-33
OWASP 2013-A4
OWASP 2017-A5
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N

F5 Big-IP Local File Inclusion (CVE-2020-5902)

Severity:
High
Summary

Invicti identified a Local File Inclusion vulnerability in Big-IP, which occurs when a file from the target system is injected into the attacked server page.


Invicti confirmed this issue by reading some files from the target web server.

Impact

The impact can vary, based on the exploitation and the read permission of the web server user. Depending on these factors, an attacker might carry out one or more of the following attacks:

  • Gather usernames via an "/etc/passwd" file
  • Harvest useful information from the config file, such as "/config/bigip.conf"
  • Remotely execute commands by combining this vulnerability with some other attack vectors, such as file upload vulnerability or log injection

Exploit of the vulnerability is known widely and should be addressed as soon as possible.

Remediation
  • Upgrade to a fixed software version, by following the table in the External References Section.
  • If it is not possible to upgrade at this time:
  1. Log in to the TMOS Shell (tmsh) by entering the following command: tmsh

  2. Edit the httpd properties by entering the following command
    edit/sys httpd all-properties

  3. Locate the line that starts with include none and replace it with the following:

    include '
    <LocationMatch ";">
    Redirect 404 /
    </LocationMatch>
    '
  4. Write and save the changes to the configuration file by entering the following vi commands:
    Esc
    :wq!

  5. When further prompted to Save Changes (y/n/e), enter y.

  6. Save the configuration by entering the following tmsh command:
    save /sys config

  7. To activate the mitigation, restart the httpd service by entering the following command:
    restart sys service httpd

  8. To exit tmsh, enter the following command:
    quit

  9. Ensure that the workaround is inserted in the configuration by comparing the output of the following command to the configured LocationMatch fragment that you inserted in step 3. To do so, enter the following command:
    grep -C1 'Redirect 404' /etc/httpd/conf/httpd.conf

    The output should match the following:
    <LocationMatch ";">
    Redirect 404 /
    </LocationMatch>


If you have high availability (HA) configuration, you may now perform a ConfigSync operation as documented in K14856: Performing a ConfigSync using tmsh.

Required Skills for Successful Exploitation
Actions To Take

It is recommended that you upgrade to a fixed software version to fully mitigate this vulnerability.

If it is not possible to upgrade at this time, you can use the following sections as temporary mitigations:

  • All TMUI interfaces: addresses unauthenticated attackers on all interfaces
  • Self IPs: addresses unauthenticated and authenticated attackers on self-IPs, by blocking all access
  • Management interface: addresses unauthenticated attackers on the management interface, by restricting access
Vulnerability Index

You can search and find all vulnerabilities

Select Vulnerability
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Featured resources

Blog

Strengthening enterprise application security: Invicti acquires Kondukto

Blog

Modern AppSec KPIs: Moving from scan counts to real risk reduction

Blog

Friends don’t let friends shift left: Shift smarter with DAST-first AppSec

Blog

Vibe talking: Dan Murphy on the promises, pitfalls, and insecurities of vibe coding

Blog

What lies ahead for CMS.

Blog

How to integrate CMS with other tools.

Blog

Improve user experience through CMS.

Blog

How CMS can benefit e-commerce.

Blog

Stay updated on CMS trends.

Blog

Tips for improving CMS performance.

Blog

Learn how to secure your CMS.

Blog

Explore the advantages of CMS.

Blog

A comprehensive guide to CMS.

Build your resistance to threats. And save hundreds of hours each month.