Skip to main content

Modular Linux intrusion detection CLI by MinakiLabs

Project description

🛡️ MinakiShield

Modular Linux Intrusion Detection CLI
Built by MinakiLabs


🚀 Overview

MinakiShield is a lightweight, modular command-line intrusion detection system for Linux. It monitors system logs in real time to detect unauthorized access attempts, privilege escalations, and more. MinakiShield alerts you instantly via webhooks (Slack, Discord, or custom endpoints) and can run continuously using systemd (user or system scope).


✅ Features

  • 🔐 SSH Brute-Force Detection
  • 🧑‍💻 Sudo Abuse Monitoring
  • 🔎 Real-Time Log Watching (/var/log/auth.log)
  • 📦 Slack & Discord Webhook Alerts
  • 🧩 Modular Detection Services
  • 🧱 Plugin System for Custom Rules
  • ⚙️ Systemd Integration (User & System Level)
  • 📁 Plaintext & JSON Logging
  • 🧪 Built-in Testing, Configuration, and Log Review

📦 Installation

From PyPI (recommended):

pip install --user minaki-shield

Then confirm:

shield --help

Optional: Make globally accessible

sudo ln -s ~/.local/bin/shield /usr/local/bin/shield


⸻

🧠 Quick Start

Start monitoring:

shield monitor --logfile /var/log/auth.log --json --log-to-file

Configure your webhook:

shield config --set-webhook https://hooks.slack.com/services/...

Install as a systemd user service:

shield systemd

Install as a system-wide service:

sudo shield systemd --scope system


⸻

📜 Command Overview

shield monitor         # Start live log monitoring
shield config          # Set or view webhook settings
shield services        # Enable/disable detection modules
shield systemd         # Create and launch systemd service
shield uninstall       # Stop and remove service
shield test            # Verify webhook and log file setup
shield logs            # Show recent alerts
shield plugins         # View custom plugin commands


⸻

🔔 Supported Detection Modules

Module	Description
ssh_bruteforce	Detects repeated failed SSH login attempts
sudo_abuse	Detects brute-forced or abnormal sudo usage

Enable/disable them with:

shield services enable sudo_abuse
shield services disable ssh_bruteforce


⸻

📂 File Locations

File or Directory	Purpose
~/.minakishield/config.yaml	Webhook configuration
~/.minakishield/shield.log	JSON or plaintext alert log
~/.config/systemd/user/minakishield.service	User-level systemd service
/etc/systemd/system/minakishield.service	System-wide systemd service (optional)


⸻

🤖 Plugin Development

To create your own custom plugin:
	1.	Save the following to ~/.minakishield/plugins/my_plugin.py:

import click

@click.command()
def cli():
    click.echo("🧪 Plugin loaded successfully!")

	2.	Then run:

shield plugins


⸻

🧪 Developer Setup

Clone and install from source:

git clone https://github.com/MinakiLabs-Official/minaki_shield-.git
cd minaki_shield-
pip install --user .

Reinstall after making local changes:

pip install --user --force-reinstall .


⸻

🌍 Webhook Support

✅ MinakiShield supports:
		Slack
		Discord
		Custom Webhook URLs (HTTP POST with JSON payloads)

⸻

🧽 Uninstallation

Stop and remove services:

shield uninstall

Uninstall the package:

pip uninstall minaki-shield

Remove global executable (if created):

sudo rm /usr/local/bin/shield


⸻

📜 License

MIT License
© 2025 Andrew Polykandriotis / MinakiLabs

⸻

👋 Contributions & Feedback

Pull requests, ideas, feedback, and security reports are welcome.
Join the mission at MinakiLabs-Offical on GitHub

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

minaki_shield-0.1.2.tar.gz (12.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

minaki_shield-0.1.2-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

Details for the file minaki_shield-0.1.2.tar.gz.

File metadata

  • Download URL: minaki_shield-0.1.2.tar.gz
  • Upload date:
  • Size: 12.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for minaki_shield-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0edd8aec11fc6d9f69b29a54dc6df743c659d416228965faa7e60d17f6bfbea6
MD5 e9bce2a1e29113d8c1ebc001fcc59723
BLAKE2b-256 742921b9384705dcddeea8181bb529d7a6857af47183666bdac25ced0eabfbeb

See more details on using hashes here.

File details

Details for the file minaki_shield-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: minaki_shield-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 17.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for minaki_shield-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a88885ab46fce101690b4ba40913124fd9780fadf9c5cc29adaa09aad551a68b
MD5 b2f6a0d9501a9d31f5f26302c61e715e
BLAKE2b-256 040aaa71fe9f7fe5bad6dbbda6cd17badfa12a052223c66e792317543f11be42

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page