# makit > makit is an open-source (MIT) command-line tool for the security of Linux servers you run yourself (Ubuntu and Debian) and of the clusters behind your cloud load balancer. It checks the host and its Docker containers (`makit scan`), blocks attacks before they reach the app with a request shield that also handles bots and AI agents (`makit shield`, on a server or as a Kubernetes Deployment that your gateway asks), sends alerts (`makit notify`), sets up and hardens new servers (`makit init`) and shows a terminal dashboard (`makit top`). Install as root: `curl -fsSL https://makit.sh/install.sh | sh` (a given version: `… | sh -s -- v0.7.0`). The installer hands over to the release's own `install.sh` on GitHub, which checks the source and binaries against the release's SHA256SUMS. In Kubernetes: `helm install shield oci://ghcr.io/runsnip/charts/makit-shield -n makit --create-namespace` (image `ghcr.io/runsnip/makit-shield`, signed with cosign). Source code: https://github.com/runsnip/makit. The full documentation in one file: https://makit.sh/llms-full.txt. Build and check a config in the browser: https://makit.sh/playground.html Contact: hello@makit.sh for questions, feedback and partnerships; security@makit.sh to report a vulnerability privately. Bugs and feature requests: https://github.com/runsnip/makit/issues Key facts: - `makit scan` is read-only and asks for consent; it never changes, deletes or uploads anything. - `makit shield` works in two independent modes: **ask** (Caddy `forward_auth`, nginx `auth_request`, Envoy Gateway / Istio / Envoy `ext_authz`, Traefik `forwardAuth`, ingress-nginx `auth-url` call makit's `/check`) and **edge** (makit in front, optionally reading PROXY protocol v1/v2 from an AWS NLB). Modes: block, observe, pass. `makit shield snippet …` prints each setup. - The client IP, behind any CDN or load balancer (Cloudflare, CloudFront, DigitalOcean or AWS load balancers, or several): `X-Forwarded-For` (else `Forwarded`, else `X-Real-IP`) read from the right, skipping `trusted_proxies` (presets `cloudflare`, `aws-alb`, `vpc`, `loopback`, or CIDRs), so a visitor cannot choose its own IP. A provider's own header such as `CF-Connecting-IP` is never read: a client could send it past a load balancer. In ask mode the asking proxy appends the address it received the request from, as every proxy does; makit needs no header of its own, and its `X-Makit-*` answers are informational. - The shield keeps its own IP set (a hash table per prefix length, ~180 ns per lookup with 1,000,000 entries, no ipset) and an allowlist that always wins. - Replicas (`cluster:` in shield.yaml, set by the Helm chart) share bans, allow entries, rate limits and request scores: a ban reaches every replica in ~2 ms, `limit 60/1m` holds for the whole cluster, and no decision waits on the network. Messages are HMAC-signed. - Bans can be pushed to AWS WAF IP sets (`aws_waf:`); `/metrics` serves Prometheus metrics; `makit shield analyze` reads nginx, Caddy and AWS ALB access logs. - `makit shield config check [FILE] [--replay LOG]` reports every misspelt key, wrong value and risky setting with its line, and shows what a new config would change on a real log; the playground on makit.sh runs the same check compiled to WebAssembly. - HTTP rules stop exploits carried in headers, each named by its CVE and replayed from its public proof of concept: Next.js middleware bypass (CVE-2025-29927), Spring Cloud Function (CVE-2022-22963), Struts OGNL (CVE-2017-5638), F5 BIG-IP (CVE-2022-1388), Fortinet (CVE-2022-40684), Rails Accept traversal (CVE-2019-5418), Symfony X-Rewrite-URL (CVE-2018-14773); Shellshock in any header is scored. - Threat knowledge is open data in the repository (`security/`): HTTP rules, the request scoring set, the bot catalog, vulnerabilities. Maintainers override it per server in `/etc/makit/security` or `/etc/makit/shield.yaml`. - Bots and AI agents are verified against published IP ranges or forward-confirmed reverse DNS; the maintainer chooses per category or per bot: allow, log, block, ban or `limit N/window` (an agent's limit counts all its IPs together). The catalog favours no crawler. - One server can serve many domains: the top of `shield.yaml` is the global policy, `sites:` overrides it per domain. - Configuration: `/etc/makit/shield.yaml`, `/etc/makit/notify.yaml`; state: `/var/lib/makit/shield/`; reports: `/var/log/makit/shield/reports/`. - Output is coloured at a terminal and plain when piped; `NO_COLOR=1` turns colour off, `FORCE_COLOR=1` keeps it on. ## Docs - [README](https://raw.githubusercontent.com/runsnip/makit/main/README.md): what makit does, every command, install and verification - [Roadmap](https://raw.githubusercontent.com/runsnip/makit/main/ROADMAP.md): what comes next (v0.8: more edges, scanning pods and images), later plans, and what is not planned - [Request shield](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/shield.md): ask and edge modes, gateways, the client IP behind proxies and load balancers, PROXY protocol, replicas, config check and replay, metrics, the IP set, rules, scoring, sites, reports, log analysis - [Kubernetes and cloud load balancers](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/kubernetes.md): Helm chart, signed image, gateways, the client IP behind ALB/NLB/Cloudflare, replicas, AWS WAF, live config - [Bots, crawlers and AI agents](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/bots.md): recognition, verification, policies, bot score, your own IP sources, robots.txt - [Notifications](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/notifications.md): Telegram, Slack, Google Chat, Discord, Teams, ntfy, webhooks, email - [Security guides index](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/README.md): one page per topic, with the `makit scan` rule ids each covers ## Check and respond - [Malware indicators](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/malware.md) - [Persistence](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/persistence.md) - [Vulnerable dependencies](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/dependencies.md) - [Scheduled scans](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/scheduled-scans.md) - [Incident response](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/incident-response.md) ## Harden - [SSH access](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/ssh.md) - [Firewall](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/firewall.md) - [Docker and the firewall](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/docker-ports.md) - [Outbound traffic (egress)](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/egress.md) - [Container hardening](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/containers.md) - [Security updates](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/updates.md) - [Kernel settings](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/kernel.md) - [Temporary directories](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/mounts.md) - [fail2ban](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/fail2ban.md) - [AppArmor](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/apparmor.md) - [Secrets](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/secrets.md) - [Logging and auditing](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/logging.md) - [Cloud and code accounts](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/accounts.md) - [Backups](https://raw.githubusercontent.com/runsnip/makit/main/docs/security/backups.md) ## Optional - [Benchmarks](https://raw.githubusercontent.com/runsnip/makit/main/benchmark/README.md): what the shield costs per request and how to reproduce it - [Changelog](https://raw.githubusercontent.com/runsnip/makit/main/CHANGELOG.md) - [Security policy](https://raw.githubusercontent.com/runsnip/makit/main/SECURITY.md): report vulnerabilities to security@makit.sh - [Security catalog](https://github.com/runsnip/makit/tree/main/security): rules, scoring sets, bot catalog, vulnerabilities (YAML/JSON)