kanopi/firewall
Kanopi Firewall is a lightweight PHP/Laravel package for controlling access by IP address. It offers configurable allow/deny rules and middleware integration to protect routes, block unwanted traffic, and manage firewall behavior from application configuration.
firewall-check --lint), and diagnostics (firewall-doctor). It is a reasonable buy/adopt alternative to building custom middleware for crawler verification, IP trust, and allow/block rules—especially if the team is already on Laravel and wants to avoid a full WAF or edge vendor.timeout_ms, verify_claim_wait_ms).Firewall::create(): lists now replace rather than append. This supports a deliberate upgrade plan—audit trusted_proxies, lockdown_allow, verify_suffixes, and included configs—rather than a blind dependency bump.Consider adoption when:
Look elsewhere when:
For executives: This release turns a known operational risk—slow reverse-DNS lookups holding PHP workers for up to ten seconds—into a bounded, measurable cost. Verification now has a configurable time limit, an opt-in DNS-over-HTTPS provider, and a circuit breaker that keeps one bad resolver from affecting everyone. The default remains private: no visitor data goes to a third party unless we explicitly choose a provider. The trade-off is a small configuration change for sites using multiple configs, which we can audit and stage.
For engineering: v2.38.0 adds global.reverse_dns.provider with cloudflare, google, per-rule overrides, and custom resolver support, plus startup validation and firewall-doctor visibility into where lookups go. It also hardens verification semantics and fixes list-merging inconsistencies. The upgrade requires attention only if Firewall::create() receives more than one config: lists now replace rather than append, and an included file’s [] now clears a list. Single-config deployments should see no behavioral difference. PHP 8.1–8.5 are supported; the DNS-over-HTTPS resolver requires the curl extension. Recommend a staged upgrade with config audit, lint, and a short canary period measuring verification latency and breaker behavior.
How can I help you explore Laravel packages today?