file-inclusion

Identify and exploit LFI and RFI vulnerabilities to read server files and achieve remote code execution.

60|14|Updated Apr 27, 2026
One-click install
npx skills add https://github.com/brucesongs/kali-claw --skill file-inclusion-brucesongs
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: file-inclusion
Source: https://github.com/brucesongs/kali-claw/tree/main/skills/file-inclusion
Command: npx skills add https://github.com/brucesongs/kali-claw --skill file-inclusion-brucesongs

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

LFI and RFI vulnerabilities expose sensitive files and enable remote code execution when user-controlled input determines file inclusion, risking data leakage and full system compromise.

Core Features & Use Cases

  • Enumerates common LFI/RFI vectors, including path traversal, PHP wrappers, log poisoning, and session file inclusion.
  • Demonstrates escalation paths from file reads to remote code execution, with defense recommendations and lab guidance.
  • Provides guidance for automated tooling and test cases (dotdotpwn, kadimus, fimap, ffuf, Burp Suite, SecLists).

Quick Start

Run this skill against a target application with an LFI/RFI vulnerability to identify writable log paths and test potential inclusion vectors.

Frequently Asked Questions about file-inclusion

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I exploit Local File Inclusion vulnerabilities to read server files?

To exploit Local File Inclusion (LFI), you manipulate user-controlled inclusion parameters using path traversal and PHP wrappers to read sensitive server files. This process involves identifying typical inclusion parameters and testing payloads using manual techniques or automated tools.

What is the best way to escalate remote file inclusion to remote code execution?

Remote File Inclusion (RFI) achieves remote code execution by hosting malicious payloads remotely and injecting the payload URL into vulnerable inclusion parameters. You can also use log poisoning or session file inclusion techniques to execute code locally on the target server.

Do I need Burp Suite and ffuf to test path traversal vulnerabilities?

You need web security testing tools like Burp Suite, ffuf, dotdotpwn, kadimus, and fimap to effectively test path traversal and file inclusion vulnerabilities. These tools automate payload delivery and help identify valid file paths during controlled security assessments.

How does PHP wrapper exploitation work during web application pentesting?

PHP wrapper exploitation during web application pentesting works by passing specialized PHP stream wrappers, such as php://filter or php://input, into vulnerable inclusion parameters. This allows attackers to read plaintext source files or execute embedded PHP code directly.

When should I use log poisoning for file inclusion attacks?

You should use log poisoning for file inclusion attacks when direct remote file inclusion is disabled, allowing you to write PHP code into server log files. You then include the poisoned log file path via the LFI vulnerability to trigger remote code execution.

Can I use SecLists to automate local file inclusion payload discovery?

Yes, you can use SecLists wordlists with fuzzing tools like ffuf to automate local file inclusion payload discovery. This combination brute-forces common file paths and traversal sequences to identify accessible server files through vulnerable inclusion parameters.