Page cover

Lo-Fi

Lofi - TryHackMe

Overview

The Lofi machine on TryHackMe is a fun and practical challenge focused on Local File Inclusion (LFI) and Path Traversal vulnerabilities. In this challenge, participants are tasked with navigating the filesystem of a vulnerable web server to find the hidden flag. Along the way, they will explore techniques to exploit LFI and Path Traversal, demonstrating the importance of secure web application development and proper server configuration.


Key Objectives

  1. Enumeration: Start by scanning open ports using tools like Nmap to identify the services running on the machine.

  2. Exploitation: Leverage LFI and Path Traversal vulnerabilities to access sensitive files on the server, such as /etc/passwd and /etc/shadow.

  3. Privilege Escalation: While SSH access to the target system may not be possible without the correct key, the focus will be on filesystem navigation and discovering hidden content like the flag.txt file.


Skills Demonstrated

  • Port Scanning: Use Nmap for service enumeration and to identify open ports on the target machine.

  • Local File Inclusion (LFI) & Path Traversal: Exploit LFI and Path Traversal vulnerabilities to access system files and uncover hidden data.

  • Web Application Analysis: Investigate the web application for vulnerabilities such as improper input sanitization that allow path traversal to sensitive files.

  • Flag Discovery: Locate the flag.txt file within the filesystem by manipulating URL parameters.


Relevance

The Lofi challenge highlights the critical risks of LFI and Path Traversal vulnerabilities in web applications. It emphasizes the need for proper validation and sanitization of user input to prevent unauthorized file access. Engaging with this machine offers participants valuable hands-on experience in exploiting common web vulnerabilities, reinforcing the importance of secure coding practices.

Last updated