/TaskThief

Advanced Penetration Testing Tool for Scheduled Task Privilege Escalation

Primary LanguageShell

๐Ÿ•ต๏ธ TaskThief

Version License Platform Bash

Advanced Security Testing Tool for Scheduled Tasks

๐Ÿ“‹ Overview

TaskThief is a sophisticated security tool for active testing of scheduled tasks and cron jobs on Linux systems. It helps identify and evaluate misconfigurations in task schedulers that could lead to privilege escalation or persistent backdoors.

๐Ÿ” Discover โ†’ ๐Ÿ›ก๏ธ Analyze โ†’ ๐Ÿงช Test โ†’ ๐Ÿ“Š Report

๐ŸŒŸ Key Features

Feature Description
๐Ÿ” Enhanced Discovery Systematically detects all scheduled tasks, including hidden ones in udev rules, systemd units, and more
๐Ÿ›ก๏ธ Configuration Analysis Evaluates settings against security best practices to identify potential vulnerabilities
๐Ÿงช Simulated Attacks Performs controlled modifications to test for privilege escalation vectors
๐Ÿ“Š Comprehensive Reporting Generates detailed HTML and text reports with actionable recommendations
๐Ÿ“ Advanced Logging Configurable logging levels with enhanced backup and restore mechanisms
๐Ÿ” Smart Privilege Handling Intelligently manages root access requirements for operations
๐Ÿงฉ Modular Architecture Easily extensible with additional modules for other schedulers
โŒจ๏ธ CLI Support Run specific operations directly from the command line

๐Ÿ”ง Requirements

  • Bash 4.0 or higher
  • Linux operating system
  • Root privileges for full functionality (can be provided via sudo)

๐Ÿ“ฅ Installation

# Clone the repository
git clone https://github.com/reschjonas/TaskThief.git

# Navigate to the directory
cd TaskThief

# Make the script executable
chmod +x taskthief.sh

# Run TaskThief
./taskthief.sh

๐Ÿš€ Usage

Core Functionality

๐Ÿ” Automatic Discovery [Requires Root]
โ€ข Identifies cron jobs, systemd timers, AT jobs, and anacron jobs
โ€ข Discovers hidden scheduled tasks like udev rules, startup scripts, and more
โ€ข Gathers detailed information about each scheduled task
๐Ÿ›ก๏ธ Configuration Analysis [Requires Root]
โ€ข Analyzes cron jobs and systemd timers for security issues
โ€ข Checks for permission problems in configuration files
โ€ข Identifies weak configurations that could be exploited
๐Ÿงช Task Manipulation [Requires Root]
โ€ข Tests cron job hijacking by attempting controlled modifications
โ€ข Tests systemd timer manipulation to identify privilege escalation vectors
โ€ข Demonstrates how an attacker might create persistent backdoors
๐Ÿ“Š Reporting
โ€ข Generates comprehensive HTML or text reports
โ€ข Provides detailed findings and recommendations
โ€ข Exports results for documentation purposes

๐Ÿ’ป Command Line Options

./taskthief.sh [OPTION]
Option Description
-h, --help Display help message
-v, --version Display version information
-d, --discover Run full discovery immediately
-a, --analyze Run full analysis immediately
-r, --report Generate a full report immediately

๐Ÿ” Privilege Management

TaskThief automatically detects when root privileges are required and offers options to:

  1. Continue without root privileges (limited functionality)
  2. Restart with sudo to gain full functionality
  3. Exit the application

For critical operations that require root access, TaskThief will prompt you to elevate privileges when needed.

๐Ÿ“ Logging Levels

Level Description
DEBUG Most verbose, logs all operations
INFO Standard information (default)
WARNING Only logs warnings and errors
ERROR Only logs errors
NONE Disables logging

Configure logging in the Settings menu or by editing the config file.

โš ๏ธ Security Considerations

TaskThief is designed for legitimate security testing and educational purposes. When using this tool:

  • โœ… Always ensure you have proper authorization to test the target systems
  • โœ… Use in a controlled environment when possible
  • โœ… Backup important files before running manipulation tests
  • โœ… Review all findings and manipulations carefully

โš–๏ธ Disclaimer

The tool performs active testing that modifies system files to demonstrate vulnerabilities. You should use this tool cautiously and only on systems you are authorized to test.

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE.md file for details.

๐Ÿ‘ฅ Credits

Developed as a penetration testing tool for identifying vulnerabilities in scheduled task systems.


Built with โค๏ธ for security professionals and system administrators