Download the PHP package wallacemartinss/filament-security without Composer

On this page you can find all versions of the php package wallacemartinss/filament-security. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package filament-security

Filament Security

Latest Version on Packagist Total Downloads License

Security plugin for Filament v5 with eight protection layers: disposable email blocking, DNS/MX verification, RDAP domain age check, single session enforcement, honeypot bot protection, Cloudflare IP blocking, malicious scan detection, and a security event dashboard with real-time analytics.

Screenshots

Email Validation

DNS/MX Verification Disposable Email Blocking

Security Event Dashboard

Stats, Tabs & Event Table Charts & Top Offending IPs

Version Compatibility

Package Version Filament Livewire Laravel Branch
2.x v5 v4 11 / 12 / 13 main
1.x v4 v3 11 / 12 / 13 1.x

Requirements

Installation

Publish the config file:

If you enable the Event Log (Layer 8) or Cloudflare IP Blocking (Layer 6), publish and run the migrations:

Tailwind CSS (required for custom views)

If you use a custom Filament theme, add the plugin's source paths to your resources/css/filament/admin/theme.css so Tailwind can scan the plugin's views and classes:

Then rebuild your theme:

Register the plugin in your AdminPanelProvider (after ->registration()):

Layer 1: Disposable Email Blocking

Blocks registration with temporary/disposable email addresses. Ships with 192,000+ built-in domains (sourced from disposable/disposable-email-domains) and supports custom domains.

Covers all major disposable email providers including Mailinator, YOPmail, GuerrillaMail (all 11 variants), TempMail, ThrowAway, Burner Mail, and thousands more.

Filament Registration Integration

When disposableEmailProtection() is enabled, the plugin automatically replaces the default Filament registration page with a secured version that validates emails against the disposable domain list. No extra configuration needed.

The plugin only replaces the default Register::class. If you have a custom registration page, use the trait instead:

Usage as Validation Rule

Usage in Filament Forms

Programmatic Check

Managing Custom Domains

Configuration

Domain Sources (priority order)

Source Location How to manage
Built-in data/disposable-domains.json Shipped with package (192,000+ domains)
Custom file storage/filament-security/custom-domains.txt php artisan filament-security:domain
Config config/filament-security.php Edit config file
Whitelist config/filament-security.php Edit config file (overrides all)

Layer 2: DNS/MX Verification

Verifies that the email domain has valid mail infrastructure. Blocks domains that cannot receive email — domains with no MX records and no A/AAAA fallback, or domains with MX records pointing to suspicious targets (localhost, private IPs).

How it works

Enabled by default

DNS/MX verification is enabled by default. No extra setup required.

Usage as Validation Rule

Programmatic Check

Configuration

What is detected

Condition Result
No MX, no A, no AAAA records Blocked
MX pointing to localhost or private IP Blocked
Valid MX records Allowed
No MX but has A/AAAA record Allowed (RFC 5321)
DNS lookup fails Allowed (fail-open)

Layer 3: Domain Age Verification (RDAP)

Checks the domain registration age via RDAP (Registration Data Access Protocol). Blocks recently registered domains — a common pattern in spam, phishing, and fraud campaigns.

Disabled by default

This feature makes external HTTP calls to RDAP servers. Enable it via .env:

Usage as Validation Rule

Programmatic Check

Configuration

Failure behavior

Scenario block_on_failure=false (default) block_on_failure=true
RDAP server unreachable Allow Block
TLD not in IANA bootstrap Allow Block
No registration date in response Allow Block
Domain age >= min_days Allow Allow
Domain age < min_days Block Block

Layer 4: Single Session Enforcement

Ensures only one active session per user. When a user logs in from a new browser or device, all previous sessions are immediately terminated. Works with database, Redis, and file session drivers.

How it works

Disabled by default

Session driver support

Driver Destruction method Enforcement
database Bulk DELETE by user_id Immediate
redis Destroy session key via handler Immediate + middleware fallback
file Destroy session file via handler Immediate + middleware fallback

Programmatic Usage

Configuration

Layer 5: Honeypot Protection

Protects registration forms against bots using invisible honeypot fields. Powered by spatie/laravel-honeypot.

Two invisible fields are injected into the registration form:

  1. Empty field - Bots auto-fill all fields; if this field has a value, the submission is rejected
  2. Timestamp field - Tracks how fast the form was submitted; instant submissions are rejected

Enabled by default

Custom Registration Page

When spam is detected, the request is aborted with 403 Forbidden. A SpamDetectedEvent is also fired for logging or IP blocking (Layer 6).

Layer 6: Cloudflare IP Blocking

Automatically blocks suspicious IPs on Cloudflare WAF after repeated failed login attempts or bot detection via honeypot.

Real client IP resolved through: CF-Connecting-IP > X-Real-IP > X-Forwarded-For > REMOTE_ADDR

Setup

  1. Add your Cloudflare credentials to .env:

  2. Publish and run the migration:

  3. Enable in the plugin:

How to get your Cloudflare credentials

API Token

  1. Go to Cloudflare Dashboard > My Profile > API Tokens
  2. Click "Create Token" > "Create Custom Token"
  3. Permissions: Zone > Firewall Services > Edit
  4. Zone Resources: Include > Specific zone > select your domain

Zone ID

  1. Go to Cloudflare Dashboard and select your domain
  2. On the Overview page, scroll down to the right sidebar > API section > copy Zone ID

Managing Blocked IPs

Programmatic Usage

Configuration

Layer 7: Malicious Scan Protection

Detects and blocks requests to known exploit paths, config files, web shells, and CMS admin pages. Returns 404 and logs the attempt as a security event.

What is detected

Category Examples
Config/env files .env, .git, .htaccess, wp-config.php
Package files composer.json, package.json, yarn.lock
Credentials credentials.json, firebase.json, database.json
WordPress/CMS wp-admin, wp-login, xmlrpc.php
Web shells shell.php, cmd.php, c99, r57, webshell
Exploit paths etc/passwd, proc/self, ../../..
Admin panels phpmyadmin, adminer, pgadmin, cPanel
Debug endpoints phpinfo, _debug, _profiler, actuator

Disabled by default

The middleware is automatically registered in the web middleware group when enabled.

Configuration

Layer 8: Security Event Dashboard

A complete Filament resource that records and visualizes all security events across every layer. Provides a real-time dashboard with stats, charts, and a threat intelligence table.

What is recorded

Every layer in the plugin automatically records events when the Event Log is enabled:

Event Type Source Layer Trigger
disposable_email Layer 1 Disposable email blocked during registration
dns_mx_suspicious Layer 2 Domain with no valid mail servers
domain_too_young Layer 3 Domain registered too recently
session_terminated Layer 4 User session killed by newer login
honeypot_triggered Layer 5 Bot detected via honeypot
login_lockout Layer 6 Failed login attempt
ip_blocked Layer 6 IP blocked on Cloudflare
ip_unblocked Layer 6 IP unblocked via panel
malicious_scan Layer 7 Exploit path accessed

Setup

  1. Enable in .env:

  2. Publish and run the migration:

  3. Enable in the plugin:

Dashboard features

The Security Events page includes:

Header Widgets (4 stat cards):

Tabs (filtered by category):

Footer Widgets (3 charts):

Table features:

Actions:

Programmatic Usage

Configuration

IpInfo Integration (Optional)

Enrich security events with IP geolocation data (country, city, organization) from ipinfo.io. This is completely optional — if no token is provided, everything works without geolocation.

Setup

  1. Get a free API token at ipinfo.io/signup
  2. Add to .env:

How it works

Configuration

Environment Variables

Testing

Translations

The package includes translations in 15 languages: English, Brazilian Portuguese, German, Spanish, French, Italian, Japanese, Korean, Dutch, Polish, Russian, Turkish, Ukrainian, Arabic, and Chinese (Simplified).

To publish translations:

License

MIT License. See LICENSE for details.


All versions of filament-security with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
filament/filament Version ^5.0
spatie/laravel-honeypot Version ^4.0
spatie/laravel-package-tools Version ^1.16
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package wallacemartinss/filament-security contains the following files

Loading the files please wait ...