ikay/theharvester-service is a Laravel package for this is my package theharvester-service.
It currently has 0 GitHub stars and 23 downloads on Packagist (latest version 1.0.13).
Install it with composer require ikay/theharvester-service.
Discover more Laravel packages by ikay
or browse all Laravel packages to compare alternatives.
Last updated
A Laravel package that runs theHarvester OSINT scans as ephemeral Docker containers and stores the parsed results. Given a target domain, it spins up one or more secsi/theharvester containers through the Docker Engine API, runs the scan, collects the logs, and extracts the number of IPs, emails, and hosts discovered.
Built on the Spatie package skeleton, with GitHub Actions CI, Pint, Larastan, and Pest.
composer require ikay/theharvester-service
Publish and run the migrations:
php artisan vendor:publish --tag="theharvester-service-migrations"
php artisan migrate
Publish the config:
php artisan vendor:publish --tag="theharvester-service-config"
The package talks to Docker over HTTP via a Guzzle client. Point it at your Docker Engine API in config/services.php:
'docker' => [
'endpoint' => env('DOCKER_ENDPOINT', 'http://localhost:2375'),
'timeout' => env('DOCKER_TIMEOUT', 120),
],
config/theharvester-service.php controls how the package integrates with your app:
| Key | Default | Purpose |
| --- | --- | --- |
| model | User::class | The user model tasks belong to |
| log_model | UserActivityLog::class | Model used for activity logging |
| guard | web | Auth guard |
| middleware | ['web'] | Middleware applied to routes |
| auth_middleware | auth | Auth middleware |
| layouts | layouts.master | Blade layout for the views |
| theharvester_route | /tasks/theharvesters/ | Base route |
| theharvester_index | /tasks/theharvesters | Index route |
A Theharvester task holds the scan request (domain, container count, title, description, status, user_id). Running it:
container Docker containers from the secsi/theharvester:latest image, each running theHarvester -d <domain> -b all.IPs found, Emails found, and Hosts found.Errors are captured to an error-log relation and to the single log channel, so a failed Docker call or scan is stored rather than thrown away.
use Ikay\TheharvesterService\Models\Theharvester;
use Ikay\TheharvesterService\TheharvesterService;
$task = Theharvester::create([
'user_id' => auth()->id(),
'title' => 'example.com recon',
'domain' => 'example.com',
'container' => 2, // number of parallel scan containers
'description' => 'Quarterly OSINT sweep',
'status' => 0,
]);
(new TheharvesterService($task))->createTheharvesterContainer();
// Results are stored on the task's container records:
$task->containers; // each has ip, email, host, operation_time, container_id
A TaskTheharvesterCreated event is dispatched when a task is created, so you can queue the scan from a listener rather than running it inline.
Theharvester — a scan task. hasMany containers, hasMany error logs, belongsTo the configured user model.TheharvesterContainer — one container run: ip, email, host counts, operation_time, container_id.TheharvesterEventualError — captured exceptions (message, code, file, line, trace).composer test
This package executes Docker commands and runs OSINT tooling against domains you supply. Only run it against domains you are authorised to assess, and keep the Docker Engine endpoint on a trusted network — an exposed Docker API is a remote-code-execution risk.
MIT. See LICENSE.md.